Hacking Tools

DLL Universal Patcher – A Comprehensive Guide To Advanced Binary Patching

DLL Universal Patcher is a flexible and convenient code patcher that doesn’t touch the files on disk.

It can be used for replacing any tasks that you’d otherwise achieve with on-disk patching, such as fixing old software on modern machines, or fixing bugs in others’ software.

In addition, due to more control over when the patching happens, it is possible to patch packed executables.

How To Use

  1. Pick a suitable dll to proxy, like version.dll
  2. Use dll-proxy-generator.exe --import-dll "dll_universal_patcher.dll" --import "dummy" "C:\Windows\System32\version.dll" to generate a suitable proxy dll
  3. Write up your patches into patches.json (more on this later)
  4. Place the generated dll, dll_universal_patcher.dll, and patches.json in target directory to perform dll hijacking

How To Use (Advanced)

  1. Pick a suitable dll to proxy, like version.dll
  2. Use dll-proxy-generator.exe --import-dll "dll_universal_patcher.dll" --import "dummy" "C:\Windows\System32\version.dll" to generate a suitable proxy dll
  3. Write up your patches into patches.json (more on this later)
  4. Use a tool like CFF Explorer to add the config as a RCDATA resource with ID 1 and neutral language to dll_universal_patcher.dll
  5. Place the generated dll and dll_universal_patcher.dll in target directory to perform dll hijacking

patches.json

Example:

[
    {
        "modules": [ "winver.exe", "{exe}" ],
        "pattern": "01 02 03 04 05 ? 06 ?? 07",
        "replacement": "90 90 90 90 C3",
        "min_matches": 1,
        "max_matches": 3,
        "on_initialize": false,
        "on_process_initialized": true,
        "on_before_dllmain": false,
        "is_code": true,
        "allowed_to_fail": false,
        "multishot": false
    }
]

For more info on the options, check out the schema

Tamil S

Tamil has a great interest in the fields of Cyber Security, OSINT, and CTF projects. Currently, he is deeply involved in researching and publishing various security tools with Kali Linux Tutorials, which is quite fascinating.

Recent Posts

Shadow-rs : Harnessing Rust’s Power For Kernel-Level Security Research

shadow-rs is a Windows kernel rootkit written in Rust, demonstrating advanced techniques for kernel manipulation…

1 week ago

ExecutePeFromPngViaLNK – Advanced Execution Of Embedded PE Files via PNG And LNK

Extract and execute a PE embedded within a PNG file using an LNK file. The…

2 weeks ago

Red Team Certification – A Comprehensive Guide To Advancing In Cybersecurity Operations

Embark on the journey of becoming a certified Red Team professional with our definitive guide.…

2 weeks ago

CVE-2024-5836 / CVE-2024-6778 : Chromium Sandbox Escape via Extension Exploits

This repository contains proof of concept exploits for CVE-2024-5836 and CVE-2024-6778, which are vulnerabilities within…

3 weeks ago

Rust BOFs – Unlocking New Potentials In Cobalt Strike

This took me like 4 days (+2 days for an update), but I got it…

3 weeks ago

MaLDAPtive – Pioneering LDAP SearchFilter Parsing And Security Framework

MaLDAPtive is a framework for LDAP SearchFilter parsing, obfuscation, deobfuscation and detection. Its foundation is…

3 weeks ago