Skip to content

Commit 61f9cc3

Browse files
committed
Correct casing - should be HttpUsername and HttpPassword
1 parent 7f643a7 commit 61f9cc3

File tree

81 files changed

+168
-168
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+168
-168
lines changed

lib/msf/core/exploit/http/client.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ def initialize(info = {})
4848
OptString.new('UserAgent', [false, 'The User-Agent header to use for all requests',
4949
Rex::Proto::Http::Client::DefaultUserAgent
5050
]),
51-
OptString.new('HTTPUSERNAME', [false, 'The HTTP username to specify for authentication', '']),
52-
OptString.new('HTTPPASSWORD', [false, 'The HTTP password to specify for authentication', '']),
51+
OptString.new('HttpUsername', [false, 'The HTTP username to specify for authentication', '']),
52+
OptString.new('HttpPassword', [false, 'The HTTP password to specify for authentication', '']),
5353
OptBool.new('DigestAuthIIS', [false, 'Conform to IIS, should work for most servers. Only set to false for non-IIS servers', true]),
5454
Opt::SSLVersion,
5555
OptBool.new('FingerprintCheck', [ false, 'Conduct a pre-exploit fingerprint verification', true]),
@@ -149,8 +149,8 @@ def connect(opts={})
149149
dossl = ssl
150150
end
151151

152-
client_username = opts['username'] || datastore['HTTPUSERNAME'] || ''
153-
client_password = opts['password'] || datastore['HTTPPASSWORD'] || ''
152+
client_username = opts['username'] || datastore['HttpUsername'] || ''
153+
client_password = opts['password'] || datastore['HttpPassword'] || ''
154154

155155
nclient = Rex::Proto::Http::Client.new(
156156
opts['rhost'] || rhost,

modules/auxiliary/admin/appletv/appletv_display_image.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ def initialize(info = {})
3636
Opt::RPORT(7000),
3737
OptInt.new('TIME', [true, 'Time in seconds to show the image', 10]),
3838
OptPath.new('FILE', [true, 'Image to upload and show']),
39-
OptString.new('HTTPPASSWORD', [false, 'The password for AppleTV AirPlay'])
39+
OptString.new('HttpPassword', [false, 'The password for AppleTV AirPlay'])
4040
], self.class)
4141

4242
# We're not actually using any of these against AppleTV in our Rex HTTP client init,
@@ -72,8 +72,8 @@ def send_image_request(opts)
7272
ssl,
7373
ssl_version,
7474
proxies,
75-
datastore['HTTPUSERNAME'],
76-
datastore['HTTPPASSWORD']
75+
datastore['HttpUsername'],
76+
datastore['HttpPassword']
7777
)
7878
add_socket(http)
7979

modules/auxiliary/admin/appletv/appletv_display_video.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,15 @@ def initialize(info = {})
3333
[
3434
['URL', 'http://nto.github.io/AirPlay.html']
3535
],
36-
'DefaultOptions' => { 'HTTPUSERNAME' => 'AirPlay' },
36+
'DefaultOptions' => { 'HttpUsername' => 'AirPlay' },
3737
'License' => MSF_LICENSE
3838
))
3939

4040
register_options([
4141
Opt::RPORT(7000),
4242
OptInt.new('TIME', [true, 'Time in seconds to show the video', 60]),
4343
OptString.new('URL', [true, 'URL of video to show. Must use an IP address']),
44-
OptString.new('HTTPPASSWORD', [false, 'The password for AppleTV AirPlay'])
44+
OptString.new('HttpPassword', [false, 'The password for AppleTV AirPlay'])
4545
], self.class)
4646

4747
# We're not actually using any of these against AppleTV in our Rex HTTP client init,
@@ -77,8 +77,8 @@ def send_video_request(opts)
7777
ssl,
7878
ssl_version,
7979
proxies,
80-
datastore['HTTPUSERNAME'],
81-
datastore['HTTPPASSWORD']
80+
datastore['HttpUsername'],
81+
datastore['HttpPassword']
8282
)
8383
add_socket(http)
8484

