rapid7/metasploit-framework

View on GitHub

Showing 4,113 of 21,757 total issues

File constants.rb has 1171 lines of code (exceeds 250 allowed). Consider refactoring.
Open

module Rex
module Proto
module SMB
class Constants

Severity: Major
Found in lib/rex/proto/smb/constants.rb - About 3 days to fix

    Method run has 602 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      def run
        return if not check_dependencies
    
        begin
          # Get all values from v$parameter
    Severity: Major
    Found in modules/auxiliary/admin/oracle/oraenum.rb - About 3 days to fix

      File rdp.rb has 1073 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      module Msf
      
      ###
      #
      # This module exposes methods for interacting with a remote RDP service
      Severity: Major
      Found in lib/msf/core/exploit/remote/rdp.rb - About 2 days to fix

        Method cmd_wmap_run has 541 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

              def cmd_wmap_run(*args)
                # Stop everything
                self.masstop = false
                self.killwhenstop = true
        
        
        Severity: Major
        Found in plugins/wmap.rb - About 2 days to fix

          File windows_secrets_dump.rb has 1041 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          require 'ruby_smb/dcerpc/client'
          
          class MetasploitModule < Msf::Auxiliary
            include Msf::Exploit::Remote::SMB::Client::Authenticated
            include Msf::Exploit::Remote::DCERPC
          Severity: Major
          Found in modules/auxiliary/gather/windows_secrets_dump.rb - About 2 days to fix

            File rpc_db.rb has 1013 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            module Msf
            module RPC
            class RPC_Db < RPC_Base
            
            private
            Severity: Major
            Found in lib/msf/core/rpc/v10/rpc_db.rb - About 2 days to fix

              File sys.rb has 1012 lines of code (exceeds 250 allowed). Consider refactoring.
              Open

              require 'rex/post/meterpreter'
              require 'rex/post/meterpreter/extensions/stdapi/command_ids'
              
              module Rex
              module Post
              Severity: Major
              Found in lib/rex/post/meterpreter/ui/console/command_dispatcher/stdapi/sys.rb - About 2 days to fix

                Method create_library has 501 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                  def self.create_library(constant_manager, library_path = 'ws2_32')
                    dll = Library.new(library_path, constant_manager)
                
                    dll.add_function('getaddrinfo', 'DWORD',[
                      ["PCHAR","pNodeName","in"],

                  File error.rb has 970 lines of code (exceeds 250 allowed). Consider refactoring.
                  Open

                  class RbMysql
                    class Error < StandardError
                      ERRNO = 0
                  
                      def self.define_error_class(prefix_re)
                  Severity: Major
                  Found in lib/rbmysql/error.rb - About 2 days to fix

                    File navigation.rb has 955 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    def without_prefix(prefix)
                      proc { |value| value.sub(/^#{prefix}/, '') }
                    end
                    
                    =begin
                    Severity: Major
                    Found in docs/navigation.rb - About 2 days to fix

                      File webkit_createthis.rb has 934 lines of code (exceeds 250 allowed). Consider refactoring.
                      Open

                      class MetasploitModule < Msf::Exploit::Remote
                        Rank = ManualRanking
                      
                        include Msf::Post::File
                        include Msf::Exploit::EXE
                      Severity: Major
                      Found in modules/exploits/apple_ios/browser/webkit_createthis.rb - About 2 days to fix

                        Method asm_reverse_winhttp has 458 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                          def asm_reverse_winhttp(opts={})
                        
                            retry_count       = [opts[:retry_count].to_i, 1].max
                            verify_ssl        = nil
                            encoded_cert_hash = nil
                        Severity: Major
                        Found in lib/msf/core/payload/windows/reverse_win_http.rb - About 2 days to fix

                          Method asm_reverse_winhttp has 456 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                            def asm_reverse_winhttp(opts={})
                          
                              retry_count       = [opts[:retry_count].to_i, 1].max
                              verify_ssl        = nil
                              encoded_cert_hash = nil
                          Severity: Major
                          Found in lib/msf/core/payload/windows/x64/reverse_win_http_x64.rb - About 2 days to fix

                            Method description has 442 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                              def self.description(code)
                            
                                case code
                                when SUCCESS
                                  "The operation completed successfully."
                            Severity: Major
                            Found in lib/msf/windows_error.rb - About 2 days to fix

                              Method kernel_mode_payload has 438 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                def kernel_mode_payload
                              
                                  # Windows x64 kernel shellcode from ring 0 to ring 3 by sleepya
                                  #
                                  # This shellcode was written originally for eternalblue exploits
                              Severity: Major
                              Found in modules/exploits/windows/rdp/cve_2019_0708_bluekeep_rce.rb - About 2 days to fix

                                File exceptions.rb has 838 lines of code (exceeds 250 allowed). Consider refactoring.
                                Open

                                module Rex
                                module Proto
                                module SMB
                                module Exceptions
                                
                                
                                Severity: Major
                                Found in lib/rex/proto/smb/exceptions.rb - About 2 days to fix

                                  Method run has 401 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                    def run
                                  
                                      loot = ""
                                      uri = "/"
                                      uri << (datastore['YEAR']).to_s if datastore['YEAR'].to_s != ""
                                  Severity: Major
                                  Found in modules/auxiliary/gather/corpwatch_lookup_id.rb - About 2 days to fix

                                    File lm2ntcrack.rb has 822 lines of code (exceeds 250 allowed). Consider refactoring.
                                    Open

                                    msfbase = __FILE__
                                    while File.symlink?(msfbase)
                                      msfbase = File.expand_path(File.readlink(msfbase), File.dirname(msfbase))
                                    end
                                    
                                    
                                    Severity: Major
                                    Found in tools/password/lm2ntcrack.rb - About 1 day to fix

                                      Method initialize has 390 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                        def initialize(info = {})
                                          super(merge_info(info,
                                            'Name'          => 'NetWare Command Shell',
                                            'Description'   => 'Connect to the NetWare console (staged)',
                                            'Author'        => 'toto',
                                      Severity: Major
                                      Found in modules/payloads/stages/netware/shell.rb - About 1 day to fix

                                        File cve_2019_0708_bluekeep_rce.rb has 798 lines of code (exceeds 250 allowed). Consider refactoring.
                                        Open

                                        class MetasploitModule < Msf::Exploit::Remote
                                          prepend Msf::Exploit::Remote::AutoCheck
                                        
                                          Rank = ManualRanking
                                        
                                        
                                        Severity: Major
                                        Found in modules/exploits/windows/rdp/cve_2019_0708_bluekeep_rce.rb - About 1 day to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language