Beispiel #1
0
    def do_attacksurface(args):
        """
        Description: Enumerates attacksurface for target APK

        Requirements: Loaded APK

        Usage: attacksurface
        """
        try:
            from framework.brains.apk.enumeration.attack_surface import AttackSurface
            if globals()["apk"] is not None:
                # Instantiate attacksurface
                # module
                #
                c = AttackSurface(globals()["apk"])
                c.run_enum_attack_surface()
            else:
                print(
                    t.red("[{0}] ".format(datetime.now())) +
                    t.white(enum.MODULE_UNAVAILABLE))
                print(
                    t.red("[{0}] ".format(datetime.now())) +
                    t.white(enum.ATTACKSURFACE_MODULE_MESSAGE))
        except ImportError as e:
            print(
                t.red("[{0}] ".format(datetime.now()) +
                      enum.IMPORT_ERROR_ATTACKSURFACE))
            Logger.run_logger(e.message)
Beispiel #2
0
    def do_attacksurface(args):

        """
        Description: Enumerates attacksurface for target APK

        Requirements: Loaded APK

        Usage: attacksurface
        """

        try:
            from framework.brains.apk.enumeration.attack_surface import AttackSurface
            c = AttackSurface(globals()["apk"])
            c.run_enum_attack_surface()
        except ImportError as e:
            print(t.red("[{0}] ".format(datetime.now()) + "Unable to import AttackSurface"))
            Logger.run_logger(e.message)
Beispiel #3
0
    def do_attacksurface(args):
        """
        Description: Enumerates attacksurface for target APK

        Requirements: Loaded APK

        Usage: attacksurface
        """

        try:
            from framework.brains.apk.enumeration.attack_surface import AttackSurface
            c = AttackSurface(globals()["apk"])
            c.run_enum_attack_surface()
        except ImportError as e:
            print(
                t.red("[{0}] ".format(datetime.now()) +
                      "Unable to import AttackSurface"))
            Logger.run_logger(e.message)
Beispiel #4
0
    def do_attacksurface(args):

        """
        Description: Enumerates attacksurface for target APK

        Requirements: Loaded APK

        Usage: attacksurface
        """

        try:
            from framework.brains.apk.enumeration.attack_surface import AttackSurface
            if globals()["apk"] is not None:
                c = AttackSurface(globals()["apk"])
                c.run_enum_attack_surface()
            else:
                print(t.red("[{0}] ".format(datetime.now())) +
                      t.white("Module not available"))
                print(t.red("[{0}] ".format(datetime.now())) +
                      t.white("You cannot run the attacksurface module without a loaded APK"))
        except ImportError as e:
            print(t.red("[{0}] ".format(datetime.now()) + "Unable to import AttackSurface"))
            Logger.run_logger(e.message)
Beispiel #5
0
    def do_attacksurface(args):
        """
        Description: Enumerates attacksurface for target APK

        Requirements: Loaded APK

        Usage: attacksurface
        """
        try:
            from framework.brains.apk.enumeration.attack_surface import AttackSurface

            if globals()["apk"] is not None:
                # Instantiate attacksurface
                # module
                #
                c = AttackSurface(globals()["apk"])
                c.run_enum_attack_surface()
            else:
                print(t.red("[{0}] ".format(datetime.now())) + t.white(enum.MODULE_UNAVAILABLE))
                print(t.red("[{0}] ".format(datetime.now())) + t.white(enum.ATTACKSURFACE_MODULE_MESSAGE))
        except ImportError as e:
            print(t.red("[{0}] ".format(datetime.now()) + enum.IMPORT_ERROR_ATTACKSURFACE))
            Logger.run_logger(e.message)