Update modules/exploits/multi/misc/consul_service_exec.rb

Co-Authored-By: QKaiser <QKaiser@users.noreply.github.com>
This commit is contained in:
Brendan Coles 2018-12-18 19:27:08 +01:00 committed by GitHub
parent 6ad40deac3
commit 5192c081ee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -114,7 +114,7 @@ class MetasploitModule < Msf::Exploit::Remote
'X-Consul-Token' => datastore['ACL_TOKEN'] 'X-Consul-Token' => datastore['ACL_TOKEN']
} }
}) })
if res and not res.code == 200 if res && res.code != 200
fail_with(Failure::Unknown, fail_with(Failure::Unknown,
'An error occured when contacting the Consul API.' 'An error occured when contacting the Consul API.'
) )