rapid7/metasploit-framework

View on GitHub

Showing 21,886 of 21,886 total issues

Similar blocks of code found in 10 locations. Consider refactoring.
Open

  def initialize(info = {})
    super(merge_info(info,
      'Name'          => 'Command Shell, Reverse TCP (via python)',
      'Description'   => 'Creates an interactive shell via Python, encodes with base64 by design. Compatible with Python 2.4-2.7 and 3.4+.',
      'Author'        => 'Ben Campbell', # Based on RageLtMan's reverse_ssl
Severity: Major
Found in modules/payloads/singles/python/shell_reverse_tcp.rb and 9 other locations - About 35 mins to fix
modules/payloads/singles/cmd/unix/reverse_stub.rb on lines 14..30
modules/payloads/singles/generic/ssh/interact.rb on lines 12..30
modules/payloads/singles/php/reverse_perl.rb on lines 15..31
modules/payloads/singles/php/reverse_php.rb on lines 15..31
modules/payloads/singles/python/shell_bind_tcp.rb on lines 10..26
modules/payloads/singles/python/shell_reverse_sctp.rb on lines 13..31
modules/payloads/singles/python/shell_reverse_tcp_ssl.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_udp.rb on lines 15..31
modules/payloads/singles/ruby/shell_reverse_tcp_ssl.rb on lines 15..27

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 10 locations. Consider refactoring.
Open

  def initialize(info = {})
    super(merge_info(info,
      'Name'          => 'PHP Command Shell, Reverse TCP (via PHP)',
      'Description'   => 'Reverse PHP connect back shell with checks for disabled functions',
      'Author'        => 'egypt',
Severity: Major
Found in modules/payloads/singles/php/reverse_php.rb and 9 other locations - About 35 mins to fix
modules/payloads/singles/cmd/unix/reverse_stub.rb on lines 14..30
modules/payloads/singles/generic/ssh/interact.rb on lines 12..30
modules/payloads/singles/php/reverse_perl.rb on lines 15..31
modules/payloads/singles/python/shell_bind_tcp.rb on lines 10..26
modules/payloads/singles/python/shell_reverse_sctp.rb on lines 13..31
modules/payloads/singles/python/shell_reverse_tcp.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_tcp_ssl.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_udp.rb on lines 15..31
modules/payloads/singles/ruby/shell_reverse_tcp_ssl.rb on lines 15..27

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 10 locations. Consider refactoring.
Open

  def initialize(info = {})
    super(merge_info(info,
      'Name'          => 'PHP Command, Double Reverse TCP Connection (via Perl)',
      'Description'   => 'Creates an interactive shell via perl',
      'Author'        => 'cazz',
Severity: Major
Found in modules/payloads/singles/php/reverse_perl.rb and 9 other locations - About 35 mins to fix
modules/payloads/singles/cmd/unix/reverse_stub.rb on lines 14..30
modules/payloads/singles/generic/ssh/interact.rb on lines 12..30
modules/payloads/singles/php/reverse_php.rb on lines 15..31
modules/payloads/singles/python/shell_bind_tcp.rb on lines 10..26
modules/payloads/singles/python/shell_reverse_sctp.rb on lines 13..31
modules/payloads/singles/python/shell_reverse_tcp.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_tcp_ssl.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_udp.rb on lines 15..31
modules/payloads/singles/ruby/shell_reverse_tcp_ssl.rb on lines 15..27

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 10 locations. Consider refactoring.
Open

  def initialize(info = {})
    super(merge_info(info,
      'Name'          => 'Command Shell, Reverse UDP (via python)',
      'Description'   => 'Creates an interactive shell via Python, encodes with base64 by design. Compatible with Python 2.6-2.7 and 3.4+.',
      'Author'        => 'RageLtMan <rageltman[at]sempervictus>',
Severity: Major
Found in modules/payloads/singles/python/shell_reverse_udp.rb and 9 other locations - About 35 mins to fix
modules/payloads/singles/cmd/unix/reverse_stub.rb on lines 14..30
modules/payloads/singles/generic/ssh/interact.rb on lines 12..30
modules/payloads/singles/php/reverse_perl.rb on lines 15..31
modules/payloads/singles/php/reverse_php.rb on lines 15..31
modules/payloads/singles/python/shell_bind_tcp.rb on lines 10..26
modules/payloads/singles/python/shell_reverse_sctp.rb on lines 13..31
modules/payloads/singles/python/shell_reverse_tcp.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_tcp_ssl.rb on lines 15..31
modules/payloads/singles/ruby/shell_reverse_tcp_ssl.rb on lines 15..27

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 10 locations. Consider refactoring.
Open

  def initialize(info = {})
    super(merge_info(info,
      'Name' => 'Command Shell, Bind TCP (via python)',
      'Description' => 'Creates an interactive shell via Python, encodes with base64 by design. Compatible with Python 2.4-2.7 and 3.4+.',
      'Author' => 'mumbai',
Severity: Major
Found in modules/payloads/singles/python/shell_bind_tcp.rb and 9 other locations - About 35 mins to fix
modules/payloads/singles/cmd/unix/reverse_stub.rb on lines 14..30
modules/payloads/singles/generic/ssh/interact.rb on lines 12..30
modules/payloads/singles/php/reverse_perl.rb on lines 15..31
modules/payloads/singles/php/reverse_php.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_sctp.rb on lines 13..31
modules/payloads/singles/python/shell_reverse_tcp.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_tcp_ssl.rb on lines 15..31
modules/payloads/singles/python/shell_reverse_udp.rb on lines 15..31
modules/payloads/singles/ruby/shell_reverse_tcp_ssl.rb on lines 15..27

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

        unless user =~ /@\w+\.\w+/
          report_cred(
            ip: res.peerinfo['addr'],
            port: datastore['RPORT'],
            service_name: 'owa',
Severity: Minor
Found in modules/auxiliary/scanner/http/owa_login.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/http/owa_login.rb on lines 258..267
modules/auxiliary/scanner/http/owa_login.rb on lines 334..343

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

        unless user =~ /@\w+\.\w+/
          report_cred(
            ip: res.peerinfo['addr'],
            port: datastore['RPORT'],
            service_name: 'owa',
Severity: Minor
Found in modules/auxiliary/scanner/http/owa_login.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/http/owa_login.rb on lines 258..267
modules/auxiliary/scanner/http/owa_login.rb on lines 306..315

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

  def run_host(ip)
    begin
      print_status("#{msg} Connecting and checking username and passwords")
      each_user_pass do |user, pass|
        do_login(user, pass)
Severity: Minor
Found in modules/auxiliary/scanner/openvas/openvas_otp_login.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/nessus/nessus_ntp_login.rb on lines 30..40
modules/auxiliary/scanner/openvas/openvas_omp_login.rb on lines 27..36

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

    if (datastore['USERNAME'] and
      not datastore['USERNAME'].empty? and
      datastore['PASSWORD'] and
      not datastore['PASSWORD'].empty?)
      print_status("Trying login to get session ID...")
Severity: Minor
Found in modules/exploits/unix/webapp/twiki_maketext.rb and 2 other locations - About 35 mins to fix
modules/exploits/unix/webapp/foswiki_maketext.rb on lines 193..202
modules/exploits/unix/webapp/moinmoin_twikidraw.rb on lines 232..241

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

          unless user =~ /@\w+\.\w+/
            report_cred(
              ip: res.peerinfo['addr'],
              port: datastore['RPORT'],
              service_name: 'owa',
Severity: Minor
Found in modules/auxiliary/scanner/http/owa_login.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/http/owa_login.rb on lines 306..315
modules/auxiliary/scanner/http/owa_login.rb on lines 334..343

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

    if session
      print_status("Using existing session #{session.sid}")
      client = session.client
      self.simple = ::Rex::Proto::SMB::SimpleClient.new(client.dispatcher.tcp_socket, client: client)
      ports = [simple.port]
Severity: Minor
Found in modules/auxiliary/scanner/smb/smb_enumusers_domain.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/smb/pipe_dcerpc_auditor.rb on lines 258..263
modules/auxiliary/scanner/smb/smb_lookupsid.rb on lines 150..155

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

    if (datastore['USERNAME'] and
      not datastore['USERNAME'].empty? and
      datastore['PASSWORD'] and
      not datastore['PASSWORD'].empty?)
      print_status("Trying login to get session ID...")
Severity: Minor
Found in modules/exploits/unix/webapp/foswiki_maketext.rb and 2 other locations - About 35 mins to fix
modules/exploits/unix/webapp/moinmoin_twikidraw.rb on lines 232..241
modules/exploits/unix/webapp/twiki_maketext.rb on lines 186..195

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

    if (datastore['USERNAME'] and
      not datastore['USERNAME'].empty? and
      datastore['PASSWORD'] and
      not datastore['PASSWORD'].empty?)
      print_status("Trying login to get session ID...")
Severity: Minor
Found in modules/exploits/unix/webapp/moinmoin_twikidraw.rb and 2 other locations - About 35 mins to fix
modules/exploits/unix/webapp/foswiki_maketext.rb on lines 193..202
modules/exploits/unix/webapp/twiki_maketext.rb on lines 186..195

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

  def run_host(ip)
    begin
      print_status("#{msg} Connecting and checking username and passwords")
      each_user_pass do |user, pass|
        do_login(user, pass)
Severity: Minor
Found in modules/auxiliary/scanner/openvas/openvas_omp_login.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/nessus/nessus_ntp_login.rb on lines 30..40
modules/auxiliary/scanner/openvas/openvas_otp_login.rb on lines 27..36

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

    if session
      print_status("Using existing session #{session.sid}")
      client = session.client
      self.simple = ::Rex::Proto::SMB::SimpleClient.new(client.dispatcher.tcp_socket, client: client)
      ports = [simple.port]
Severity: Minor
Found in modules/auxiliary/scanner/smb/smb_lookupsid.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/smb/pipe_dcerpc_auditor.rb on lines 258..263
modules/auxiliary/scanner/smb/smb_enumusers_domain.rb on lines 129..134

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

  def run_host(ip)
    begin
      print_status("#{msg} Connecting and checking username and passwords")
      each_user_pass do |user, pass|
        do_login(user, pass)
Severity: Minor
Found in modules/auxiliary/scanner/nessus/nessus_ntp_login.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/openvas/openvas_omp_login.rb on lines 27..36
modules/auxiliary/scanner/openvas/openvas_otp_login.rb on lines 27..36

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 3 locations. Consider refactoring.
Open

    if session
      print_status("Using existing session #{session.sid}")
      client = session.client
      self.simple = ::Rex::Proto::SMB::SimpleClient.new(client.dispatcher.tcp_socket, client: client)
      ports = [simple.port]
Severity: Minor
Found in modules/auxiliary/scanner/smb/pipe_dcerpc_auditor.rb and 2 other locations - About 35 mins to fix
modules/auxiliary/scanner/smb/smb_enumusers_domain.rb on lines 129..134
modules/auxiliary/scanner/smb/smb_lookupsid.rb on lines 150..155

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

          [ 'VMware',   { 'Ret' => 0x000f142b } ],
          [ 'NetWare 6.5 SP2', { 'Ret' => 0xb2329b98 } ], # push esp - ret (libc.nlm)
          [ 'NetWare 6.5 SP3', { 'Ret' => 0xb234a268 } ], # push esp - ret (libc.nlm)
          [ 'NetWare 6.5 SP4', { 'Ret' => 0xbabc286c } ], # push esp - ret (libc.nlm)
          [ 'NetWare 6.5 SP5', { 'Ret' => 0xbabc9c3c } ], # push esp - ret (libc.nlm)
Severity: Major
Found in modules/exploits/netware/smb/lsass_cifs.rb and 4 other locations - About 35 mins to fix
modules/exploits/linux/http/linksys_apply_cgi.rb on lines 39..45
modules/exploits/netware/sunrpc/pkernel_callit.rb on lines 41..47
modules/exploits/windows/http/privatewire_gateway.rb on lines 39..45
modules/exploits/windows/misc/tiny_identd_overflow.rb on lines 43..49

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

          [ 'Generic', { 'Bufaddr' => 0x10002b50}],
          [ 'Version 1.42.2', { 'Bufaddr' => 0x100016a8 }],
          [ 'Version 2.02.6beta1', { 'Bufaddr' => 0x10001760 }],
          [ 'Version 2.02.7_ETSI', { 'Bufaddr' => 0x10001634 }],
          [ 'Version 3.03.6', { 'Bufaddr' => 0x10001830 }],
Severity: Major
Found in modules/exploits/linux/http/linksys_apply_cgi.rb and 4 other locations - About 35 mins to fix
modules/exploits/netware/smb/lsass_cifs.rb on lines 43..49
modules/exploits/netware/sunrpc/pkernel_callit.rb on lines 41..47
modules/exploits/windows/http/privatewire_gateway.rb on lines 39..45
modules/exploits/windows/misc/tiny_identd_overflow.rb on lines 43..49

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

          ['Windows 2000 English SP1',     { 'Ret' => 0x77e3cb4c }], # jmp esp user32.dll
          ['Windows 2000 English SP2',     { 'Ret' => 0x77e3af64 }], # jmp esp user32.dll
          ['Windows 2000 English SP3',     { 'Ret' => 0x77e388a7 }], # jmp esp user32.dll
          ['Windows 2000 English SP4',     { 'Ret' => 0x77e3c256 }], # jmp esp user32.dll
          ['Windows 2003 English SP0/SP1', { 'Ret' => 0x77d74c94 }], # jmp esp user32.dll
Severity: Major
Found in modules/exploits/windows/http/privatewire_gateway.rb and 4 other locations - About 35 mins to fix
modules/exploits/linux/http/linksys_apply_cgi.rb on lines 39..45
modules/exploits/netware/smb/lsass_cifs.rb on lines 43..49
modules/exploits/netware/sunrpc/pkernel_callit.rb on lines 41..47
modules/exploits/windows/misc/tiny_identd_overflow.rb on lines 43..49

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 36.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language