Exploit Development

Table of Contents

To Do

  • Sort tools better, like enviromental tools vs use-specific tools

  • Corelan, swift, primal Exploit Series

  • Add more sites to Acquiring Old/Vulnerable Software

  • More sites to structured learning

  • Add ARM stuff

  • Add more on Borrowed-Instruction-Set Computing

  • Why .shared sections are a security hole https://rastating.github.io/creating-a-custom-shellcode-encoder/ https://www.corelan.be/index.php/2019/04/23/windows-10-egghunter/ https://blog.flanker017.me/galaxy-leapfrogging-pwning-the-galaxy-s8/ https://blog.flanker017.me/galaxy-leapfrogging-pwning-the-galaxy-s8/


https://github.com/swisskyrepo/PayloadsAllTheThings https://github.com/Cn33liz/MS17-012 https://github.com/qazbnm456/awesome-cve-poc#cve-2018-5318 https://github.com/Cn33liz/Tater https://exploit.education/


https://m0chan.github.io/2019/08/21/Win32-Buffer-Overflow-SEH.html https://googleprojectzero.blogspot.com/2019/09/windows-exploitation-tricks-spoofing.html

* [High-Level Approaches for Finding Vulnerabilities - @Jackson_T](https://web.archive.org/web/20171119102445/https://jackson.thuraisamy.me/finding-vulnerabilities.html)
  • Bypassing Windows ASLR in Microsoft Office using ActiveX controls - Parvez

  • Exploiting the Linux kernel via packet sockets - Andrey Konovalov

    • https://github.com/xairy/kernel-exploits/tree/master/CVE-2017-7308 https://github.com/CENSUS/shadow https://heap-exploitation.dhavalkapil.com/attacks/house_of_spirit.html http://blog.sevagas.com/?Code-segment-encryption Solaris
    • https://techblog.mediaservice.net/2018/11/cve-2018-14665-exploit-local-privilege-escalation-on-solaris-11/
    • https://www.giac.org/paper/gcih/700/local-privilege-escalation-solaris-8-solaris-9-buffer-overflow-passwd1/105309
    • https://www.exploit-db.com/exploits/715
  • I Am Groot: Examining the Guardians of Windows 10 Security - Chuanda Ding(Defcon China 1)

    • Being one of the main targets of 3 Pwn2Own competitions, Microsoft Windows 10, along with Microsoft Edge, is proven more and more difficult to exploit. Now Windows 10 has been released for more than 2 years, Microsoft has been constantly updating the security mitigations integrated with the operating system. After 5 major releases, multiple levels of protections have been added to prevent a programming error from turning into a full system compromise. You may have heard many of them marketed as "Guards" under the Windows Defender brand. But how do they actually work? As Pwn2Own participants (and winners), we closely watched Windows 10 security evolve over the years. In this talk, you will get a behind-the-scene view of Windows 10 security mitigation implementations, how it helped make attackers' life harder, and how the attackers overcame it.

    • https://www.thezdi.com/blog/2019/3/13/cve-2019-0604-details-of-a-microsoft-sharepoint-rce-vulnerability

    • https://habr.com/ru/company/pt/blog/448378/

    • https://blog.ret2.io/2018/08/28/pwn2own-2018-sandbox-escape/

    • CVE-2017-11882

    • http://www.trapkit.de/books/bhd/en.html#code

iOS Exploitation - Title: 2PAC 2FURIOUS: Envisioning an iOS compromise in 2019 * https://googleprojectzero.blogspot.com/2019/04/splitting-atoms-in-xnu.html * https://www.qualcomm.com/media/documents/files/whitepaper-pointer-authentication-on-armv8-3.pdf

Android Chrome exploitation infiltrate * https://vimeo.com/270454588 https://osandamalith.com/2018/02/01/exploiting-format-strings-in-windows/ https://googleprojectzero.blogspot.com/2017/05/exploiting-linux-kernel-via-packet.html

  • Get Cozy with OpenBSM Auditing...the good, the bad, & the ugly - Patrick Wardle

  • Getting Cozy With OpenBSM Auditing On MacOS - Patrick Wardle

    • With the demise of dtrace on macOS, and Apple’s push to rid the kernel of 3rd-party kexts, another option is needed to perform effective auditing on macOS. Lucky for us, OpenBSM fits the bill. Though quite powerful, this auditing mechanism is rather poorly documented and suffered from a variety of kernel vulnerabilities. In this talk, we’ll begin with an introductory overview of OpenBSM’s goals, capabilities, and components before going ‘behind-the-scenes’ to take a closer look at it’s kernel-mode implementation. Armed with this understanding, we’ll then detail exactly how to build powerful user-mode macOS monitoring utilities such as file, process, and networking monitors based on the OpenBSM framework and APIs. Next we’ll don our hacker hats and discuss a handful of kernel bugs discovered during a previous audit of the audit subsystem (yes, quite meta): a subtle off-by-one read error, a blotched patch that turned the off-by-one into a kernel info leak, and finally an exploitable heap overflow. Though now patched, the discussion of these bugs provides an interesting ‘case-study’ of finding and exploiting several types of bugs that lurked within the macOS kernel for many years
  • Bypassing Windows ASLR by determining the library address using shared pages - stackoverflow


Prep for https://medium.com/@iphelix/exodus-vuln-dev-master-class-44741b1ebdd5 https://msrc-blog.microsoft.com/2009/02/02/preventing-the-exploitation-of-structured-exception-handler-seh-overwrites-with-sehop/ https://trailofbits.files.wordpress.com/2010/04/practical-rop.pdf https://www.csc2.ncsu.edu/faculty/xjiang4/pubs/ASIACCS11.pdf https://www.corelan.be/index.php/2013/07/02/root-cause-analysis-integer-overflows/ http://www.phreedom.org/research/heap-feng-shui/ http://illmatics.com/Understanding_the_LFH_Slides.pdf https://net-ninja.net/article/2012/Mar/1/heap-overflows-for-humans-104/

https://github.com/googleprojectzero/iOS-messaging-tools https://googleprojectzero.blogspot.com/2019/04/windows-exploitation-tricks-abusing.html https://googleprojectzero.blogspot.com/p/working-at-project-zero.html


https://www.youtube.com/watch?v=gu_i6LYuePg https://j00ru.vexillium.org/syscalls/nt/64/ http://www.exploit-monday.com/2013/08/writing-optimized-windows-shellcode-in-c.html https://hovav.net/ucsd/dist/noret-ccs.pdf


Acquiring Old/Vulnerable Software

Practice Exploit Development / Structured Learning

  • Exploit-Challenges - A collection of vulnerable ARM binaries for practicing exploit development
    • Here are a collection of vulnerable ARM binaries designed for beginner vulnerability researchers & exploit developers to play around with and test their skills!
  • BinTut
    • Dynamic or live demonstration of classical exploitation techniques of typical memory corruption vulnerabilities, from debugging to payload generation and exploitation, for educational purposes
  • ROP Emporium
    • Learn return-oriented programming through a series of challenges designed to teach ROP techniques in isolation, with minimal reverse-engineering and bug-hunting.
  • Pwnables.kr

  • Originally from (originally a pastebin link, which had been modified from a persons personal page, i believe it may have been an r2 dev?) If you made this, thank you so much; I've now added onto it and changed it from what it originally was. I've kept the original creator's note as I feel it is highly relevant and aligns with my goal)

  • "My intention with this document is for it to be somewhat of a recommended reading list for the aspiring hacker. I have tried to order the articles by technique and chronology. - sar"

Buffer overflows:

Return-into-lib / Return oriented programming:

Blind ROP

  • Blind Return Oriented Programming (BROP)
    • The BROP attack makes it possible to write exploits without possessing the target's binary. It requires a stack overflow and a service that restarts after a crash. Based on whether a service crashes or not (i.e., connection closes or stays open), the BROP attack is able to construct a full remote exploit that leads to a shell. The BROP attack remotely leaks enough gadgets to perform the write system call, after which the binary is transferred from memory to the attacker's socket. Following that, a standard ROP attack can be carried out. Apart from attacking proprietary services, BROP is very useful in targeting open-source software for which the particular binary used is not public (e.g., installed from source setups, Gentoo boxes, etc.). The attack completes within 4,000 requests (within minutes) when tested against a toy proprietary service, and real vulnerabilities in nginx and MySQL.
  • Hacking Blind - BROP paper
  • Blind Return Oriented Programming
  • Blind Return Oriented Programming (BROP) Attack (1)
  • Blind Return Oriented Programming (BROP) Attack (2)

Signal ROP

Jump Oriented Programming

Heap exploitation:

Format string exploitation:

Integer overflows:

Null-ptr dereference:



Kernel Exploitation

Addendum: Use-After-Free


Exploit Development Tutorials



  • ShellCode
    • 101
    • Articles/Blogposts/Writeups
    • Educational/Informative
      • Shellcode Time: Come on Grab Your Friends - wartortell -Derbycon4
        • Packed shellcode is a common deterrent against reverse engineering. Mainstream software will use it in order to protect intellectual property or prevent software cracking. Malicious binaries and Capture the Flag (CTF) challenges employ packed shellcode to hide their intended functionality. However, creating these binaries is an involved process requiring significant experience with machine language. Due to the complexity of creating packed shellcode, the majority of samples are painstakingly custom-created or encoded with very simple mechanisms, such as a single byte XOR. In order to aid in the creation of packed shellcode and better understand how to reverse engineer it, I created a tool to generate samples of modular packed shellcode. During this talk, I will demonstrate the use of the shellcode creation tool and how to reverse engineer the binaries it creates. I will also demonstrate an automated process for unpacking the binaries that are created.
    • How to Write it
    • Techniques
    • General
    • Reference/Resources
    • REPLs
      • rappel
        • Rappel is a pretty janky assembly REPL. It works by creating a shell ELF, starting it under ptrace, then continiously rewriting/running the .text section, while showing the register states. It's maybe half done right now, and supports Linux x86, amd64, armv7 (no thumb), and armv8 at the moment.(As of Aug 2017)
      • WinREPL
        • x86 and x64 assembly "read-eval-print loop" shell for Windows
    • Tools
      • General
        • Sickle
          • Sickle is a shellcode development tool, created to speed up the various steps needed to create functioning shellcode.
        • meterssh
          • MeterSSH is a way to take shellcode, inject it into memory then tunnel whatever port you want to over SSH to mask any type of communications as a normal SSH connection.
        • Shellcode_Tools
          • Miscellaneous tools written in Python, mostly centered around shellcodes.
          • bin2py: Embed binary files into Python source code.
          • shellcode2exe: Convert shellcodes into executable files for multiple platforms.
        • ShellSploit Framework
        • shellnoob
          • A shellcode writing toolkit
        • rex
          • Shellphish's automated exploitation engine, originally created for the Cyber Grand Challenge.
        • Patcherex
          • Shellphish's automated patching engine, originally created for the Cyber Grand Challenge.
        • sRDI
          • Shellcode implementation of Reflective DLL Injection. Convert DLLs to position independent shellcode
        • ShellcodeStdio
          • An extensible framework for easily writing debuggable, compiler optimized, position independent, x86 shellcode for windows platforms.
        • OWASP ZSC
          • OWASP ZSC is open source software written in python which lets you generate customized shellcode and convert scripts to an obfuscated script. This software can be run on Windows/Linux/OSX with python.
        • Shellen
          • Shellen is an interactive shellcoding environment. If you want a handy tool to write shellcodes, then shellen may be your friend. Shellen can also be used as an assembly or disassembly tool. keystone and capstone engines are used for all of shellen's operations. Shellen only works on python3. python2 support may appear in the future.
      • Encoders
        • Context-keyed Payload Encoding
          • A common goal of payload encoders is to evade a third-party detection mechanism which is actively observing attack traffic somewhere along the route from an attacker to their target, filtering on commonly used payload instructions. The use of a payload encoder may be easily detected and blocked as well as opening up the opportunity for the payload to be decoded for further analysis. Even so-called keyed encoders utilize easily observable, recoverable, or guessable key values in their encoding algorithm, thus making decoding on-the-fly trivial once the encoding algorithm is identified. It is feasible that an active observer may make use of the inherent functionality of the decoder stub to decode the payload of a suspected exploit in order to inspect the contents of that payload and make a control decision about the network traffic. This paper presents a new method of keying an encoder which is based entirely on contextual information that is predictable or known about the target by the attacker and constructible or recoverable by the decoder stub when executed at the target. An active observer of the attack traffic however should be unable to decode the payload due to lack of the contextual keying information.
      • Obfuscators
        • UniByAv
          • UniByAv is a simple obfuscator that take raw shellcode and generate executable that are Anti-Virus friendly. The obfuscation routine is purely writtend in assembly to remain pretty short and efficient. In a nutshell the application generate a 32 bits xor key and brute force the key at run time then perform the decryption of the actually shellcode.
    • Miscellaneous

Bypassing Exploit Protections/Mitigations & Corresponding literature

Exploit Development

  • ARM Specific Exploit Development
    • 101
    • Articles/Blogposts/Writeups
    • Educational/Informative
      • A SysCall to ARMs - Brendan Watters - Brendan Watters -Derbycon 2013
        • Description:ARM processors are growing more and more prevalent in the world; ARM itself claims that more than 20 billion chips have been shipped. Take a moment to appreciate that is about three chips for every man, woman, and child on earth. The three main topics I aim to cover are (1) how to perform a Linux system call on an ARM processor via assembly, ARM pipelining used in most modern ARM processors and how it came about, and (3) the really cool way ARM can avoid branching, even with conditional control flow. These will be explained in both code, English, and (hopefully successful) live demos using an ARM development board. The end result is to get the audience to understand how to create a simple socket program written in ARM assembly.
    • Papers
    • Tools
    • Miscellaneous
  • Adobe
  • Barcodes
      • Exploit using barcodes, QRcodes, earn13, datamatrix
  • Borrowed Instruction Programs
    • BISC: Borrowed Instructions Synthetic Computation
      • BISC is a Ruby library for demonstrating how to build borrowed-instruction programs. BISC aims to be simple, analogous to a traditional assembler, minimize behind-the-scenes magic, and let users write simple macros. BISC was developed by Dino Dai Zovi for Practical Return-oriented Programming at Blackhat USA 2010 and was used for the Assured Exploitation course.
  • BroadPwn
  • Cisco
  • Glibc
  • Hypervisor
    • Compromise-as-a-Service: Our PleAZURE.
      • This could be a comprehensive introduction about the ubiquity of virtualization, the essential role of the hypervisor, and how the security posture of the overall environment depends on it. However, we decided otherwise, as this is what everybody is interested in: We will describe the Hyper-V architecture in detail, provide a taxonomy of hypervisor exploits, and demonstrate how we found MS13-092 which had the potential to compromise the whole Azure environment. Live demo included!
  • Java Specific
  • Macros
  • Linux Specific Exploit Development
  • OS X Specific
    • 101
    • Articles/Blogposts/Papers/Writeups
      • IOHIDeous
        • A macOS kernel exploit based on an IOHIDFamily 0day.
        • Writeup
      • OS X Kernel-mode Exploitation in a Weekend
        • Apple's Mac OS X operating system is attracting more attention from users and security researchers alike. Despite this increased interest, there is still an apparent lack of detailed vulnerability development information for OS X. This paper will attempt to help bridge this gap by walking through the entire vulnerability development process. This process starts with vulnerability discovery and ultimately finished with a remote code execution. To help illustrate this process, a real vulnerability found in the OS X wireless device driver is used.
    • Educational/Informative
    • Tools
  • PDF
  • RPC
  • Software into Hardware back into Software
    • Exploiting the DRAM rowhammer bug to gain kernel privileges
      • "Rowhammer is a problem with some recent DRAM devices in which repeatedly accessing a row of memory can cause bit flips in adjacent rows. We tested a selection of laptops and found that a subset of them exhibited the problem. We built two working privilege escalation exploits that use this effect. One exploit uses rowhammer-induced bit flips to gain kernel privileges on x86-64 Linux when run as an unprivileged userland process. When run on a machine vulnerable to the rowhammer problem, the process was able to induce bit flips in page table entries (PTEs). It was able to use this to gain write access to its own page table, and hence gain read-write access to all of physical memory.
    • Program for testing for the DRAM "rowhammer" problem
  • Windows Specific
    • 101
    • Articles/Blogposts/Writeups
    • Educational/Informative
    • Papers
      • Getting out of Jail: Escaping Internet Explorer Protected Mode
        • With the introduction of Windows Vista, Microsoft has added a new form of mandatory access control to the core operating system. Internally known as "integrity levels", this new addition to the security manager allows security controls to be placed on a per-process basis. This is different from the traditional model of per-user security controls used in all prior versions of Windows NT. In this manner, integrity levels are essentially a bolt-on to the existing Windows NT security architecture. While the idea is theoretically sound, there does exist a great possibility for implementation errors with respect to how integrity levels work in practice. Integrity levels are the core of Internet Explorer Protected Mode, a new "low-rights" mode where Internet Explorer runs without permission to modify most files or registry keys. This places both Internet Explorer and integrity levels as a whole at the forefront of the computer security battle with respect to Windows Vista.
      • PatchGuard Reloaded: A Brief Analysis of PatchGuard Version 3
        • Since the publication of previous bypass or circumvention techniques for Kernel Patch Protection (otherwise known as "PatchGuard"), Microsoft has continued to refine their patch protection system in an attempt to foil known bypass mechanisms. With the release of Windows Server 2008 Beta 3, and later a full-blown distribution of PatchGuard to Windows Vista and Windows Server 2003 via Windows Update, Microsoft has introduced the next generation of PatchGuard to the general public ("PatchGuard 3"). As with previous updates to PatchGuard, version three represents a set of incremental changes that are designed to address perceived weaknesses and known bypass vectors in earlier versions. Additionally, PatchGuard 3 expands the set of kernel variables that are protected from unauthorized modification, eliminating several mechanisms that might be used to circumvent PatchGuard while co-existing (as opposed to disabling) it. This article describes some of the changes that have been made in PatchGuard 3. This article also proposes several new techniques that can be used to circumvent PatchGuard's defenses. Countermeasures for these techniques are also discussed.
      • Subverting PatchGuard Version 2
        • Windows Vista x64 and recently hotfixed versions of the Windows Server 2003 x64 kernel contain an updated version of Microsoft's kernel-mode patch prevention technology known as PatchGuard. This new version of PatchGuard improves on the previous version in several ways, primarily dealing with attempts to increase the difficulty of bypassing PatchGuard from the perspective of an independent software vendor (ISV) deploying a driver that patches the kernel. The feature-set of PatchGuard version 2 is otherwise quite similar to PatchGuard version 1; the SSDT, IDT/GDT, various MSRs, and several kernel global function pointer variables (as well as kernel code) are guarded against unauthorized modification. This paper proposes several methods that can be used to bypass PatchGuard version 2 completely. Potential solutions to these bypass techniques are also suggested. Additionally, this paper describes a mechanism by which PatchGuard version 2 can be subverted to run custom code in place of PatchGuard's system integrity checking code, all while leaving no traces of any kernel patching or custom kernel drivers loaded in the system after PatchGuard has been subverted. This is particularly interesting from the perspective of using PatchGuard's defenses to hide kernel mode code, a goal that is (in many respects) completely contrary to what PatchGuard is designed to do.
      • Bypassing PatchGuard on Windows x64
        • The version of the Windows kernel that runs on the x64 platform has introduced a new feature, nicknamed PatchGuard, that is intended to prevent both malicious software and third-party vendors from modifying certain critical operating system structures. These structures include things like specific system images, the SSDT, the IDT, the GDT, and certain critical processor MSRs. This feature is intended to ensure kernel stability by preventing uncondoned behavior, such as hooking. However, it also has the side effect of preventing legitimate products from working properly. For that reason, this paper will serve as an in-depth analysis of PatchGuard's inner workings with an eye toward techniques that can be used to bypass it. Possible solutions will also be proposed for the bypass techniques that are suggested.
    • Tools
      • Vulnserver
        • 'I have just released a program named Vulnserver - a Windows based threaded TCP server application that is designed to be exploited.''
      • Blackbone
        • Windows memory hacking library
    • Code Injection
    • DLL
    • Windows Heap Exploitation
    • Windows Kernel Exploitation
    • Patch Analysis
      • Microsoft Patch Analysis for Exploitation
        • Since the early 2000's Microsoft has distributed patches on the second Tuesday of each month. Bad guys, good guys, and many in-between compare the newly released patches to the unpatched version of the files to identify the security fixes. Many organizations take weeks to patch and the faster someone can reverse engineer the patches and get a working exploit written, the more valuable it is as an attack vector. Analysis also allows a researcher to identify common ways that Microsoft fixes bugs which can be used to find 0-days. Microsoft has recently moved to mandatory cumulative patches which introduces complexity in extracting patches for analysis. Join me in this presentation while I demonstrate the analysis of various patches and exploits, as well as the best-known method for modern patch extraction.
      • Microsoft Patch Analysis for Exploitation Stephen Sims
      • The Wallstreet of Windows Binaries - Marion Marschalek, Joseph Moti
      • Microsoft Patch Analysis for Exploitation
        • Since the early 2000's Microsoft has distributed patches on the second Tuesday of each month. Bad guys, good guys, and many in-between compare the newly released patches to the unpatched version of the files to identify the security fixes. Many organizations take weeks to patch and the faster someone can reverse engineer the patches and get a working exploit written, the more valuable it is as an attack vector. Analysis also allows a researcher to identify common ways that Microsoft fixes bugs which can be used to find 0-days. Microsoft has recently moved to mandatory cumulative patches which introduces complexity in extracting patches for analysis. Join me in this presentation while I demonstrate the analysis of various patches and exploits, as well as the best-known method for modern patch extraction.
    • Papers
      • ActiveX - Active Exploitation
        • This paper provides a general introduction to the topic of understanding security vulnerabilities that affect ActiveX controls. A brief description of how ActiveX controls are exposed to Internet Explorer is given along with an analysis of three example ActiveX vulnerabilities that have been previously disclosed.
      • Exploiting the Otherwise Non-Exploitable on Windows
        • This paper describes a technique that can be applied in certain situations to gain arbitrary code execution through software bugs that would not otherwise be exploitable, such as NULL pointer dereferences. To facilitate this, an attacker gains control of the top-level unhandled exception filter for a process in an indirect fashion. While there has been previous work illustrating the usefulness in gaining control of the top-level unhandled exception filter, Microsoft has taken steps in XPSP2 and beyond, such as function pointer encoding, to prevent attackers from being able to overwrite and control the unhandled exception filter directly. While this security enhancement is a marked improvement, it is still possible for an attacker to gain control of the top-level unhandled exception filter by taking advantage of a design flaw in the way unhandled exception filters are chained. This approach, however, is limited by an attacker's ability to control the chaining of unhandled exception filters, such as through the loading and unloading of DLLs. This does reduce the global impact of this approach; however, there are some interesting cases where it can be immediately applied, such as with Internet Explorer.
  • Countermeasures
    • BuBBle: A Javascript Engine Level Countermeasure against Heap-Spraying Attacks
      • Abstract. Web browsers that support a safe language such as Javascript are becoming a platform of great interest for security attacks. One such attack is a heap-spraying attack: a new kind of attack that combines the notoriously hard to reliably exploit heap-based buffer overflow with the use of an in-browser script- ing language for improved r eliability. A typical heap-s praying attack allocates a high number of objects containing the attacker’s code on the heap, dramatically increasing the probability that the contents of one of these objects is executed. In this paper we present a lightweight approach that makes heap-spraying attacks in Javascript significantly harder. Our prototype, which is implemented in Firefox, has a negligible performance and memory overhead while effectively protecting against heap-spraying attacks.



General Tools

Check out the 'Reverse Engineering" Section's Tools list for a lot of useful tools that aren't listed here.

  • General Tools
    • binwally
      • Binary and Directory tree comparison tool using the Fuzzy Hashing concept (ssdeep)
      • Using Binwally
    • lisa.py
      • An Exploit Dev Swiss Army Knife.
  • Hunting/Making Exploits Tools(DeBrujinn sequence)
    • Pattern-Create/offset as a python function
      • Metasploit pattern generator in Python, modified to be used as a function
    • !exploitable Crash Analyzer
      • !exploitable (pronounced bang exploitable) is a Windows debugging extension (Windbg) that provides automated crash analysis and security risk assessment. The tool first creates hashes to determine the uniqueness of a crash and then assigns an exploitability rating to the crash: Exploitable, Probably Exploitable, Probably Not Exploitable, or Unknown. There is more detailed information about the tool in the following .pptx file or at http://www.microsoft.com/security/msec. Additonally, see the blog post, or watch the video.
    • Findjmp2
      • Findjmp2 is a modified version of Findjmp from eEye.com to find jmp, call, push in a loaded DLL. This version includes search for pop/pop/ret set of instructions that is useful to bypass Windows XP SP2 and Windows 2003 stack protection mechanism.
    • binjitsu
      • binjitsu is a CTF framework and exploit development library. Written in Python, it is designed for rapid prototyping and development, and intended to make exploit writing as simple as possible.
  • Shellcode Tools
    • rp++
      • rp++ is a full-cpp written tool that aims to find ROP sequences in PE/Elf/Mach-O (doesn't support the FAT binaries) x86/x64 binaries. It is open-source, documented with Doxygen (well, I'm trying to..) and has been tested on several OS: Debian / Windows 7 / FreeBSD / Mac OSX Lion (10.7.3). Moreover, it is x64 compatible. I almost forgot, it handles both Intel and AT&T syntax (beloved BeaEngine). By the way, the tool is a standalone executable ; I will upload static-compiled binaries for each OS.

Decompilers & Disassemblers

  • List
    • Bokken
      • Bokken is a GUI for the Pyew and Radare projects so it offers almost all the same features that Pyew has and and some of the Radare's ones. It's intended to be a basic disassembler, mainly, to analyze malware and vulnerabilities. Currently Bokken is neither an hexadecimal editor nor a full featured disassembler YET, so it should not be used for deep code analysis or to try to modify files with it.
    • IDA
      • IDA Pro combines an interactive, programmable, multi-processor disassembler coupled to a local and remote debugger and augmented by a complete plugin programming environment.
      • Overview & Tutorials
      • Ida Plugins
        • Ida Sploiter
          • IDA Sploiter is a plugin for Hex-Ray's IDA Pro disassembler designed to enhance IDA's capabilities as an exploit development and vulnerability research tool. Some of the plugin's features include a powerful ROP gadgets search engine, semantic gadget analysis and filtering, interactive ROP chain builder, stack pivot analysis, writable function pointer search, cyclic memory pattern generation and offset analysis, detection of bad characters and memory holes, and many others.
        • Ida Pomidor
          • IDA Pomidor is a fun and simple plugin for the Hex-Ray's IDA Pro disassembler that will help you retain concentration and productivity during long reversing sessions.
        • FLARE-Ida
          • This repository contains a collection of IDA Pro scripts and plugins used by the FireEye Labs Advanced Reverse Engineering (FLARE) team.
    • Hopper
      • Hopper is a reverse engineering tool for OS X and Linux, that lets you disassemble, decompile and debug your 32/64bits Intel Mac, Linux, Windows and iOS executables!
    • Reverse
      • Reverse engineering for x86 binaries (elf-format). Generate a more readable code (pseudo-C) with colored syntax. Warning, the project is still in development, use it at your own risks. This tool will try to disassemble one function (by default main). The address of the function, or its symbol, can be passed by argument.
    • fREedom - capstone based disassembler for extracting to binnavi
    • fREedom is a primitive attempt to provide an IDA Pro independent means of extracting disassembly information from executables for use with binnavi (https://github.com/google/binnavi).
    • BinNavi
      • BinNavi is a binary analysis IDE that allows to inspect, navigate, edit and annotate control flow graphs and call graphs of disassembled code.


  • General/Platform Neutral
    • The Secret Lives of Debuggers - Lance Buttars - BSides SLC15
      • Binaries are files like any text file or a bitmap. They can be modified and changed.With some basic understanding of assembly language anyone can take a binary and modify its execution in a debugger and using a hex editor change how it executes. In this presentation I will cover the basics of binary manipulation and the use of debuggers to change program execution.
    • HyperDbg
      • HyperDbg is a kernel debugger that leverages hardware-assisted virtualization. More precisely, HyperDbg is based on a minimalistic hypervisor that is installed while the system runs. Compared to traditional kernel debuggers (e.g., WinDbg, SoftIce, Rasta R0 Debugger) HyperDbg is completely transparent to the kernel and can be used to debug kernel code without the need of serial (or USB) cables. For example, HyperDbg allows to single step the execution of the kernel, even when the kernel is executing exception and interrupt handlers. Compared to traditional virtual machine based debuggers (e.g., the VMware builtin debugger), HyperDbg does not require the kernel to be run as a guest of a virtual machine, although it is as powerful.
      • Paper
    • scdbg
      • scdbg is an open source, multi-platform, shellcode analysis application that runs shellcode through a virtual machine that emulates a 32bit processor, memory, and basic Windows API environment. scdbg uses the libemu library to provide this environment. Builds of scdbg exist for both Windows and Unix users.
    • scdbg Manual
    • xnippet
      • xnippet is a tool that lets you load code snippets or isolated functions (no matter the operating system they came from), pass parameters to it in several formats (signed decimal, string, unsigned hexadecimal...), hook other functions called by the snippet and analyze the result. The tool is written in a way that will let me improve it in a future, defining new calling conventions and output argument pointers.
    • voltron
      • Voltron is an extensible debugger UI toolkit written in Python. It aims to improve the user experience of various debuggers (LLDB, GDB, VDB and WinDbg) by enabling the attachment of utility views that can retrieve and display data from the debugger host. By running these views in other TTYs, you can build a customised debugger user interface to suit your needs.
  • Linux
    • GDB - GNU Debugger * GDB, the GNU Project debugger, allows you to see what is going on 'inside' another program while it executes -- or what another program was doing at the moment it crashed. * GDB 'exploitable' plugin * 'exploitable' is a GDB extension that classifies Linux application bugs by severity. The extension inspects the state of a Linux application that has crashed and outputs a summary of how difficult it might be for an attacker to exploit the underlying software bug to gain control of the system. The extension can be used to prioritize bugs for software developers so that they can address the most severe ones first. The extension implements a GDB command called 'exploitable'. The command uses heuristics to describe the exploitability of the state of the application that is currently being debugged in GDB. The command is designed to be used on Linux platforms and versions of GDB that include the GDB Python API. Note that the command will not operate correctly on core file targets at this time.
    • PEDA
      • PEDA - Python Exploit Development Assistance for GDB
    • radare2 as an alternative to gdb-peda
    • pwndbg - Making debugging suck less
      • A PEDA replacement. In the spirit of our good friend windbg, pwndbg is pronounced pwnd-bag.
      • Uses capstone as backend.
    • gdbgui
      • A modern, browser-based frontend to gdb (gnu debugger). Add breakpoints, view stack traces, and more in C, C++, Go, and Rust. Simply run gdbgui from the terminal and a new tab will open in your browser.
    • GEF - GDB Enhanced Features
      • GEF is aimed to be used mostly by exploiters and reverse-engineers. It provides additional features to GDB using the Python API to assist during the process of dynamic analysis or exploit development.
      • Why not PEDA?
      • Yes!! Why not?! PEDA is a fantastic tool to do the same, but is only to be used for x86-32 or x86-64. On the other hand, GEF supports all the architecture supported by GDB (x86, ARM, MIPS, PowerPC, SPARC, and so on).
      • Docs
  • Windows

Exploit Collections/Repository

GPU Exploits / Research

Temporal Return Address

  • Temporal Return Addresses
    • Nearly all existing exploitation vectors depend on some knowledge of a process' address space prior to an attack in order to gain meaningful control of execution flow. In cases where this is necessary, exploit authors generally make use of static addresses that may or may not be portable between various operating system and application revisions. This fact can make exploits unreliable depending on how well researched the static addresses were at the time that the exploit was implemented. In some cases, though, it may be possible to predict and make use of certain addresses in memory that do not have static contents. This document introduces the concept of temporal addresses and describes how they can be used, under certain circumstances, to make exploitation more reliable.
  • Automating Mimicry Attacks Using Static Binary Analysis
    • Intrusion detection systems that monitor sequences of system calls have recently become more sophisticated in defining legitimate application behavior. In particular, additional information, such as the value of the program counter and the configuration of the program's call stack at each system call, has been used to achieve better characterization of program behavior. While there is common agreement that this additional information complicates the task for the attacker, it is less clear to which extent an intruder is constrained. In this paper, we present a novel technique to evade the extended detection features of state-of-the-art intrusion detection systems and reduce the task of the intruder to a traditional mimicry attack. Given a legitimate sequence of system calls, our technique allows the attacker to execute each system call in the correct execution context by obtaining and relinquishing the control of the application's execution flow through manipulation of code pointers. We have developed a static analysis tool for Intel x86 binaries that uses symbolic execution to automatically identify instructions that can be used to redirect control flow and to compute the necessary modifications to the environment of the process. We used our tool to successfully exploit three vulnerable programs and evade detection by existing state-of-the-art system call monitors. In addition, we analyzed three real-world applications to verify the general applicability of our techniques.
  • Anti-Virus Software Gone Wrong
    • Anti-virus software is becoming more and more prevalent on end-user computers today. Many major computer vendors (such as Dell) bundle anti-virus software and other personal security suites in the default configuration of newly-sold computer systems. As a result, it is becoming increasingly important that anti-virus software be well-designed, secure by default, and interoperable with third-party applications. Software that is installed and running by default constitutes a prime target for attack and, as such, it is especially important that said software be designed with security and interoperability in mind. In particular, this article provides examples of issues found in well-known anti-virus products. These issues range from not properly validating input from an untrusted source (especially within the context of a kernel driver) to failing to conform to API contracts when hooking or implementing an intermediary between applications and the underlying APIs upon which they rely. For popular software, or software that is installed by default, errors of this sort can become a serious problem to both system stability and security. Beyond that, it can impact the ability of independent software vendors to deploy functioning software on end-user systems.
  • Sigreturn Oriented Programming is a real Threat
    • Abstract: This paper shows that Sigreturn Oriented Programming (SROP), which consists of using calls to sigreturn to execute arbitrary code, is a pow erful method for the de velopment of exploits. This is demonstrated by developing two different kinds of SROP based exploits, one asterisk exploit which was already portrayed in the paper presenting SROP, and one novel exploit for a recently disclosed bug inthe DNS address resolution of the default GNUC library. Taking advantage of the fact, that these exploits have very few dependencies on the program being exploited, a library is implemented to automate wide parts of SROP exploit creation. This highlights the potential of SROP in respect to reusable and portable exploit code which strongly supports the conclusion of the original paper: SROP is areal threat!
  • Breaking the links: Exploiting the linker
  • nt!_SEP_TOKEN_PRIVILEGES - Single Write EoP Protect - Kyriakos 'kyREcon' Economou
    • TL;DR: Abusing enabled token privileges through a kernel exploit to gain EoP it won't be enough anymore as from NT kernel version 10.0.15063 are 'checked' against the privileges present in the token of the calling process. So you will need two writes

Writeups that haven't been sorted

Attacking AntiVirus

Finding Vulnerabilities

  • Look at fuzzing section.
  • Winmerge
    • WinMerge is an Open Source differencing and merging tool for Windows. WinMerge can compare both folders and files, presenting differences in a visual text format that is easy to understand and handle.
  • Analyzing Common Binary Parser Mistakes
    • With just about one file format bug being consistently released on a weekly basis over the past six to twelve months, one can only hope developers would look and learn. The reality of it all is unfortunate; no one cares enough. These bugs have been around for some time now, but have only recently gained media attention due to the large number of vulnerabilities being released. Researchers have been finding more elaborate and passive attack vectors for these bugs, some of which can even leverage a remote compromise.

Finding and analyzing Crash dumps

High Level Searching

Searching Github for vulnerable code/credentials

Exploit Development Practice Lab Setup

Building a Lab to practice Exploit writing(Windows, x86, OSCE Prep)

So, this is a thing I found while doing some googling. If you wrote this, I owe you a lot of beer. I redacted the place/username as it was on a less than happy place.

This assumes you have an idea of ASM x86 and general exploitation methods.

Idea with this setup, is that you have a VM of XP SP3 running with the following software and tools installed. You look up the exploits on exploit-db and recreate them. Or you lookup the vulnerabilities and fuzz it yourself knowing where to look.

Start here:
I'm designing exploit lab based on WinXP SP3. As for now I have following vulnerabilities/apps:

1. Simple RET - Ability FTP Server (FTP)
2. Simple RET - FreeFloat FTP (FTP)
3. Simple RET (harder) - CesarFTP (FTP)
4. Simple RET - Easy RM to MP3 Converter (.pls)
5. Simple RET - DL-10 - Need to find copy of
6. SEH - DVDXPlayer
7. SEH - Millenium
8. SEH - Soritong
9. SEH - mp3nator
10. SEH - NNM (hard) - Need to find copy of
11. SEH + UNICODE - ALLPlayer
12. SEH (difficult) - Winamp

with following tools installed:

1. WinDBG + MSEC.dll (!load winext\msec.dll) + byakugan (!load byakugan)
2. Immunity Debugger + mona.py (!mona)
3. OllyDBG+Plugins(SSEH+OllySnake+AdvancedOlly+OllyHeapVis+Virtual2Physical)
4. C:\Windows\system32\findjmp2.exe
5. Cygwin + perl + gdb + gcc...
6. Python26 (for IDA) + PyDbg - https://code.google.com/p/pydbgr/wiki/HowToInstall
6. Python27 (for ImmunityDebugger)+pyDbg
7. lcc-win
8. Wireshark
9. Mantra on Chrome (MoC)
10. Google-Chrome
11. Microsoft Visual C++ 2008 Express
12. Nasm
13. metasploit
14. Alpha3 (c:\Alpha3)
15. IDA
16. Sysinternals (c:\Windows\System32)
17. Proxifier Edition
18. Echo Mirage


End Sort