GithubHelp home page GithubHelp logo

dexrepair's Introduction

Dex Repair

Command line tool to repair Android DEX bytecode files CRC checksum and SHA-1 hash

Compile

  • Clone this repository
  • Install Android NDK if you want to cross-compile for Android devices
  • Invoke make.sh bash script with desired build target
    • $ ./make.sh - default system compiler
    • $ ./make.sh gcc - prefer gcc
    • $ ./make.sh clang - prefer clang
    • $ ./make.sh cross-android - cross-compile for Android with NDK
  • Executables are copied under the bin directory

Usage

$ bin/dexRepair -h
    DEX Repair ver. 0.1.4

    Anestis Bechtsoudis <[email protected]>
  Copyright 2015-2017 by CENSUS S.A. All Rights Reserved.

  -I,  --input-files=DIR : input files dirs (1 level recursion only) or single file
  -S,  --repair-sha      : repair SHA-1 hash too (default: disabled)
  -h,  --help            : this help
  -v,  --debug=LEVEL     : debug level (0 - FATAL ... 4 - DEBUG), default: '3' (INFO)

Changelog

  • 0.1.4 - 13 October 2017
    • Dex version 038 (Oreo) & 039 (dev-master) support
  • 0.1.3 - 26 April 2017
    • Support to repair SHA-1 hash too
  • 0.1.2 - 24 April 2017
    • Refactor readdir utils
    • Improve make script & Android.mk
  • 0.1.1 - 5 September 2016
    • Add support for ODEX 037 format
  • 0.1.0 - 14 February 2015
    • Initial commit

License

   Anestis Bechtsoudis <[email protected]>
   Copyright 2015-2017 by CENSUS S.A. All Rights Reserved.

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

     http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.

dexrepair's People

Contributors

anestisb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dexrepair's Issues

error: ‘readdir_r’ is deprecated

Hello,
when I tried to cross-compile on lubuntu 16.04 into arm64 I got 'error: ‘readdir_r’ is deprecated'.

shell log is:
lubuntu@lubuntu:~/dexRepair$ ./make.sh make: Entering directory '/home/lubuntu/dexRepair/src' rm -f *.o rm -f dexRepair make: Leaving directory '/home/lubuntu/dexRepair/src' make: Entering directory '/home/lubuntu/dexRepair/src' cc -c -std=c11 -D_GNU_SOURCE -Wall -Wextra -Werror -c dexRepair.c -o dexRepair.o cc -c -std=c11 -D_GNU_SOURCE -Wall -Wextra -Werror -c log.c -o log.o cc -c -std=c11 -D_GNU_SOURCE -Wall -Wextra -Werror -c utils.c -o utils.o utils.c: In function ‘utils_readdir’: utils.c:45:9: error: ‘readdir_r’ is deprecated [-Werror=deprecated-declarations] if (readdir_r(dir, &de, &res) > 0) { ^~ In file included from utils.c:26:0: /usr/include/dirent.h:183:12: note: declared here extern int readdir_r (DIR *__restrict __dirp, ^~~~~~~~~ cc1: all warnings being treated as errors Makefile:36: recipe for target 'utils.o' failed make: *** [utils.o] Error 1 make: Leaving directory '/home/lubuntu/dexRepair/src' [-] gcc build failed

Can you please update utils.c so that it will be compatible with readdir command instead of readdir_r ?

Also, it will be REALLY HELPFUL if you could compile dexRepair and publish the bin for arm & arm64, since source compiling is HARD for me.

Req: dex SHA-1 signature repair, not just alder32 checksum

Dear @anestisb
as known, dexRepair can fix dex file alder32 checksum, but not its SHA-1 signature.
can you please add SHA-1 signature repair as well to dexRepair ?

IMHO, it would be advisable to separate it as a different switch then the already existing checksum repair, since SHA-1 repair should come before adler32 checksum and that SHA-1 calculation is considerable longer then alder32 checksum calculation.

I hope you can add such feature to the already great dexRepair :-)

P.S - as i'm a user in this repo(not dev), I can't label this issues at all - only you can @anestisb.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.