modules/exploits/unix/http/schneider_electric_net55xx_encoder.rb
Method initialize
has 45 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def initialize(info = {})
super(
update_info(
info,
'Name' => 'Schneider Electric Pelco Endura NET55XX Encoder',
Method do_login
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def do_login
change_password
print_status("#{rhost}:22 - Attempt to start a SSH connection...")
opts = ssh_client_defaults.merge({
auth_methods: ['password', 'keyboard-interactive'],
Method check
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def check
xmlPayload = '<?xml version="1.0" encoding="UTF-8"?>'\
'<Envelope xmlns="http://www.w3.org/2003/05/soap-envelope">'\
'<Header xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">'\
'<a:Action mustUnderstand="1">http://schemas.xmlsoap.org/ws/2005/04/discovery/Probe</a:Action>'\
Consider simplifying this complex logical expression. Open
Open
if xmlResponse.include?('NET5501') || xmlResponse.include?('NET5501-I') || xmlResponse.include?('NET5501-XT') || xmlResponse.include?('NET5504') || xmlResponse.include?('NET5500') || xmlResponse.include?('NET5516') || xmlResponse.include?('NET5508')
return Exploit::CheckCode::Appears
end