Skip to content

A powerful Lua obfuscator designed to make your Lua code nearly impossible to reverse-engineer, with multiple layers of advanced obfuscation techniques

License

Notifications You must be signed in to change notification settings

zeusssz/hercules-obfuscator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

73 Commits
 
 
 
 
 
 

Repository files navigation

herculessmall

Hercules Lua Obfuscator

Stars Forks Issues License Last Commit
Hercules is a powerful Lua obfuscator designed to make your Lua code nearly impossible to reverse-engineer. With multiple layers of advanced obfuscation techniques, Hercules ensures your scripts are secure from prying eyes.
Hercules is very much still in development, and may not be the best yet, but we will make sure that it shall grow to be one of the best
Contact either roboxer_ or xthrx0 on discord for queries, or join the discord server

Caution

Obfuscation is not a foolproof method for protecting your code! Always consider additional security measures depending on your use case.

Note

Hercules is mainly a base lua/luau obfuscator, and a glua patch is coming soon.


Features

  • String Encoding: Obfuscates strings by encoding them in base64 with additional scrambling.
  • Variable Renaming: Replaces variable names with randomly generated names.
  • Control Flow Obfuscation: Adds fake control flow structures to confuse static analysis.
  • Garbage Code Insertion: Injects junk code to bloat and obscure the script.
  • Watermarking: Automatically appends a watermark to indicate that the code has been obfuscated by Hercules.

Tip

You can customise your level of obfuscation through the config.py file.


Installation

macOS and Linux

  1. Clone this repository:

    git clone https://github.com/zeusssz/hercules-obfuscator.git
    cd hercules-obfuscator
    cd src
  2. Make the hercules script executable:

    chmod +x hercules
  3. Run the obfuscator:

    ./hercules path/to/your/script.lua

Note

Ensure you are in the working directory of the executable, i.e, src by default Alternatively, you can use the Lua interpreter directly if it is added to your system PATH.

Windows

  1. Clone this repository using Git Bash or download the ZIP file and extract it.

  2. Open Command Prompt or PowerShell and navigate to the hercules-obfuscator directory.

  3. Run the obfuscator using Lua:

    lua hercules path\to\your\script.lua

Usage

To obfuscate a Lua script using Hercules, simply run:

./hercules path/to/your/script.lua  # macOS/Linux
lua hercules path\to\your\script.lua  # Windows

This will generate an obfuscated version of the script in the same directory, with the filename *_obfuscated.lua.

Example

./hercules my_script.lua  # macOS/Linux
lua hercules my_script.lua  # Windows

Output: my_script_obfuscated.lua – the obfuscated version of your script. Or, if you specify overwrite with the --overwrite flag, it will write back to the specified script

Customization

You can modify or add new modules to the modules/ directory to create additional layers of obfuscation. The pipeline.lua file controls the order of obfuscation steps.


Project Structure

src/
│
├── hercules            # Main entry point (executable)
├── pipeline.lua        # Obfuscation pipeline
└── modules/            # Obfuscation modules  

Important

When adding more modules to the modules/ directory, ensure you maintain integrity of the executable, and remember to add your module to the pipeline.lua file

About

A powerful Lua obfuscator designed to make your Lua code nearly impossible to reverse-engineer, with multiple layers of advanced obfuscation techniques

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages