hackedteam/vector-exploit

View on GitHub

Showing 219 of 389 total issues

Function decrypt has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
Open

    def decrypt(self, iput, key, size):
        output = [0] * 16
        # the number of rounds
        nbrRounds = 0
        # the 128 bit block to decode
Severity: Minor
Found in src/ht-webkit-Android4-src/precompiled/release/slowaes.py - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function encrypt has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
Open

    def encrypt(self, iput, key, size):
        output = [0] * 16
        # the number of rounds
        nbrRounds = 0
        # the 128 bit block to encode
Severity: Minor
Found in src/ht-webkit-Android4-src/ext/slowaes.py - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function decrypt has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
Open

    def decrypt(self, iput, key, size):
        output = [0] * 16
        # the number of rounds
        nbrRounds = 0
        # the 128 bit block to decode
Severity: Minor
Found in src/ht-webkit-Android4-src/ext/slowaes.py - About 1 hr to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function stage1_xml has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

def stage1_xml(base=0x6b503000, nextaddr=None):
    """
    Generates the exploit XML document. The parameter base must be an integer.
    """

Severity: Minor
Found in src/ht-webkit-Android4-src/precompiled/release/stage1_xml.py - About 1 hr to fix

    Function XSLTObject has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function XSLTObject(page, childrenaddr, nameaddr, elementaddr, xml) {
        if (page === undefined) {
        ERR("XSLTObject: A page object is required.");
        }
    
    
    Severity: Minor
    Found in src/ht-webkit-Android4-src/precompiled/debug/script.js - About 1 hr to fix

      Function bisect_check has 26 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function bisect_check(bisect_firsthalf, bisect_secondhalf, addr) {
          // INFO("bisect_check " + addr);
      
          var iframe = document.createElement("iframe");
      
      
      Severity: Minor
      Found in src/ht-webkit-Android4-src/precompiled/debug/script.js - About 1 hr to fix

        Function stage1_xml has 26 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        def stage1_xml(base=0x6b503000, nextaddr=None):
            """
            Generates the exploit XML document. The parameter base must be an integer.
            """
        
        
        Severity: Minor
        Found in src/edn2/2014-004-AndroidBrowser/stage1_xml.py - About 1 hr to fix

          Function stage1_xml has 26 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          def stage1_xml(base=0x6b503000, nextaddr=None):
              """
              Generates the exploit XML document. The parameter base must be an integer.
              """
          
          
          Severity: Minor
          Found in src/ht-webkit-Android4-src/src/stage1_xml.py - About 1 hr to fix

            Function stage1_xml has 26 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            def stage1_xml(base=0x6b503000, nextaddr=None):
                """
                Generates the exploit XML document. The parameter base must be an integer.
                """
            
            
            Severity: Minor
            Found in src/ht-webkit-Android4-src/precompiled/debug/stage1_xml.py - About 1 hr to fix

              Function __init__ has 7 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                  def __init__(self, info, start, src_start, size, folder, archive, maxsize=None):
              Severity: Major
              Found in ht-2013-002-Word/pylzma.egg/py7zlib.py - About 50 mins to fix

                Function call has 7 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                RCE.prototype.call = function(fn, r0, r1, r2, r3, r4, forking) {
                Severity: Major
                Found in src/ht-webkit-Android4-src/precompiled/debug/script.js - About 50 mins to fix

                  Function __init__ has 7 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                      def __init__(self, info, start, src_start, size, folder, archive, maxsize=None):
                  Severity: Major
                  Found in ht-2013-003-Powerpoint/pylzma.egg/py7zlib.py - About 50 mins to fix

                    Function __init__ has 7 arguments (exceeds 4 allowed). Consider refactoring.
                    Open

                        def __init__(self, info, start, src_start, size, folder, archive, maxsize=None):
                    Severity: Major
                    Found in ht-2013-004-IE/pylzma.egg/py7zlib.py - About 50 mins to fix

                      Function decrypt has 6 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                          def decrypt(self, cipherIn, originalsize, mode, key, size, IV):
                      Severity: Minor
                      Found in src/edn2/2014-004-AndroidBrowser/slowaes.py - About 45 mins to fix

                        Avoid deeply nested control flow statements.
                        Open

                                                if len(gadgets_retrieved) != 6:
                                                    firstStageSuccessful = False
                                                    ExploitHTTPHandler.send_empty_reply()
                        
                                                    logging.debug('Not enough gadgets {}'.format( len(gadgets_retrieved) ) )
                        Severity: Major
                        Found in src/ht-webkit-Android23/webkit_rc3_plus_tea.py - About 45 mins to fix

                          Avoid deeply nested control flow statements.
                          Open

                                                  for k in range(originalsize-start):
                                                      stringOut += chr(plaintext[k])
                                              else:
                          Severity: Major
                          Found in src/edn2/2014-004-AndroidBrowser/slowaes.py - About 45 mins to fix

                            Avoid deeply nested control flow statements.
                            Open

                                                with open(apk_path, 'rb') as f:
                                                    data = s.recv(1025)
                                                    if(data.strip() == "ready"):
                                                        time.sleep(2)
                                                        logging.info('Sending file {}..'.format(apk_path))
                            Severity: Major
                            Found in src/ht-webkit-Android23/exp_server.py - About 45 mins to fix

                              Avoid deeply nested control flow statements.
                              Open

                                                      if len(gadgets_retrieved) != 9:
                                                          firstStageSuccessful = False
                                                          ExploitHTTPHandler.send_empty_reply()
                                                          
                                                          logging.debug('Not enough gadgets {} '.format( len(gadgets_retrieved) ) )
                              Severity: Major
                              Found in src/ht-webkit-Android23/webkit_rc3_plus_tea.py - About 45 mins to fix

                                Function stage3_alternate has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                Open

                                function stage3_alternate(memobj, node, addr, page, libwebcore, libc) {
                                Severity: Minor
                                Found in src/ht-webkit-Android4-src/precompiled/debug/script.js - About 45 mins to fix

                                  Function forkingcall has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                  Open

                                  RCE.prototype.forkingcall = function(fn, r0, r1, r2, r3, r4) {
                                  Severity: Minor
                                  Found in src/ht-webkit-Android4-src/precompiled/debug/script.js - About 45 mins to fix
                                    Severity
                                    Category
                                    Status
                                    Source
                                    Language