Git Product home page Git Product logo

Comments (11)

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
The second issue is probably related. Same applet, same code, except I am 
calling a.get_methods()


Traceback (most recent call last):
  File "./bla.py", line 23, in <module>
    for i in a.get_methods() :
  File "/home/spjsschl/androguard/androguard.py", line 474, in __getattr__
    return getattr(self.__a, value)
AttributeError: 'NoneType' object has no attribute 'get_methods'

Original comment by [email protected] on 29 Nov 2011 at 11:56

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
Ok I'm on it :)

Original comment by [email protected] on 30 Nov 2011 at 8:08

  • Changed state: Accepted

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
Can you try on the latest revision ?

Original comment by [email protected] on 1 Dec 2011 at 7:51

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
Sorry, seems my email from last week got lost. Thanks for working  on this.

I have tried the new version and both problems persist, there is no visible 
effect for the changes on my system.
Johannes

Original comment by [email protected] on 5 Dec 2011 at 7:13

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
Uhm not on my side:

ACC_PROTECTED json/Parser r Ljavax/swing/JList;
ACC_STATIC json/Parser exp [Ljava/lang/String;
ACC_PRIVATE json/Parser jsonData Ljava/lang/String;
ACC_PROTECTED json/Parser d Ljava/util/HashSet;
ACC_PRIVATE json/Parser postfix Ljava/lang/String;
ACC_PROTECTED ACC_STATIC json/Parser dc Ljava/lang/String;
ACC_PUBLIC ACC_STATIC json/Parser v Ljava/lang/String;
ACC_PROTECTED ACC_STATIC json/Parser pt Ljava/lang/String;
ACC_PROTECTED ACC_STATIC json/Parser pfx Ljava/lang/String;
ACC_PUBLIC ACC_STATIC ACC_FINAL json/SmartyPointer e Ljava/lang/String;
ACC_PUBLIC ACC_STATIC ACC_FINAL json/SmartyPointer c Ljava/lang/Class;
ACC_PUBLIC ACC_STATIC ACC_FINAL json/SmartyPointer g Ljava/lang/String;
ACC_PUBLIC ACC_STATIC ACC_FINAL json/SmartyPointer n S
ACC_PUBLIC ACC_STATIC json/ThreadParser m Ljava/lang/reflect/Method;
ACC_PROTECTED ACC_STATIC json/ThreadParser ctr I
ACC_PUBLIC ACC_STATIC json/ThreadParser rw [B
ACC_PRIVATE json/ThreadParser s Ljava/lang/String;
ACC_PRIVATE json/XML j Ljava/util/HashSet;
ACC_PRIVATE ACC_STATIC json/XML i [S
ACC_PUBLIC ACC_STATIC json/XML e Ljava/lang/String;
ACC_FINAL json/XML database Ljson/Parser;



#!/usr/bin/env python

import sys, hashlib

PATH_INSTALL = "./"
sys.path.append(PATH_INSTALL + "/core")
sys.path.append(PATH_INSTALL + "/core/bytecodes")
sys.path.append(PATH_INSTALL + "/core/bytecodes/libdvm/")
sys.path.append(PATH_INSTALL + "/core/analysis")
sys.path.append(PATH_INSTALL + "/core/analysis/libsign")
sys.path.append(PATH_INSTALL + "/classification")

import androguard, jvm

TEST = "./field.jar"

x = jvm.JAR( TEST )                                                             


bc = x.get_classes()

for j in bc :
    vm = jvm.JVMFormat(j[1])

    for i in vm.get_fields() :
        print i.get_access(), i.get_class_name(), i.get_name(), i.get_descriptor()

Original comment by [email protected] on 6 Dec 2011 at 7:09

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
Your program works even though it has shorter output compared yo your example 
run:

ACC_PRIVATE json/XML j Ljava/util/HashSet;
ACC_PRIVATE ACC_STATIC json/XML i [S
ACC_PUBLIC ACC_STATIC json/XML e Ljava/lang/String;
ACC_FINAL json/XML database Ljson/Parser;

The program that I sent to you initially (and that I used for my testing) still 
does not work:
#!/usr/bin/env python

import sys

PATH_INSTALL = "/home/spjsschl/androguard/"
sys.path.append(PATH_INSTALL)
sys.path.append(PATH_INSTALL + "/core")
sys.path.append(PATH_INSTALL + "/core/bytecodes")
sys.path.append(PATH_INSTALL + "/core/analysis")

import androguard

a = androguard.AndroguardS(sys.argv[1])

# SHOW CLASS (verbose)
#a.show()

# SHOW FIELDS
for i in a.get_fields() :
    print i.get_access(), i.get_name(), i.get_descriptor()

## SHOW METHODS
#for i in a.get_methods() :
#   print i.get_access(), i.get_name(), i.get_descriptor()

output:
Traceback (most recent call last):
  File "./bla.py", line 19, in <module>
    for i in a.get_fields() :
  File "/home/spjsschl/androguard/androguard.py", line 474, in __getattr__
    return getattr(self.__a, value)
AttributeError: 'NoneType' object has no attribute 'get_fields'


Original comment by [email protected] on 6 Dec 2011 at 8:16

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
Yes I know, could you try with mine ?

Original comment by [email protected] on 7 Dec 2011 at 7:16

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
I ran your code, see the output in my previous mail.

It is somehow shorter than your example output.

Original comment by [email protected] on 8 Dec 2011 at 7:09

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
Could you try by changing AndroguardS with JAR + JavaVMFormat ?

Original comment by [email protected] on 9 Dec 2011 at 12:21

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024
any news ?

Original comment by [email protected] on 3 Feb 2012 at 6:18

from androguard.

GoogleCodeExporter avatar GoogleCodeExporter commented on May 30, 2024

Original comment by [email protected] on 5 Aug 2012 at 9:40

  • Changed state: Fixed

from androguard.

Related Issues (20)

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.