We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a597de5 commit 9634248Copy full SHA for 9634248
lib/metasploit/framework/login_scanner/smb.rb
@@ -127,11 +127,13 @@ def attempt_login(credential)
127
else
128
status = Metasploit::Model::Login::Status::INCORRECT
129
end
130
- rescue ::Rex::ConnectionError => e
+ rescue ::Rex::ConnectionError, Errno::EINVAL => e
131
status = Metasploit::Model::Login::Status::UNABLE_TO_CONNECT
132
proof = e
133
rescue RubySMB::Error::UnexpectedStatusCode => e
134
135
+ ensure
136
+ client.disconnect!
137
138
139
if status == Metasploit::Model::Login::Status::SUCCESSFUL && credential.public.empty?
0 commit comments