Giter Club home page Giter Club logo

apkfile's People

Contributors

calebfenton avatar jariq 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  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  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  avatar  avatar  avatar  avatar

apkfile's Issues

Streaming an Apkfile to json results stackoverflow error condition

First of all, Thanks for the wonderful project. I have tried to test it and tried it against the sieve.apk file (https://github.com/mwrlabs/drozer/releases/download/2.3.4/sieve.apk)

with the sample code provided in the github example.
Writer writer = new OutputStreamWriter(System.out); gson.toJson(apkFile, writer);

The code resulted in java.lang.StackoverflowError
Exception in thread "main" java.lang.StackOverflowError
at com.google.gson.internal.$Gson$Types$WildcardTypeImpl.equals($Gson$Types.java:567)
at java.util.Arrays.equals(Arrays.java:2829)

I am running the latest build which includes the fix for the above mentioned behavior.
5b6ce0d

Thanks.

build error help

Hi Caleb,

Im getting the follow errors when running:

test@test-VirtualBox:~/Downloads/apkfile$ ./gradlew build
Starting a Gradle Daemon, 1 stopped Daemon could not be reused, use --status for details
:compileJava
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:19: warning: RDN is internal proprietary API and may be removed in a future release
import sun.security.x509.RDN;
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:20: warning: X500Name is internal proprietary API and may be removed in a future release
import sun.security.x509.X500Name;
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:19: warning: RDN is internal proprietary API and may be removed in a future release
import sun.security.x509.RDN;
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:20: warning: X500Name is internal proprietary API and may be removed in a future release
import sun.security.x509.X500Name;
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:19: warning: RDN is internal proprietary API and may be removed in a future release
import sun.security.x509.RDN;
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:20: warning: X500Name is internal proprietary API and may be removed in a future release
import sun.security.x509.X500Name;
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:19: warning: RDN is internal proprietary API and may be removed in a future release
import sun.security.x509.RDN;
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:20: warning: X500Name is internal proprietary API and may be removed in a future release
import sun.security.x509.X500Name;
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/utils/Utils.java:40: warning: [unchecked] unchecked call to adjustOrPutValue(K,int,int) as a member of the raw type TObjectIntMap
dest.adjustOrPutValue(key, value, value);
^
where K is a type-variable:
K extends Object declared in interface TObjectIntMap
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/utils/Utils.java:47: warning: [unchecked] unchecked call to adjustOrPutValue(K,long,long) as a member of the raw type TObjectLongMap
dest.adjustOrPutValue(key, value, value);
^
where K is a type-variable:
K extends Object declared in interface TObjectLongMap
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:37: warning: [unchecked] unchecked call to getMatches(Selector) as a member of the raw type Store
Collection matches = data.getCertificates().getMatches(null);
^
where T is a type-variable:
T extends Object declared in interface Store
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:37: warning: [unchecked] unchecked conversion
Collection matches = data.getCertificates().getMatches(null);
^
required: Collection
found: Collection
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:39: error: incompatible types: org.bouncycastle.asn1.x500.X500Name cannot be converted to sun.security.x509.X500Name
allRdns.add(buildRdns(holder.getSubject(), holder.getIssuer()));
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:45: warning: X500Name is internal proprietary API and may be removed in a future release
private static SubjectAndIssuerRdns buildRdns(X500Name subject, X500Name issuer) {
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:45: warning: X500Name is internal proprietary API and may be removed in a future release
private static SubjectAndIssuerRdns buildRdns(X500Name subject, X500Name issuer) {
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:56: error: cannot find symbol
for (RDN rdn : subject.getRDNs()) {
^
symbol: method getRDNs()
location: variable subject of type X500Name
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:56: warning: RDN is internal proprietary API and may be removed in a future release
for (RDN rdn : subject.getRDNs()) {
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:57: error: cannot find symbol
for (AttributeTypeAndValue typeAndValue : rdn.getTypesAndValues()) {
^
symbol: method getTypesAndValues()
location: variable rdn of type RDN
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:65: error: cannot find symbol
for (RDN rdn : subject.getRDNs()) {
^
symbol: method getRDNs()
location: variable subject of type X500Name
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:65: warning: RDN is internal proprietary API and may be removed in a future release
for (RDN rdn : subject.getRDNs()) {
^
/home/test/Downloads/apkfile/src/main/java/org/cf/apkfile/apk/Certificate.java:66: error: cannot find symbol
for (AttributeTypeAndValue typeAndValue : rdn.getTypesAndValues()) {
^
symbol: method getTypesAndValues()
location: variable rdn of type RDN
Note: Some messages have been simplified; recompile with -Xdiags:verbose to get full output
5 errors
16 warnings
:compileJava FAILED

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':compileJava'.

Compilation failed; see the compiler error output for details.

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Total time: 8.626 secs

2 Questions Regarding the Implementation of apkfile

Hi,

First of all, thank you for your wonderful work.
I have 2 questions:

  1. Is apkfile thread-safe? that is, analyzing different apks simultaneously with different threads may present problems? reading the code, I couldn't find a reason that it wouldn't. It doesn't seem to rely on shared data structures, for example, while analyzing an apk.

  2. I noticed that the collections used to hold the extracted features (for example, the app's activities) are of type LinkedList. What are your thoughts about using ArrayLists for better performance? Arrays are much more cache-friendly than LinkedList, and though admittedly I haven't tried it, I think this minor change might improve performance.

Thanks!
Ben

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.