rapid7/metasploit-framework

View on GitHub

Showing 7,361 of 22,177 total issues

Avoid deeply nested control flow statements.
Open

                  if srcres and srcres.body.length > 0
                    if datastore['SHOW_SOURCE']
                      print_status(srcres.body)
                    end

Severity: Major
Found in modules/auxiliary/scanner/http/svn_scanner.rb - About 45 mins to fix

    Avoid deeply nested control flow statements.
    Open

                    result.connection.close unless result.connection.nil?
    Severity: Major
    Found in modules/auxiliary/scanner/mysql/mysql_login.rb - About 45 mins to fix

      Avoid deeply nested control flow statements.
      Open

                      rescue ::Timeout::Error, ::Errno::EPIPE
      Severity: Major
      Found in modules/auxiliary/scanner/http/svn_scanner.rb - About 45 mins to fix

        Avoid deeply nested control flow statements.
        Open

                      if @error_cnt >= @nr_errors
                        print_status("System does not respond - exiting now\n")
                        @stopprocess = true
                        print_error("Error: #{e.class} #{e} #{e.backtrace}\n")
                        return
        Severity: Major
        Found in modules/auxiliary/fuzzers/ftp/ftp_pre_post.rb - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                          if fieldname == "" and fieldid != ""
                            fieldname = fieldid
                          end
          Severity: Major
          Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

                              if thisfield.match(/^value=/)
                                # special case
                                location = fielddata[0].index(thisfield)
                                delta = fielddata[0].size - location
                                remaining = fielddata[0][location,delta]
            Severity: Major
            Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                                if thisfield.match(/^id=/)
                                  fieldid = get_field_val(thisfield)
                                end
              Severity: Major
              Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                              if @error_cnt >= @nr_errors
                                @error_cnt = 0
                              end
                Severity: Major
                Found in modules/auxiliary/fuzzers/ftp/ftp_pre_post.rb - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                                    if thisfield.match(/^type=/)
                                      fieldtype = get_field_val(thisfield)
                                    end
                  Severity: Major
                  Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                                  if (e.class.name == 'Rex::ConnectionRefused') or (e.class.name == 'EOFError') or (e.class.name == 'Errno::ECONNRESET' and datastore['CONNRESET']) or (e.class.name == 'Errno::EPIPE')
                                    if @error_cnt >= @nr_errors
                                      print_status("System does not respond - exiting now\n")
                                      @stopprocess = true
                                      print_error("Error: #{e.class} #{e} #{e.backtrace}\n")
                    Severity: Major
                    Found in modules/auxiliary/fuzzers/ftp/ftp_pre_post.rb - About 45 mins to fix

                      Avoid deeply nested control flow statements.
                      Open

                                        if currfieldmark == "<select" and thisfield.match(/^class=/)
                                          fieldtype = get_field_val(thisfield)
                                        end
                      Severity: Major
                      Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

                        Avoid deeply nested control flow statements.
                        Open

                                        if thisfield[:name]
                                          if fuzz_this_field(thisfield[:name],thisfield[:type]) == 1
                                            print_status("    - Fuzzing field #{thisfield[:name]}")
                                            do_fuzz_field(thisform,thisfield[:name])
                                            init_fuzzdata()
                        Severity: Major
                        Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

                          Avoid deeply nested control flow statements.
                          Open

                                        if datastore['ExpandCrash']
                                          print_status("Crash string : #{prepend}#{evil}")
                                        else
                                          print_status("Crash string : #{prepend}#{evilstr} x #{count}")
                                        end
                          Severity: Major
                          Found in modules/auxiliary/fuzzers/ftp/ftp_pre_post.rb - About 45 mins to fix

                            Avoid deeply nested control flow statements.
                            Open

                                            if fieldid == "" and fieldname != ""
                                              fieldid = fieldname
                                            end
                            Severity: Major
                            Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

                              Avoid deeply nested control flow statements.
                              Open

                                                if thisfield.match(/^name=/)
                                                  fieldname = get_field_val(thisfield)
                                                end
                              Severity: Major
                              Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

                                Avoid deeply nested control flow statements.
                                Open

                                                if fieldid != ""
                                                  formfields << {
                                                    :id => fieldid,
                                                    :name => fieldname,
                                                    :type => fieldtype,
                                Severity: Major
                                Found in modules/auxiliary/fuzzers/http/http_form_field.rb - About 45 mins to fix

                                  Avoid deeply nested control flow statements.
                                  Open

                                            if @lastdata
                                              print_error("#{msg} DNS is DOWN since the request:")
                                              print_error(lastdata.unpack('H*'))
                                            else
                                              print_error("#{msg} DNS is DOWN")
                                  Severity: Major
                                  Found in modules/auxiliary/fuzzers/dns/dns_fuzzer.rb - About 45 mins to fix

                                    Avoid deeply nested control flow statements.
                                    Open

                                                      if !dns_send(pkt,@underlayerProtocol) then return end
                                    Severity: Major
                                    Found in modules/auxiliary/fuzzers/dns/dns_fuzzer.rb - About 45 mins to fix

                                      Avoid deeply nested control flow statements.
                                      Open

                                              if res.body.to_s =~ /'\/style\/style\.css', '([0-9]+)'\);<\/script>/
                                                # ... but get the build number if we can find it
                                                version[2] = $1.to_i
                                              end
                                      Severity: Major
                                      Found in modules/exploits/multi/http/manageengine_auth_upload.rb - About 45 mins to fix

                                        Avoid deeply nested control flow statements.
                                        Open

                                              elsif res.body.to_s =~ /\/console\/ConsoleMain\.cc/
                                                # IT360 newer versions
                                                version[3] = 'it'
                                        Severity: Major
                                        Found in modules/exploits/multi/http/manageengine_auth_upload.rb - About 45 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language