File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
modules/auxiliary/server/relay Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -66,10 +66,20 @@ def check_host(target_ip)
66
66
disconnect
67
67
68
68
return Exploit ::CheckCode ::Unknown if res . nil?
69
- return Exploit ::CheckCode ::Safe unless res . code == 401
70
- return Exploit ::CheckCode ::Safe unless res . headers [ 'WWW-Authenticate' ] . include? ( 'NTLM' ) && res . body . present?
69
+ unless res . code == 401
70
+ return Exploit ::CheckCode ::Safe ( 'The target does not require authentication.' )
71
+ end
72
+
73
+ unless res . headers [ 'WWW-Authenticate' ] . include? ( 'NTLM' ) && res . body . present?
74
+ return Exploit ::CheckCode ::Safe ( 'The target does not support NTLM.' )
75
+ end
71
76
72
- Exploit ::CheckCode ::Detected ( 'Server replied that authentication is required and NTLM is supported.' )
77
+ if datastore [ 'SSL' ]
78
+ # if the target is over SSL, downgrade to "Detected" because Extended Protection for Authentication may or may not be enabled
79
+ Exploit ::CheckCode ::Detected ( 'Server replied that authentication is required and NTLM is supported.' )
80
+ else
81
+ Exploit ::CheckCode ::Appears ( 'Server replied that authentication is required and NTLM is supported.' )
82
+ end
73
83
end
74
84
75
85
def validate
You can’t perform that action at this time.
0 commit comments