File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
modules/auxiliary/scanner/oracle Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -42,8 +42,19 @@ def run_host(ip)
42
42
send_packet = tns_packet ( "(CONNECT_DATA=(COMMAND=service_register_NSGR))" )
43
43
sock . put ( send_packet )
44
44
packet = sock . read ( 100 )
45
+ hex_packet = Rex ::Text . to_hex ( packet , prefix = ':' )
46
+ split_hex = hex_packet . split ( ":" )
45
47
find_packet = /\( ERROR_STACK=\( ERROR=/ === packet
46
- find_packet == true ? print_error ( "#{ ip } :#{ rport } is not vulnerable " ) : print_good ( "#{ ip } :#{ rport } is vulnerable" )
48
+ #find_packet == true ? print_error("#{ip}:#{rport} is not vulnerable ") : print_good("#{ip}:#{rport} is vulnerable")
49
+ if find_packet == true
50
+ print_error ( "#{ ip } :#{ rport } is not vulnerable" )
51
+ elsif split_hex [ 5 ] == "02"
52
+ print_good ( "#{ ip } :#{ rport } is vulnerable" )
53
+ elsif split_hex [ 5 ] == "04"
54
+ print_error ( "#{ ip } :#{ rport } is not vulnerable" )
55
+ else
56
+ print_error ( "#{ ip } :#{ rport } might not be vulnerable" )
57
+ end
47
58
# TODO: Module should report_vuln if this finding is solid.
48
59
rescue ::Rex ::ConnectionError , ::Errno ::EPIPE
49
60
print_error ( "#{ ip } :#{ rport } unable to connect to the server" )
You can’t perform that action at this time.
0 commit comments