Skip to content

Commit

Permalink
datastore opts cleanup
Browse files Browse the repository at this point in the history
cleanuo digestauth datastore options in modules
  • Loading branch information
David Maloney authored and David Maloney committed Feb 4, 2013
1 parent 8d817dc commit 2c3de43
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 10 deletions.
4 changes: 2 additions & 2 deletions modules/auxiliary/gather/shodan_search.rb
Expand Up @@ -38,10 +38,10 @@ def initialize(info = {})
))

# disabling all the unnecessary options that someone might set to break our query
deregister_options('RPORT','RHOST', 'BasicAuthPass', 'BasicAuthUser', 'DOMAIN',
deregister_options('RPORT','RHOST', 'DOMAIN',
'DigestAuthIIS', 'SSLVersion', 'NTLM::SendLM', 'NTLM::SendNTLM',
'NTLM::SendSPN', 'NTLM::UseLMKey', 'NTLM::UseNTLM2_session',
'NTLM::UseNTLMv2', 'DigestAuthPassword', 'DigestAuthUser', 'SSL')
'NTLM::UseNTLMv2', 'SSL')

register_options(
[
Expand Down
3 changes: 1 addition & 2 deletions modules/auxiliary/server/http_ntlmrelay.rb
Expand Up @@ -84,8 +84,7 @@ def initialize(info = {})
'IPC$,ADMIN$,C$,D$,CCMLOGS$,ccmsetup$,share,netlogon,sysvol'])
], self.class)

deregister_options('BasicAuthPass', 'BasicAuthUser', 'DOMAIN', 'DigestAuthPassword',
'DigestAuthUser', 'NTLM::SendLM', 'NTLM::SendSPN', 'NTLM::SendNTLM', 'NTLM::UseLMKey',
deregister_options('DOMAIN', 'NTLM::SendLM', 'NTLM::SendSPN', 'NTLM::SendNTLM', 'NTLM::UseLMKey',
'NTLM::UseNTLM2_session', 'NTLM::UseNTLMv2')
end

Expand Down
10 changes: 4 additions & 6 deletions modules/exploits/windows/http/xampp_webdav_upload_php.rb
Expand Up @@ -36,8 +36,8 @@ def initialize
[
OptString.new('PATH', [ true, "The path to attempt to upload", '/webdav/']),
OptString.new('FILENAME', [ false , "The filename to give the payload. (Leave Blank for Random)"]),
OptString.new('RUSER', [ true, "The Username to use for Authentication", 'wampp']),
OptString.new('RPASS', [ true, "The Password to use for Authentication", 'xampp'])
OptString.new('USERNAME', [false, 'The HTTP username to specify for authentication', 'wampp']),
OptString.new('PASSWORD', [false, 'The HTTP password to specify for authentication', 'xampp'])
], self.class)
end

Expand All @@ -46,12 +46,10 @@ def initialize
def exploit
uri = build_path
print_status "Uploading Payload to #{uri}"
res,c = send_digest_request_cgi({
res = send_request_cgi({
'uri' => uri,
'method' => 'PUT',
'data' => payload.raw,
'DigestAuthUser' => datastore['RUSER'],
'DigestAuthPassword' => datastore['RPASS']
'data' => payload.raw
}, 25)
unless (res and res.code == 201)
print_error "Failed to upload file!"
Expand Down

0 comments on commit 2c3de43

Please sign in to comment.