Reduce code complexity easily

bug/bundler_fix
jvazquez-r7 2013-11-18 13:25:45 -06:00
parent f61c1548ee
commit ae440130f5
1 changed files with 42 additions and 41 deletions

View File

@ -12,7 +12,12 @@ module Msf::HTTP::Typo3::Login
'method' => 'GET',
'uri' => typo3_url_login
})
if res_main and res_main.code == 200
unless res_main and res_main.code == 200
vprint_error('Can not reach login page')
return nil
end
e = res_main.body.match(/<input type="hidden" id="rsa_e" name="e" value="(\d+)" \/>/)[1]
n = res_main.body.match(/<input type="hidden" id="rsa_n" name="n" value="(\w+)" \/>/)[1]
vprint_status("e: #{e}")
@ -52,10 +57,6 @@ module Msf::HTTP::Typo3::Login
return nil
end
end
else
vprint_error('Can not reach login page')
return nil
end
return nil
end