droidproperties.py
def clear_fields(self):
        """Re-initialize all fields of the object - to default values"""
        self.file_nb_classes = 0
        self.file_nb_dir = 0
        self.file_size = 0
        self.file_small = False
        self.filetype = droidutil.UNKNOWN
        self.file_innerzips = False

        self.certificate.clear()
        self.certificate = {  'av' : False, \
                              'algo' : None, \
                              'debug': False, \
                              'dev' : False, \
                              'famous' : False, \
                              'serialno' : None, \
                              'country': droidcountry.country['unknown'],\
                              'owner' : None,\
                              'timestamp' : None, \
                              'year' : 0,\
                              'unknown_country' : False }

        self.manifest.clear()
        self.manifest = {
            'activities' : [], \
            'libraries' : [], \
            'listens_incoming_sms' : False,\
            'listens_outgoing_call' : False,\
            'maxSDK' : 0,\
            'main_activity': None, \
            'minSDK' : 0,\
            'package' : None, \
            'permissions' : [], \
            'providers' : [], \
            'receivers' : [], \
            'services' : [], \
            'swf' : False,\
            'targetSDK' : 0 }

        # automatically adding smali properties. 
        self.smali.clear()
        self.smaliconfig = droidconfig.droidconfig(droidconfig.SMALI_CONFIGFILE, self.verbose)
        for section in self.smaliconfig.get_sections():
            self.smali[section] = False

        # automatically adding wide properties
        self.wide.clear()
        self.wide['app_name'] = None
        self.wide['phonenumbers'] = []
        self.wide['urls'] = []
        self.wide['base64_strings'] = []
        self.wide['apk_zip_url'] = False
        self.wideconfig = droidconfig.droidconfig(droidconfig.WIDE_CONFIGFILE, self.verbose)
        for section in self.wideconfig.get_sections():
            self.wide[section] = False

        # automatically add ARM properties
        self.arm.clear()
        self.armconfig = droidconfig.droidconfig(droidconfig.ARM_CONFIGFILE, self.verbose)
        for section in self.armconfig.get_sections():
            self.arm[section] = False

        self.dex.clear()
        self.dex = { 'magic' : 0, \
                     'odex' : False, \
                    'magic_unknown' : False,\
                    'bad_sha1' : False,\
                    'bad_adler32' : False,\
                    'big_header': False,\
                    'thuxnder' : False
                    }

        # automatically set to False kit properties
        self.kits.clear()
        self.kitsconfig = droidconfig.droidconfig(droidconfig.KIT_CONFIGFILE, self.verbose)
        for section in self.kitsconfig.get_sections():
            self.kits[section] = False
        
        # END OF reinit to default values