modules/auxiliary/admin/http/linksys_e1500_e2500_exec.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,16 +32,16 @@ def initialize(info = {})
3232

3333
register_options(
3434
[
35-
OptString.new('HTTPUSERNAME',[ true, 'User to login with', 'admin']),
36-
OptString.new('HTTPPASSWORD',[ true, 'Password to login with', 'password']),
35+
OptString.new('HttpUsername',[ true, 'User to login with', 'admin']),
36+
OptString.new('HttpPassword',[ true, 'Password to login with', 'password']),
3737
OptString.new('CMD', [ true, 'The command to execute', 'telnetd -p 1337'])
3838
], self.class)
3939
end
4040

4141
def run
4242
uri = '/apply.cgi'
43-
user = datastore['HTTPUSERNAME']
44-
pass = datastore['HTTPPASSWORD']
43+
user = datastore['HttpUsername']
44+
pass = datastore['HttpPassword']
4545

4646
print_status("#{rhost}:#{rport} - Trying to login with #{user} / #{pass}")
4747

modules/auxiliary/admin/http/linksys_wrt54gl_exec.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ def initialize(info = {})
4242
[
4343
Opt::RPORT(80),
4444
OptString.new('TARGETURI',[ true, 'PATH to OS Command Injection', '/apply.cgi']),
45-
OptString.new('HTTPUSERNAME',[ true, 'User to login with', 'admin']),
46-
OptString.new('HTTPPASSWORD',[ false, 'Password to login with', 'password']),
45+
OptString.new('HttpUsername',[ true, 'User to login with', 'admin']),
46+
OptString.new('HttpPassword',[ false, 'Password to login with', 'password']),
4747
OptString.new('CMD', [ true, 'The command to execute', 'ping 127.0.0.1']),
4848
OptString.new('NETMASK', [ false, 'LAN Netmask of the router', '255.255.255.0']),
4949
OptAddress.new('LANIP', [ false, 'LAN IP address of the router (default is RHOST)']),
@@ -66,7 +66,7 @@ def lan_ip
6666
def run
6767
#setting up some basic variables
6868
uri = datastore['TARGETURI']
69-
user = datastore['HTTPUSERNAME']
69+
user = datastore['HttpUsername']
7070
rhost = datastore['RHOST']
7171
netmask = datastore['NETMASK']
7272
routername = datastore['ROUTER_NAME']
@@ -75,10 +75,10 @@ def run
7575

7676
ip = lan_ip.split('.')
7777

78-
if datastore['HTTPPASSWORD'].nil?
78+
if datastore['HttpPassword'].nil?
7979
pass = ""
8080
else
81-
pass = datastore['HTTPPASSWORD']
81+
pass = datastore['HttpPassword']
8282
end
8383

8484
print_status("Trying to login with #{user} / #{pass}")

modules/auxiliary/admin/http/openbravo_xxe.rb

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ def initialize(info = {})
4141
register_options(
4242
[
4343
OptString.new('TARGETURI', [ true, "Base Openbravo directory path", '/openbravo/']),
44-
OptString.new('HTTPUSERNAME', [true, "The Openbravo user", "Openbravo"]),
45-
OptString.new('HTTPPASSWORD', [true, "The Openbravo password", "openbravo"]),
44+
OptString.new('HttpUsername', [true, "The Openbravo user", "Openbravo"]),
45+
OptString.new('HttpPassword', [true, "The Openbravo password", "openbravo"]),
4646
OptString.new('FILEPATH', [true, "The filepath to read on the server", "/etc/passwd"]),
4747
OptString.new('ENDPOINT', [true, "The XML API REST endpoint to use", "ADUser"])
4848
], self.class)
@@ -53,7 +53,7 @@ def run
5353
users = send_request_raw({
5454
'method' => 'GET',
5555
'uri' => normalize_uri(datastore['TARGETURI'], "/ws/dal/#{datastore["ENDPOINT"]}"),
56-
'authorization' => basic_auth(datastore['HTTPUSERNAME'], datastore['HTTPPASSWORD'])
56+
'authorization' => basic_auth(datastore['HTTPUSERNAME'], datastore['HttpPassword'])
5757
}, 60)
5858

5959
if !users or users.code != 200
@@ -86,20 +86,20 @@ def run
8686
'method' => 'PUT',
8787
'uri' => normalize_uri(target_uri.path, "/ws/dal/#{datastore["ENDPOINT"]}/#{id}"),
8888
'data' => xml,
89-
'authorization' => basic_auth(datastore['HTTPUSERNAME'], datastore['HTTPPASSWORD'])
89+
'authorization' => basic_auth(datastore['HttpUsername'], datastore['HttpPassword'])
9090
})
9191

