explaingit

ridter/binhol

Analysis updated 2026-08-04 · repo last pushed 2024-09-10

Audience · researcherComplexity · 4/5StaleSetup · moderate

TLDR

BinHol is a command-line security research tool that injects custom code into compiled Windows programs without needing the original source code. It offers three injection methods for studying how altered programs behave.

Mindmap

mindmap
  root((repo))
    What it does
      Injects code into EXEs
      Three injection methods
      Modifies program behavior
    Injection methods
      Function Patch
      Entrypoint Hijack
      TLS Injection
    Tech stack
      Go language
      Command-line interface
      No heavy external libraries
    Use cases
      Antivirus detection testing
      Endpoint security testing
      Application logic testing
    Audience
      Security researchers
      Penetration testers
      Malware analysts

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Inject test code into a harmless program to see if antivirus software detects the modification.

USE CASE 2

Test how a Windows application responds when its internal functions are patched or replaced.

USE CASE 3

Evaluate endpoint security tools by modifying digitally signed executables and observing detection.

USE CASE 4

Study early-stage program startup behavior using TLS callback injection techniques.

What is it built with?

GoCLIWindows

How does it compare?

ridter/binhol00kaku/gallery-slider-block04amanrajj/netwatch
Stars0
LanguageJavaScriptRust
Last pushed2024-09-102021-05-19
MaintenanceStaleDormant
Setup difficultymoderateeasymoderate
Complexity4/52/53/5
Audienceresearchergeneralops devops

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Requires Go installed and comfort with command-line tools and Windows executable internals, modified files may trigger antivirus alerts.

The explanation does not mention a license, so the terms of use are unclear.

In plain English

BinHol is a security research tool that lets you insert custom code into existing Windows executable files. Think of it as a way to modify a program's behavior after it has been compiled, without needing access to the original source code. It is designed for people working in cybersecurity, malware analysis, or software testing who need to study how programs behave when their code is altered. The tool offers three different methods for injecting code into a Windows executable. The first method, "Function Patch," replaces or modifies a specific function within the target program. The second, "Entrypoint Hijack," changes the starting point of the executable so that your custom code runs first when the program launches. The third, "TLS Injection," uses a built-in Windows mechanism called Thread Local Storage to run your code at a very early stage of the program's startup. You choose the method that best fits your research scenario, run the tool from the command line, and it produces a modified version of the executable. Security researchers and penetration testers are the primary audience. For example, a researcher studying how antivirus software detects threats might use this tool to embed test code into a harmless utility program, then observe whether security systems catch the modification. It is also useful for testing how applications respond to unexpected changes in their internal logic. The tool handles Windows digital signatures, meaning it can even modify programs that carry a publisher's signature, which is valuable for testing endpoint security tools. It is worth noting that the project is built using the Go programming language and does not rely on heavy external code libraries for dissecting binary files. The README is clear that this is strictly an educational and research tool. Modifying executables can break them, and antivirus software will likely flag the results as suspicious. You should back up any files before modifying them.

Copy-paste prompts

Prompt 1
I want to use BinHol to inject a small code stub into a Windows utility using the Entrypoint Hijack method. Walk me through the exact command-line flags and steps, including how to specify the target EXE, my custom code, and the output file.
Prompt 2
I have a harmless Windows EXE and want to use BinHol's Function Patch method to replace a specific function with my own code. How do I identify which function to target and what format does my replacement code need to be in?
Prompt 3
Help me set up BinHol from source. The project is written in Go with minimal external dependencies. What are the build steps and prerequisites on a Windows machine?
Prompt 4
I want to use BinHol's TLS Injection method to run custom code at the earliest stage of a Windows program's startup. Explain how this method differs from Entrypoint Hijack and when I should choose it instead.

Frequently asked questions

What is binhol?

BinHol is a command-line security research tool that injects custom code into compiled Windows programs without needing the original source code. It offers three injection methods for studying how altered programs behave.

Is binhol actively maintained?

Stale — no commits in 1-2 years (last push 2024-09-10).

What license does binhol use?

The explanation does not mention a license, so the terms of use are unclear.

How hard is binhol to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is binhol for?

Mainly researcher.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.