Re-initialize all fields of the object - to default values
Re-initialize all fields of the object - to default values
Re - initialize all fields of the object - to default values
def clear_fields(self):
        self.file_nb_classes = 0
        self.file_nb_dir = 0
        self.file_size = 0
        self.file_small = False
        self.filetype = droidutil.UNKNOWN
        self.file_innerzips = False
        self.certificate.clear()
        self.certificate = {  'av' : False, \
                              'algo' : None, \
                              'debug': False, \
                              'dev' : False, \
                              'famous' : False, \
                              'serialno' : None, \
                              'country': droidcountry.country['unknown'],\
                              'owner' : None,\
                              'timestamp' : None, \
                              'year' : 0,\
                              'unknown_country' : False }
        self.manifest.clear()
        self.manifest = {
            'activities' : [], \
            'libraries' : [], \
            'listens_incoming_sms' : False,\
            'listens_outgoing_call' : False,\
            'maxSDK' : 0,\
            'main_activity': None, \
            'minSDK' : 0,\
            'package' : None, \
            'permissions' : [], \
            'providers' : [], \
            'receivers' : [], \
            'services' : [], \
            'swf' : False,\
            'targetSDK' : 0 }
        self.smali.clear()
        self.smaliconfig = droidconfig.droidconfig(droidconfig.SMALI_CONFIGFILE, self.verbose)
        for section in self.smaliconfig.get_sections():
            self.smali[section] = False
        self.wide.clear()
        self.wide['app_name'] = None
        self.wide['phonenumbers'] = []
        self.wide['urls'] = []
        self.wide['base64_strings'] = []
        self.wide['apk_zip_url'] = False
        self.wideconfig = droidconfig.droidconfig(droidconfig.WIDE_CONFIGFILE, self.verbose)
        for section in self.wideconfig.get_sections():
            self.wide[section] = False
        self.arm.clear()
        self.armconfig = droidconfig.droidconfig(droidconfig.ARM_CONFIGFILE, self.verbose)
        for section in self.armconfig.get_sections():
            self.arm[section] = False
        self.dex.clear()
        self.dex = { 'magic' : 0, \
                     'odex' : False, \
                    'magic_unknown' : False,\
                    'bad_sha1' : False,\
                    'bad_adler32' : False,\
                    'big_header': False,\
                    'thuxnder' : False
                    }
        self.kits.clear()
        self.kitsconfig = droidconfig.droidconfig(droidconfig.KIT_CONFIGFILE, self.verbose)
        for section in self.kitsconfig.get_sections():
            self.kits[section] = False
def clear_fields ( self ) : self . file_nb_classes = 0 self . file_nb_dir = 0 self . file_size = 0 self . file_small = False self . filetype = droidutil . UNKNOWN self . file_innerzips = False self . certificate . clear ( ) self . certificate = { 'av' : False , 'algo' : None , 'debug' : False , 'dev' : False , 'famous' : False , 'serialno' : None , 'country' : droidcountry . country [ 'unknown' ] , 'owner' : None , 'timestamp' : None , 'year' : 0 , 'unknown_country' : False } self . manifest . clear ( ) self . manifest = { 'activities' : [ ] , 'libraries' : [ ] , 'listens_incoming_sms' : False , 'listens_outgoing_call' : False , 'maxSDK' : 0 , 'main_activity' : None , 'minSDK' : 0 , 'package' : None , 'permissions' : [ ] , 'providers' : [ ] , 'receivers' : [ ] , 'services' : [ ] , 'swf' : False , 'targetSDK' : 0 } self . smali . clear ( ) self . smaliconfig = droidconfig . droidconfig ( droidconfig . SMALI_CONFIGFILE , self . verbose ) for section in self . smaliconfig . get_sections ( ) : self . smali [ section ] = False self . wide . clear ( ) self . wide [ 'app_name' ] = None self . wide [ 'phonenumbers' ] = [ ] self . wide [ 'urls' ] = [ ] self . wide [ 'base64_strings' ] = [ ] self . wide [ 'apk_zip_url' ] = False self . wideconfig = droidconfig . droidconfig ( droidconfig . WIDE_CONFIGFILE , self . verbose ) for section in self . wideconfig . get_sections ( ) : self . wide [ section ] = False self . arm . clear ( ) self . armconfig = droidconfig . droidconfig ( droidconfig . ARM_CONFIGFILE , self . verbose ) for section in self . armconfig . get_sections ( ) : self . arm [ section ] = False self . dex . clear ( ) self . dex = { 'magic' : 0 , 'odex' : False , 'magic_unknown' : False , 'bad_sha1' : False , 'bad_adler32' : False , 'big_header' : False , 'thuxnder' : False } self . kits . clear ( ) self . kitsconfig = droidconfig . droidconfig ( droidconfig . KIT_CONFIGFILE , self . verbose ) for section in self . kitsconfig . get_sections ( ) : self . kits [ section ] = False
Re-initialize all fields of the object - to default values
Re - initialize all fields of the object - to default values
"""Re-initialize all fields of the object - to default values""" # automatically adding smali properties.  # automatically adding wide properties # automatically add ARM properties # automatically set to False kit properties # END OF reinit to default values
self