9292
if !resp or resp.code != 200 or resp.body =~ /Not updating entity/
9393
print_error("Problem updating #{datastore["ENDPOINT"]} #{other_id} with ID: #{id}")
9494
next
9595
end
9696

97-
print_status("Found writeable #{datastore["ENDPOINT"]}: #{other_id}")
97+
print_status("Found writable #{datastore["ENDPOINT"]}: #{other_id}")
9898

9999
u = send_request_raw({
100100
'method' => 'GET',
101101
'uri' => normalize_uri(datastore['TARGETURI'], "/ws/dal/#{datastore["ENDPOINT"]}/#{id}"),
102-
'authorization' => basic_auth(datastore['HTTPUSERNAME'], datastore['HTTPPASSWORD'])
102+
'authorization' => basic_auth(datastore['HttpUsername'], datastore['HttpPassword'])
103103
})
104104

105105
u = REXML::Document.new u.body
@@ -116,7 +116,7 @@ def run
116116
'method' => 'PUT',
117117
'uri' => normalize_uri(target_uri.path, "/ws/dal/#{datastore["ENDPOINT"]}/#{id}"),
118118
'data' => xml,
119-
'authorization' => basic_auth(datastore['HTTPUSERNAME'], datastore['HTTPPASSWORD'])
119+
'authorization' => basic_auth(datastore['HttpUsername'], datastore['HttpPassword'])
120120
})
121121

122122
print_good("File saved to: #{path}")

modules/auxiliary/admin/sap/sap_mgmt_con_osexec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ def initialize
3232
[
3333
Opt::RPORT(50013),
3434
OptString.new('URI', [false, 'Path to the SAP Management Console ', '/']),
35-
OptString.new('HTTPUSERNAME', [true, 'Username to use', '']),
36-
OptString.new('HTTPPASSWORD', [true, 'Password to use', '']),
35+
OptString.new('HttpUsername', [true, 'Username to use', '']),
36+
OptString.new('HttpPassword', [true, 'Password to use', '']),
3737
OptString.new('CMD', [true, 'Command to run', 'set']),
3838
], self.class)
3939
register_autofilter_ports([ 50013 ])
@@ -126,7 +126,7 @@ def osexecute(rhost, cmd_to_run)
126126
data << '</SOAP-ENV:Body>' + "\r\n"
127127
data << '</SOAP-ENV:Envelope>' + "\r\n\r\n"
128128

129-
user_pass = Rex::Text.encode_base64(datastore['HTTPUSERNAME'] + ":" + datastore['HTTPPASSWORD'])
129+
user_pass = Rex::Text.encode_base64(datastore['HttpUsername'] + ":" + datastore['HttpPassword'])
130130

