[Python-modules-commits] [androguard] 01/05: Imported Upstream version 2.0
Hans-Christoph Steiner
eighthave at moszumanska.debian.org
Mon Jan 18 22:38:55 UTC 2016
This is an automated email from the git hooks/post-receive script.
eighthave pushed a commit to branch master
in repository androguard.
commit dc92c5c90311213be15b61eaf01fd36f8b1dee43
Author: Hans-Christoph Steiner <hans at eds.org>
Date: Mon Jan 18 20:41:52 2016 +0100
Imported Upstream version 2.0
---
.gitignore | 2 +
.hgsub | 1 +
.hgsubstate | 1 +
CHANGELOG | 27 +
LICENCE-2.0 | 177 +
Makefile | 13 +
README.md | 54 +
androarsc.py | 90 +
androauto.py | 60 +
androaxml.py | 71 +
androcsign.py | 68 +
androdd.py | 218 +
androdiff.py | 119 +
androdis.py | 66 +
androgexf.py | 69 +
androguard/__init__.py | 0
androguard/core/__init__.py | 0
androguard/core/analysis/__init__.py | 0
androguard/core/analysis/analysis.py | 2069 +++
androguard/core/analysis/auto.py | 359 +
androguard/core/analysis/ganalysis.py | 3488 ++++
androguard/core/analysis/risk.py | 1047 ++
androguard/core/analysis/sign.py | 376 +
androguard/core/androconf.py | 375 +
androguard/core/androgen.py | 260 +
androguard/core/api_specific_resources/__init__.py | 0
.../aosp_permissions/__init__.py | 0
.../aosp_permissions/aosp_permissions.py | 24 +
.../aosp_permissions/aosp_permissions_api10.py | 189 +
.../aosp_permissions/aosp_permissions_api14.py | 214 +
.../aosp_permissions/aosp_permissions_api15.py | 216 +
.../aosp_permissions/aosp_permissions_api16.py | 239 +
.../aosp_permissions/aosp_permissions_api17.py | 280 +
.../aosp_permissions/aosp_permissions_api18.py | 291 +
.../aosp_permissions/aosp_permissions_api19.py | 320 +
.../aosp_permissions/aosp_permissions_api21.py | 366 +
.../aosp_permissions/aosp_permissions_api22.py | 374 +
.../aosp_permissions/aosp_permissions_api9.py | 183 +
.../api_permission_mappings/__init__.py | 0
.../api_permission_mappings.py | 24 +
.../api_permission_mappings_api10.py | 11073 +++++++++++
.../api_permission_mappings_api14.py | 15959 ++++++++++++++++
.../api_permission_mappings_api15.py | 15870 ++++++++++++++++
.../api_permission_mappings_api16.py | 13516 ++++++++++++++
.../api_permission_mappings_api17.py | 14170 ++++++++++++++
.../api_permission_mappings_api18.py | 16533 +++++++++++++++++
.../api_permission_mappings_api19.py | 18425 +++++++++++++++++++
.../api_permission_mappings_api21.py | 11053 +++++++++++
.../api_permission_mappings_api22.py | 11378 ++++++++++++
.../api_permission_mappings_api9.py | 10819 +++++++++++
androguard/core/binaries/__init__.py | 0
androguard/core/binaries/elf.py | 101 +
androguard/core/binaries/idapipe.py | 211 +
androguard/core/binaries/idawrapper.py | 160 +
androguard/core/bytecode.py | 764 +
androguard/core/bytecodes/__init__.py | 0
androguard/core/bytecodes/api_permissions.py | 4379 +++++
androguard/core/bytecodes/apk.py | 1950 ++
androguard/core/bytecodes/arm.py | 67 +
androguard/core/bytecodes/dvm.py | 8417 +++++++++
androguard/core/bytecodes/dvm_permissions.py | 341 +
androguard/core/data/__init__.py | 0
androguard/core/data/data.py | 394 +
androguard/core/debugger/__init__.py | 0
androguard/core/resources/__init__.py | 0
androguard/core/resources/public.py | 1935 ++
androguard/decompiler/__init__.py | 0
androguard/decompiler/dad/README.txt | 0
androguard/decompiler/dad/__init__.py | 0
androguard/decompiler/dad/ast.py | 638 +
androguard/decompiler/dad/basic_blocks.py | 368 +
androguard/decompiler/dad/control_flow.py | 437 +
androguard/decompiler/dad/dataflow.py | 485 +
androguard/decompiler/dad/decompile.py | 467 +
androguard/decompiler/dad/graph.py | 487 +
androguard/decompiler/dad/instruction.py | 1372 ++
androguard/decompiler/dad/node.py | 158 +
androguard/decompiler/dad/opcode_ins.py | 1978 ++
androguard/decompiler/dad/tests/dataflow_test.py | 364 +
androguard/decompiler/dad/tests/dominator_test.py | 209 +
androguard/decompiler/dad/tests/rpo_test.py | 217 +
androguard/decompiler/dad/util.py | 210 +
androguard/decompiler/dad/writer.py | 690 +
androguard/decompiler/decompiler.py | 506 +
androguard/gui/__init__.py | 0
androguard/gui/fileloading.py | 45 +
androguard/gui/helpers.py | 74 +
androguard/gui/mainwindow.py | 254 +
androguard/gui/renamewindow.py | 41 +
androguard/gui/sourcewindow.py | 439 +
androguard/gui/stringswindow.py | 76 +
androguard/gui/treewindow.py | 133 +
androguard/gui/xrefwindow.py | 318 +
androguard/misc.py | 197 +
androguard/patch/__init__.py | 0
androguard/patch/zipfile.py | 1435 ++
androguard/session.py | 129 +
androguard/util.py | 19 +
androgui.py | 34 +
androlyze.py | 118 +
androsign.py | 109 +
androsim.py | 191 +
apkviewer.py | 97 +
demos/androguard_ANALYSIS.py | 99 +
demos/apk_format_1.py | 18 +
demos/apk_format_2.py | 18 +
demos/arm_format_1.py | 19 +
demos/axml_format_1.py | 16 +
demos/benchmark.py | 64 +
demos/crackme_dexlabs_patch.py | 62 +
demos/create_invalid_apk.py | 44 +
demos/create_invalid_dex.py | 27 +
demos/dad_emul.py | 179 +
demos/dad_print.py | 329 +
demos/dalvikvm_format_1.py | 25 +
demos/dalvikvm_format_2.py | 27 +
demos/dalvikvm_format_3.py | 23 +
demos/dalvikvm_format_4.py | 31 +
demos/dalvikvm_format_6.py | 106 +
demos/dalvikvm_format_7.py | 23 +
demos/dalvikvm_format_8.py | 33 +
demos/decompiler_dad.py | 30 +
demos/disassembler.py | 33 +
demos/disassembler_analysis.py | 34 +
demos/disassembler_exceptions.py | 45 +
demos/disassembler_special_ins.py | 38 +
demos/example_idapipe.py | 48 +
demos/geinimi_analysis.py | 63 +
demos/tags.py | 29 +
elsim/COPYING | 674 +
elsim/COPYING.LESSER | 165 +
elsim/Makefile | 13 +
elsim/elsim/__init__.py | 0
elsim/elsim/elsign/Makefile | 13 +
elsim/elsim/elsign/__init__.py | 0
elsim/elsim/elsign/dalvik_elsign.py | 593 +
elsim/elsim/elsign/example_sign.py | 66 +
elsim/elsim/elsign/formula/Makefile | 25 +
elsim/elsim/elsign/formula/formula.cc | 66 +
elsim/elsim/elsign/formula/formula.h | 64 +
elsim/elsim/elsign/formula/test.cc | 12 +
elsim/elsim/elsign/libelsign/Makefile | 56 +
elsim/elsim/elsign/libelsign/WuManber.cpp | 176 +
elsim/elsim/elsign/libelsign/WuManber.h | 47 +
elsim/elsim/elsign/libelsign/__init__.py | 0
elsim/elsim/elsign/libelsign/ac_heap.c | 41 +
elsim/elsim/elsign/libelsign/ac_heap.h | 34 +
elsim/elsim/elsign/libelsign/ac_list.c | 130 +
elsim/elsim/elsign/libelsign/ac_list.h | 64 +
elsim/elsim/elsign/libelsign/ac_types.h | 28 +
elsim/elsim/elsign/libelsign/aho_corasick.c | 754 +
elsim/elsim/elsign/libelsign/aho_corasick.h | 114 +
elsim/elsim/elsign/libelsign/cluster.c | 4598 +++++
elsim/elsim/elsign/libelsign/cluster.h | 103 +
elsim/elsim/elsign/libelsign/elsign.cc | 1286 ++
elsim/elsim/elsign/libelsign/elsign.h | 268 +
elsim/elsim/elsim.py | 443 +
elsim/elsim/elsim_dalvik.py | 820 +
elsim/elsim/elsim_db.py | 241 +
elsim/elsim/elsim_text.py | 142 +
elsim/elsim/elsim_x86.py | 138 +
elsim/elsim/similarity/Makefile | 11 +
elsim/elsim/similarity/__init__.py | 0
elsim/elsim/similarity/hashtype.py | 44 +
elsim/elsim/similarity/libsimilarity/Makefile | 42 +
elsim/elsim/similarity/libsimilarity/bz2/Makefile | 22 +
elsim/elsim/similarity/libsimilarity/bz2/bz2.c | 41 +
elsim/elsim/similarity/libsimilarity/bz2/bz2.h | 9 +
.../elsim/similarity/libsimilarity/bz2/test_bz2.c | 88 +
elsim/elsim/similarity/libsimilarity/lzma/Alloc.c | 127 +
elsim/elsim/similarity/libsimilarity/lzma/Alloc.h | 38 +
elsim/elsim/similarity/libsimilarity/lzma/LzFind.c | 761 +
elsim/elsim/similarity/libsimilarity/lzma/LzFind.h | 115 +
elsim/elsim/similarity/libsimilarity/lzma/LzHash.h | 54 +
.../elsim/similarity/libsimilarity/lzma/LzmaDec.c | 999 +
.../elsim/similarity/libsimilarity/lzma/LzmaDec.h | 231 +
.../elsim/similarity/libsimilarity/lzma/LzmaEnc.c | 2268 +++
.../elsim/similarity/libsimilarity/lzma/LzmaEnc.h | 80 +
.../elsim/similarity/libsimilarity/lzma/LzmaLib.c | 46 +
.../elsim/similarity/libsimilarity/lzma/LzmaLib.h | 135 +
elsim/elsim/similarity/libsimilarity/lzma/Makefile | 22 +
elsim/elsim/similarity/libsimilarity/lzma/Types.h | 254 +
elsim/elsim/similarity/libsimilarity/lzma/lzma.c | 11 +
elsim/elsim/similarity/libsimilarity/lzma/lzma.h | 9 +
.../similarity/libsimilarity/lzma/test_lzma.c | 88 +
elsim/elsim/similarity/libsimilarity/similarity.c | 449 +
elsim/elsim/similarity/libsimilarity/similarity.h | 53 +
elsim/elsim/similarity/libsimilarity/smaz/Makefile | 22 +
elsim/elsim/similarity/libsimilarity/smaz/smaz.c | 202 +
elsim/elsim/similarity/libsimilarity/smaz/smaz.h | 7 +
.../similarity/libsimilarity/smaz/test_smaz.c | 88 +
.../elsim/similarity/libsimilarity/snappy/Makefile | 25 +
.../similarity/libsimilarity/snappy/snappy.cc | 53 +
.../elsim/similarity/libsimilarity/snappy/snappy.h | 12 +
.../similarity/libsimilarity/snappy/test_snappy.c | 87 +
.../similarity/libsimilarity/vcblocksort/Makefile | 22 +
.../libsimilarity/vcblocksort/test_vcblocksort.c | 108 +
.../libsimilarity/vcblocksort/vcblocksort.c | 483 +
.../libsimilarity/vcblocksort/vcblocksort.h | 25 +
elsim/elsim/similarity/libsimilarity/xz/Makefile | 22 +
elsim/elsim/similarity/libsimilarity/xz/test_xz.c | 88 +
elsim/elsim/similarity/libsimilarity/xz/xz.c | 40 +
elsim/elsim/similarity/libsimilarity/xz/xz.h | 9 +
elsim/elsim/similarity/libsimilarity/z/Makefile | 22 +
elsim/elsim/similarity/libsimilarity/z/test_z.c | 88 +
elsim/elsim/similarity/libsimilarity/z/z.c | 58 +
elsim/elsim/similarity/libsimilarity/z/z.h | 10 +
elsim/elsim/similarity/simhash.py | 64 +
elsim/elsim/similarity/similarity.py | 534 +
elsim/examples/android/classes_tc.dex | Bin 0 -> 7120 bytes
elsim/examples/android/classes_tc_dasho.dex | Bin 0 -> 6680 bytes
elsim/examples/android/classes_tc_diff.dex | Bin 0 -> 7240 bytes
elsim/examples/android/classes_tc_diff_dasho.dex | Bin 0 -> 6756 bytes
elsim/examples/android/classes_tc_mark1.dex | Bin 0 -> 7120 bytes
elsim/examples/android/classes_tc_proguard.dex | Bin 0 -> 7452 bytes
elsim/examples/text/COPYING.LESSER | 165 +
elsim/examples/text/COPYING.LESSER.MODIF | 163 +
elsim/examples/text/COPYING.LESSER.MODIF.info | 4 +
elsim/examples/text/COPYING.LESSER.MODIF_ADD | 167 +
elsim/examples/text/COPYING.LESSER.MODIF_ADDREMOVE | 161 +
elsim/examples/text/COPYING.LESSER.MODIF_REORDER | 167 +
elsim/signatures/basebridge.b.sign | 1 +
elsim/signatures/basebridge.c.sign | 1 +
elsim/signatures/basebridge.sign | 1 +
elsim/signatures/basebridge_included.sign | 1 +
elsim/signatures/boxer.sign | 1 +
elsim/signatures/crusewind.sign | 1 +
elsim/signatures/dbandroguard | 1 +
elsim/signatures/dbandroguard_exploits | 1 +
elsim/signatures/dbconfig | 1 +
elsim/signatures/dogowar.sign | 1 +
elsim/signatures/droiddeluxe.sign | 1 +
elsim/signatures/droiddream.sign | 1 +
elsim/signatures/droiddream_included.sign | 1 +
elsim/signatures/droiddream_light.sign | 1 +
elsim/signatures/droidkungfu.sign | 1 +
elsim/signatures/droidkungfu2.sign | 1 +
elsim/signatures/droidkungfu3.sign | 1 +
elsim/signatures/ewalls.b.sign | 1 +
elsim/signatures/ewalls.sign | 1 +
elsim/signatures/exploid_exploit.sign | 1 +
elsim/signatures/foncy.b.sign | 1 +
elsim/signatures/foncy.c.sign | 1 +
elsim/signatures/foncy.sign | 1 +
elsim/signatures/geinimi.sign | 1 +
elsim/signatures/ggtracker.sign | 1 +
elsim/signatures/gingermaster.sign | 1 +
elsim/signatures/golddream.sign | 1 +
elsim/signatures/hipposms.b.sign | 1 +
elsim/signatures/hipposms.sign | 1 +
elsim/signatures/hongtoutou.sign | 1 +
elsim/signatures/logastrod.sign | 1 +
elsim/signatures/lovetrap.sign | 1 +
elsim/signatures/moghava.sign | 1 +
elsim/signatures/nickybot.sign | 1 +
elsim/signatures/nickyspy.sign | 1 +
elsim/signatures/ozotshielder.b.sign | 1 +
elsim/signatures/ozotshielder.c.sign | 1 +
elsim/signatures/ozotshielder.sign | 1 +
elsim/signatures/pjapps.b.sign | 1 +
elsim/signatures/pjapps.c.sign | 1 +
elsim/signatures/pjapps.sign | 1 +
elsim/signatures/plankton.b.sign | 1 +
elsim/signatures/plankton.c.sign | 1 +
elsim/signatures/plankton.sign | 1 +
elsim/signatures/rageagainstthecage_exploit.sign | 1 +
elsim/signatures/roguesppush.sign | 1 +
elsim/signatures/smshider.sign | 1 +
elsim/signatures/smssend.sign | 1 +
elsim/signatures/sndapps.sign | 1 +
elsim/signatures/spitmo.sign | 1 +
elsim/signatures/spy32.sign | 1 +
elsim/signatures/wat.sign | 1 +
elsim/signatures/yzhcsms.b.sign | 1 +
elsim/signatures/yzhcsms.sign | 1 +
elsim/signatures/zitmo.sign | 1 +
elsim/signatures/zsone.sign | 1 +
elsim/tests/androappindb.py | 106 +
elsim/tests/androapptodb.py | 78 +
elsim/tests/example_text_sim.py | 84 +
elsim/tests/test_similarity.py | 373 +
examples/android/Invalid/Invalid.apk | Bin 0 -> 155034 bytes
examples/android/TC/AndroidManifest.xml | 15 +
examples/android/TC/androguard.xml | 30 +
examples/android/TC/bin/TC-debug.apk | Bin 0 -> 15775 bytes
examples/android/TC/bin/classes.dex | Bin 0 -> 8668 bytes
examples/android/TC/build.properties | 17 +
examples/android/TC/build.xml | 84 +
examples/android/TC/default.properties | 11 +
examples/android/TC/local.properties | 10 +
examples/android/TC/proguard.cfg | 34 +
examples/android/TC/res/drawable-hdpi/icon.png | Bin 0 -> 4147 bytes
examples/android/TC/res/drawable-ldpi/icon.png | Bin 0 -> 1723 bytes
examples/android/TC/res/drawable-mdpi/icon.png | Bin 0 -> 2574 bytes
examples/android/TC/res/layout/main.xml | 13 +
examples/android/TC/res/values/strings.xml | 4 +
.../android/TC/src/org/t0t0/androguard/TC/TCA.java | 33 +
.../TC/src/org/t0t0/androguard/TC/TCActivity.java | 15 +
.../android/TC/src/org/t0t0/androguard/TC/TCB.java | 32 +
.../android/TC/src/org/t0t0/androguard/TC/TCC.java | 30 +
.../android/TC/src/org/t0t0/androguard/TC/TCD.java | 33 +
.../android/TC/src/org/t0t0/androguard/TC/TCE.java | 75 +
.../TC/src/org/t0t0/androguard/TC/TCMod1.java | 78 +
.../TC/src/org/t0t0/androguard/TC/TestType1.java | 23 +
examples/android/TCDiff/AndroidManifest.xml | 15 +
examples/android/TCDiff/androguard.xml | 30 +
examples/android/TCDiff/bin/TCDiff-debug.apk | Bin 0 -> 15858 bytes
examples/android/TCDiff/bin/classes.dex | Bin 0 -> 8816 bytes
examples/android/TCDiff/build.properties | 17 +
examples/android/TCDiff/build.xml | 84 +
examples/android/TCDiff/default.properties | 11 +
examples/android/TCDiff/local.properties | 10 +
examples/android/TCDiff/proguard.cfg | 34 +
examples/android/TCDiff/res/drawable-hdpi/icon.png | Bin 0 -> 4147 bytes
examples/android/TCDiff/res/drawable-ldpi/icon.png | Bin 0 -> 1723 bytes
examples/android/TCDiff/res/drawable-mdpi/icon.png | Bin 0 -> 2574 bytes
examples/android/TCDiff/res/layout/main.xml | 13 +
examples/android/TCDiff/res/values/strings.xml | 4 +
.../TCDiff/src/org/t0t0/androguard/TCDiff/TCA.java | 39 +
.../src/org/t0t0/androguard/TCDiff/TCActivity.java | 15 +
.../TCDiff/src/org/t0t0/androguard/TCDiff/TCB.java | 32 +
.../TCDiff/src/org/t0t0/androguard/TCDiff/TCC.java | 30 +
.../TCDiff/src/org/t0t0/androguard/TCDiff/TCD.java | 33 +
.../TCDiff/src/org/t0t0/androguard/TCDiff/TCE.java | 80 +
.../src/org/t0t0/androguard/TCDiff/TCMod1.java | 86 +
.../src/org/t0t0/androguard/TCDiff/TestType1.java | 23 +
examples/android/TestsAndroguard/.classpath | 9 +
examples/android/TestsAndroguard/.project | 33 +
.../android/TestsAndroguard/AndroidManifest.xml | 26 +
.../android/TestsAndroguard/bin/TestActivity.apk | Bin 0 -> 174896 bytes
examples/android/TestsAndroguard/bin/classes.dex | Bin 0 -> 614592 bytes
.../TestsAndroguard/gen/tests/androguard/R.java | 23 +
.../TestsAndroguard/libs/android-support-v4.jar | Bin 0 -> 385685 bytes
.../android/TestsAndroguard/project.properties | 14 +
.../TestsAndroguard/res/drawable-hdpi/icon.png | Bin 0 -> 4147 bytes
.../TestsAndroguard/res/drawable-ldpi/icon.png | Bin 0 -> 1723 bytes
.../TestsAndroguard/res/drawable-mdpi/icon.png | Bin 0 -> 2574 bytes
.../android/TestsAndroguard/res/layout/main.xml | 12 +
.../android/TestsAndroguard/res/values/strings.xml | 5 +
.../TestsAndroguard/src/TestDefaultPackage.java | 82 +
.../src/tests/androguard/Eratosthene.java | 36 +
.../TestsAndroguard/src/tests/androguard/Lzss.java | 59 +
.../TestsAndroguard/src/tests/androguard/RC4.java | 41 +
.../src/tests/androguard/TestActivity.java | 373 +
.../src/tests/androguard/TestArr$ays.java | 44 +
.../src/tests/androguard/TestExceptions.java | 146 +
.../src/tests/androguard/TestIfs.java | 145 +
.../src/tests/androguard/TestInvoke.java | 50 +
.../src/tests/androguard/TestLoops.java | 238 +
.../src/tests/androguard/TestQuickSort.java | 45 +
.../src/tests/androguard/TestQuickSort2.java | 51 +
.../src/tests/androguard/TestSynthetic.java | 76 +
examples/axml/AndroidManifest-Chinese.xml | Bin 0 -> 12712 bytes
examples/axml/AndroidManifest-xmlns.xml | Bin 0 -> 26336 bytes
examples/axml/AndroidManifest.xml | Bin 0 -> 9256 bytes
examples/axml/test.xml | Bin 0 -> 1560 bytes
examples/axml/test1.xml | Bin 0 -> 6108 bytes
examples/axml/test2.xml | Bin 0 -> 4920 bytes
examples/axml/test3.xml | Bin 0 -> 4448 bytes
examples/dalvik/test/bin/Test-debug-unaligned.apk | Bin 0 -> 4969 bytes
examples/dalvik/test/bin/Test-debug.apk | Bin 0 -> 4970 bytes
examples/dalvik/test/bin/Test.ap_ | Bin 0 -> 1919 bytes
examples/dalvik/test/bin/classes.dex | Bin 0 -> 2980 bytes
examples/dalvik/test/bin/classes/Test1.class | Bin 0 -> 1055 bytes
.../classes/org/t0t0/androguard/test/R$attr.class | Bin 0 -> 358 bytes
.../org/t0t0/androguard/test/R$layout.class | Bin 0 -> 412 bytes
.../org/t0t0/androguard/test/R$string.class | Bin 0 -> 416 bytes
.../bin/classes/org/t0t0/androguard/test/R.class | Bin 0 -> 469 bytes
.../classes/org/t0t0/androguard/test/Test1.class | Bin 0 -> 1105 bytes
.../org/t0t0/androguard/test/TestActivity.class | Bin 0 -> 661 bytes
examples/dalvik/test/bin/classes_output.dex | Bin 0 -> 2980 bytes
examples/obfu/classes_tc.dex | Bin 0 -> 7120 bytes
examples/obfu/classes_tc.jar | Bin 0 -> 7986 bytes
examples/obfu/classes_tc.sign | 1 +
examples/obfu/classes_tc_dasho.dex | Bin 0 -> 6680 bytes
examples/obfu/classes_tc_dasho.jar | Bin 0 -> 6241 bytes
examples/obfu/classes_tc_diff.dex | Bin 0 -> 7240 bytes
examples/obfu/classes_tc_diff.jar | Bin 0 -> 8132 bytes
examples/obfu/classes_tc_diff_dasho.dex | Bin 0 -> 6756 bytes
examples/obfu/classes_tc_diff_dasho.jar | Bin 0 -> 6282 bytes
examples/obfu/classes_tc_mark1.dex | Bin 0 -> 7120 bytes
examples/obfu/classes_tc_mark1.jar | Bin 0 -> 7866 bytes
examples/obfu/classes_tc_proguard.dex | Bin 0 -> 7452 bytes
examples/obfu/classes_tc_proguard.jar | Bin 0 -> 8035 bytes
examples/obfu/dbsample | 1 +
setup.py | 14 +
tests/test_arsc.py | 98 +
tests/test_axml.py | 97 +
tests/test_dex.py | 108 +
tests/test_ins.py | 133 +
tests/test_sign.py | 54 +
tests/test_types.py | 182 +
tools/api/androapi.py | 213 +
tools/api/androapi_format.py | 140 +
tools/api/dvm_permissions_unformatted.py | 656 +
tools/api/permissions_by_hand.py | 28 +
tools/permissions/extract_aosp_permissions.py | 229 +
.../permissions/extract_api_permission_mappings.py | 254 +
398 files changed, 208576 insertions(+)
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..3072e6f
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,2 @@
+*.pyc
+*.pyo
\ No newline at end of file
diff --git a/.hgsub b/.hgsub
new file mode 100644
index 0000000..a742635
--- /dev/null
+++ b/.hgsub
@@ -0,0 +1 @@
+elsim = https://code.google.com/p/elsim/
diff --git a/.hgsubstate b/.hgsubstate
new file mode 100644
index 0000000..0aea278
--- /dev/null
+++ b/.hgsubstate
@@ -0,0 +1 @@
+ceadaf0d341fb0cc3c46fbafcd474a6f2c3ed320 elsim
diff --git a/CHANGELOG b/CHANGELOG
new file mode 100644
index 0000000..e494ae8
--- /dev/null
+++ b/CHANGELOG
@@ -0,0 +1,27 @@
+1.9:
+ - fix AXML bugs
+ - add ARSC support
+ - add sublimetext plugin
+ - remove useless dependencies (networkx, pygments)
+ - improve decompiler
+ - fix various bugs for python2.6
+ - add a tool (androdis) to disasm a dex file at a specific offset
+
+1.6:
+ - fix doc
+ - add auto analysis
+ - comunity
+
+1.5.1:
+ DAD:
+ - Propagatation pass has been updated
+ - Switches with fallthrough are handled
+ Core:
+ - fix and add the zipmodule python
+ - fix bugs in search of packages
+ - fix bugs in show_*
+ - fix bug in ganalysis.py
+
+1.5: stable release
+
+
diff --git a/LICENCE-2.0 b/LICENCE-2.0
new file mode 100644
index 0000000..f433b1a
--- /dev/null
+++ b/LICENCE-2.0
@@ -0,0 +1,177 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..efb4ee2
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,13 @@
+CD = cd
+RM = rm -f
+
+
+all : LIBS
+
+LIBS :
+# cd androguard/core/bytecodes/libdvm && make
+ cd elsim && make
+
+clean :
+# cd androguard/core/bytecodes/libdvm && make clean
+ cd elsim && make clean
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..314703c
--- /dev/null
+++ b/README.md
@@ -0,0 +1,54 @@
+# Androguard
+
+## Features
+
+Androguard is a full python tool to play with Android files.
+
+* DEX, ODEX
+* APK
+* Android's binary xml
+* Disassemble DEX/ODEX bytecodes
+* Decompiler DEX files
+
+##1. Authors: Androguard Team
+
+Androguard + tools: Anthony Desnos (desnos at t0t0.fr).
+
+DAD (DAD is A Decompiler): Geoffroy Gueguen (geoffroy dot gueguen at gmail dot com)
+
+
+##2. Licenses
+
+* Androguard
+
+Copyright (C) 2012 - 2015, Anthony Desnos (desnos at t0t0.fr)
+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.
+
+* DAD
+
+Copyright (C) 2012 - 2015, Geoffroy Gueguen (geoffroy dot gueguen at gmail dot com)
+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.
diff --git a/androarsc.py b/androarsc.py
new file mode 100755
index 0000000..e3b9038
--- /dev/null
+++ b/androarsc.py
@@ -0,0 +1,90 @@
+#!/usr/bin/env python
+
+# This file is part of Androguard.
+#
+# Copyright (C) 2012, Anthony Desnos <desnos at t0t0.fr>
+# All rights reserved.
+#
+# Androguard is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# Androguard is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with Androguard. If not, see <http://www.gnu.org/licenses/>.
+
+import sys
+from optparse import OptionParser
+from xml.dom import minidom
+import codecs
+
+from androguard.core import androconf
+from androguard.core.bytecodes import apk
+from androguard.util import read
+
+
+option_0 = { 'name' : ('-i', '--input'), 'help' : 'filename input (APK or android resources(arsc))', 'nargs' : 1 }
+option_1 = { 'name' : ('-p', '--package'), 'help' : 'select the package (optional)', 'nargs' : 1 }
+option_2 = { 'name' : ('-l', '--locale'), 'help' : 'select the locale (optional)', 'nargs' : 1 }
+option_3 = { 'name' : ('-t', '--type'), 'help' : 'select the type (string, interger, public, ...)', 'nargs' : 1 }
+option_4 = { 'name' : ('-o', '--output'), 'help' : 'filename output', 'nargs' : 1 }
+option_5 = { 'name' : ('-v', '--version'), 'help' : 'version of the API', 'action' : 'count' }
+options = [option_0, option_1, option_2, option_3, option_4, option_5]
+
+
+def main(options, arguments):
+ if options.input != None:
+ buff = ""
+
+ arscobj = None
+ ret_type = androconf.is_android(options.input)
+ if ret_type == "APK":
+ a = apk.APK(options.input)
+ arscobj = a.get_android_resources()
+ elif ret_type == "ARSC":
+ arscobj = apk.ARSCParser(read(options.input))
+ else:
+ print "Unknown file type"
+ return
+
+ if not options.package and not options.type and not options.locale:
+ buff = ""
+ for package in arscobj.get_packages_names():
+ buff += package + "\n"
+ for locale in arscobj.get_locales(package):
+ buff += "\t" + repr(locale) + "\n"
+ for ttype in arscobj.get_types(package, locale):
+ buff += "\t\t" + ttype + "\n"
+
+ else:
+ package = options.package or arscobj.get_packages_names()[0]
+ ttype = options.type or "public"
+ locale = options.locale or '\x00\x00'
+
+ buff = minidom.parseString(getattr(arscobj, "get_" + ttype + "_resources")(package, locale)).toprettyxml()
+
+ if options.output != None:
+ fd = codecs.open(options.output, "w", "utf-8")
+ fd.write(buff)
+ fd.close()
+ else:
+ print buff
+
+ elif options.version != None:
+ print "Androarsc version %s" % androconf.ANDROGUARD_VERSION
+
+if __name__ == "__main__":
+ parser = OptionParser()
+ for option in options:
+ param = option['name']
+ del option['name']
+ parser.add_option(*param, **option)
+
+ options, arguments = parser.parse_args()
+ sys.argv[:] = arguments
+ main(options, arguments)
diff --git a/androauto.py b/androauto.py
new file mode 100755
index 0000000..916f34a
--- /dev/null
+++ b/androauto.py
@@ -0,0 +1,60 @@
+#!/usr/bin/env python
+
+# This file is part of Androguard.
+#
+# Copyright (C) 2012, Anthony Desnos <desnos at t0t0.fr>
+# All rights reserved.
+#
+# Androguard is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# Androguard is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with Androguard. If not, see <http://www.gnu.org/licenses/>.
+
+import sys
+
+from optparse import OptionParser
+from androguard.core.analysis import auto
+from androguard.core.androconf import set_debug
+
+option_0 = {'name': ('-d', '--directory'), 'help': 'directory input', 'nargs': 1}
+option_1 = {'name': ('-v', '--verbose'), 'help': 'add debug', 'action': 'count'}
+options = [option_0, option_1]
+
+
+class AndroLog(object):
+ def __init__(self, id_file, filename):
+ self.id_file = id_file
+
+
+def main(options, arguments):
+ if options.verbose:
+ set_debug()
+
+ if options.directory:
+ settings = {
+ "my": auto.DirectoryAndroAnalysis(options.directory),
+ "log": AndroLog,
+ "max_fetcher": 3,
+ }
+
+ aa = auto.AndroAuto(settings)
+ aa.go()
+
+if __name__ == "__main__":
+ parser = OptionParser()
+ for option in options:
+ param = option['name']
+ del option['name']
+ parser.add_option(*param, **option)
+
+ options, arguments = parser.parse_args()
+ sys.argv[:] = arguments
+ main(options, arguments)
diff --git a/androaxml.py b/androaxml.py
new file mode 100755
index 0000000..735a836
--- /dev/null
+++ b/androaxml.py
@@ -0,0 +1,71 @@
+#!/usr/bin/env python
+
+# This file is part of Androguard.
+#
+# Copyright (C) 2012, Anthony Desnos <desnos at t0t0.fr>
+# All rights reserved.
+#
+# Androguard is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# Androguard is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with Androguard. If not, see <http://www.gnu.org/licenses/>.
+
+import sys
+from optparse import OptionParser
+from xml.dom import minidom
+import codecs
+
+from androguard.core import androconf
+from androguard.core.bytecodes import apk
+from androguard.util import read
+
+
+option_0 = { 'name' : ('-i', '--input'), 'help' : 'filename input (APK or android\'s binary xml)', 'nargs' : 1 }
+option_1 = { 'name' : ('-o', '--output'), 'help' : 'filename output of the xml', 'nargs' : 1 }
+option_2 = { 'name' : ('-v', '--version'), 'help' : 'version of the API', 'action' : 'count' }
+options = [option_0, option_1, option_2]
+
+
+def main(options, arguments):
+ if options.input != None:
+ buff = ""
+
+ ret_type = androconf.is_android(options.input)
+ if ret_type == "APK":
+ a = apk.APK(options.input)
+ buff = a.get_android_manifest_xml().toprettyxml(encoding="utf-8")
+ elif ".xml" in options.input:
+ ap = apk.AXMLPrinter(read(options.input))
+ buff = minidom.parseString(ap.get_buff()).toprettyxml(encoding="utf-8")
+ else:
+ print "Unknown file type"
+ return
+
+ if options.output != None:
+ fd = codecs.open(options.output, "w", "utf-8")
+ fd.write( buff )
+ fd.close()
+ else:
+ print buff
+
+ elif options.version != None:
+ print "Androaxml version %s" % androconf.ANDROGUARD_VERSION
+
+if __name__ == "__main__":
+ parser = OptionParser()
+ for option in options:
+ param = option['name']
+ del option['name']
+ parser.add_option(*param, **option)
+
+ options, arguments = parser.parse_args()
+ sys.argv[:] = arguments
+ main(options, arguments)
diff --git a/androcsign.py b/androcsign.py
new file mode 100755
index 0000000..ae947ff
--- /dev/null
+++ b/androcsign.py
@@ -0,0 +1,68 @@
+#!/usr/bin/env python
+
+# This file is part of Androguard.
+#
+# Copyright (C) 2012, Anthony Desnos <desnos at t0t0.fr>
+# All rights reserved.
+#
+# Androguard is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# Androguard is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with Androguard. If not, see <http://www.gnu.org/licenses/>.
+
+import sys
+
+from androguard.core import androconf
+from androguard.util import read
+
+sys.path.append("./elsim/")
+from elsim.elsign import dalvik_elsign
+
+from optparse import OptionParser
+
+option_0 = { 'name' : ('-i', '--input'), 'help' : 'file : use this filename', 'nargs' : 1 }
... 210214 lines suppressed ...
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/androguard.git
More information about the Python-modules-commits
mailing list