Skip to content


Folders and files

Last commit message
Last commit date

Latest commit



97 Commits

Repository files navigation



Fentanyl is an IDAPython script that makes patching significantly easier. Fentanyl lets you patch from IDA Pro or Demo easily. Most patches can be done without touching a hex editor but if you must edit raw bytes you can simply use IDA's hex view. You can also undo and redo changes to the idb.

Fentanyl supercedes other tools for binary patching by being able to assemble with IDA's built in assemblers which can support more than x86 and x86_64. Fentanyl also automates commonly performed patches. One of Fentanyl's best features is that it supports Undo/Redo. We can see changes to the graph live and undo them if they aren't to our liking.

Setup (IDA 7.x / Python 3)

Simply move all items from this repository into the following directory:


The %IDA% directory can usually be found bellow:

C:\Program Files\IDA <version>\

Now on program start, the plugin will be loaded automatically.

Setup (IDA 6.x / Python 2)

Need to add backwards compatibility with IDA 6.x / Python2 or mark as deprecated.


  1. Download IDAPython here.
  2. Move appropriate folders to IDA plugins directory as per the README

IDA PySide

  1. Download (custom built by ancat): Python 2.7 PySide bindings installer or raw.
  2. Extract and move PySide folder to C:\python27\Lib\site-packages\



IDA 7.x / Python 3

Follow instructions under Setup.

IDA 6.x / Python 2

  1. Alt+F7 or File > Script File to load scripts
  2. Browse to and open it
  3. That's it!

Key Bindings

Some of these keybindings can be accessed by right-clicking on the screen in graph view.

  • Ctrl-Alt-N Convert instructions to nops
  • Ctrl-Alt-X Nop all xrefs to this function
  • Ctrl-Alt-J Invert conditional jump
  • Ctrl-Alt-P Patch instruction
  • Alt-Z Undo modification (Won't always work. Should still be careful editing.)
  • Alt-Y Redo modification (Won't always work. Should still be careful editing.)
  • Ctrl-Alt-S Save file
  • Ctrl-Alt-C Find Code Caves
  • Ctrl-Alt-F Make jump unconditional
  • Alt-N Neuter the binary (remove calls to fork, setuid, setgid, getpwnam, setgroups, and chdir)


Loading Fentanyl on Startup

Check out this example.


PySide is annoying to compile. If you don't want to use the PySide binaries available here, or don't want to compile it yourself, you don't actually need it. Fentanyl will not use the GUI if PySide is not available.


Fentanyl is an IDAPython script that makes patching significantly easier






No releases published


No packages published

Contributors 4