131131
begin
132132
res = send_request_raw({

modules/auxiliary/dos/sap/sap_soap_rfc_eps_delete_file.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ def initialize
5151
register_options([
5252
Opt::RPORT(8000),
5353
OptString.new('CLIENT', [true, 'SAP Client', '001']),
54-
OptString.new('HTTPUSERNAME', [true, 'Username', 'SAP*']),
55-
OptString.new('HTTPPASSWORD', [true, 'Password', '06071992']),
54+
OptString.new('HttpUsername', [true, 'Username', 'SAP*']),
55+
OptString.new('HttpPassword', [true, 'Password', '06071992']),
5656
OptString.new('DIRNAME', [true, 'Directory Path which contains the file to delete', '/tmp']),
5757
OptString.new('FILENAME', [true, 'Filename to delete', 'msf.txt'])
5858
], self.class)
@@ -80,7 +80,7 @@ def run_host(ip)
8080
'uri' => '/sap/bc/soap/rfc',
8181
'method' => 'POST',
8282
'data' => data,
83-
'authorization' => basic_auth(datastore['HTTPUSERNAME'], datastore['HTTPPASSWORD']),
83+
'authorization' => basic_auth(datastore['HttpUsername'], datastore['HttpPassword']),
8484
'cookie' => 'sap-usercontext=sap-language=EN&sap-client=' + datastore['CLIENT'],
8585
'ctype' => 'text/xml; charset=UTF-8',
8686
'headers' => {

modules/auxiliary/gather/snare_registry.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ def initialize(info = {})
3535
register_options(
3636
[
3737
Opt::RPORT(6161),
38-
OptString.new('HTTPUSERNAME', [ false, 'The username for Snare remote access', 'snare' ]),
39-
OptString.new('HTTPPASSWORD', [ false, 'The password for Snare remote access', '' ]),
38+
OptString.new('HttpUsername', [ false, 'The username for Snare remote access', 'snare' ]),
39+
OptString.new('HttpPassword', [ false, 'The password for Snare remote access', '' ]),
4040
OptString.new('REG_DUMP_KEY', [ false, 'Retrieve this registry key and all sub-keys', 'HKLM\\HARDWARE\\DESCRIPTION\\System' ]),
4141
OptBool.new('REG_DUMP_ALL', [false, 'Retrieve the entire Windows registry', false]),
4242
OptInt.new('TIMEOUT', [true, 'Timeout in seconds for downloading each registry key/hive', 300])
@@ -68,7 +68,7 @@ def dump_key(reg_key)
6868
end
6969
res = send_request_cgi({
7070
'uri' => normalize_uri('RegDump'),
71-
'authorization' => basic_auth(datastore['HTTPUSERNAME'], datastore['HTTPPASSWORD']),
71+
'authorization' => basic_auth(datastore['HttpUsername'], datastore['HttpPassword']),
7272
'vars_get' => vars_get
7373
}, datastore['TIMEOUT'])
7474
if !res
@@ -102,7 +102,7 @@ def retrieve_hive_list
102102
print_status("#{peer} - Retrieving list of registry hives ...")
103103
res = send_request_cgi(
104104
'uri' => normalize_uri('RegDump'),
105-
'authorization' => basic_auth(datastore['HTTPUSERNAME'], datastore['HTTPPASSWORD'])
105+
'authorization' => basic_auth(datastore['HttpUsername'], datastore['HttpPassword'])
106106
)
107107
if !res
108108
fail_with(Failure::Unreachable, "#{peer} - Connection failed")

modules/auxiliary/gather/xbmc_traversal.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ def initialize(info={})
3838
Opt::RPORT(8080),
3939
OptString.new('FILEPATH', [false, 'The name of the file to download', '/private/var/mobile/Library/Preferences/XBMC/userdata/passwords.xml']),
4040
OptInt.new('DEPTH', [true, 'The max traversal depth', 9]),
41-
OptString.new('HTTPUSERNAME', [true, 'The username to use for the HTTP server', 'xbmc']),
42-
OptString.new('HTTPPASSWORD', [false, 'The password to use for the HTTP server', 'xbmc']),
41+
OptString.new('HttpUsername', [true, 'The username to use for the HTTP server', 'xbmc']),
42+
OptString.new('HttpPassword', [false, 'The password to use for the HTTP server', 'xbmc']),
4343
], self.class)
4444
end
4545

@@ -56,7 +56,7 @@ def run
5656
res = send_request_raw({
5757
'method' => 'GET',
5858
'uri' => "/#{traversal}/#{datastore['FILEPATH']}",
59-
'authorization' => basic_auth(datastore['HTTPUSERNAME'],datastore['HTTPPASSWORD'])
59+
'authorization' => basic_auth(datastore['HttpUsername'],datastore['HttpPassword'])
6060
}, 25)
6161
rescue Rex::ConnectionRefused
6262
print_error("#{rhost}:#{rport} Could not connect.")

0 commit comments

Comments
 (0)