All Projects → superblaubeere27 → Obfuscator

superblaubeere27 / Obfuscator

Licence: mit
A java obfuscator (GUI)

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to Obfuscator

Deobfuscation
Binary Deobfuscation Series
Stars: ✭ 15 (-95.56%)
Mutual labels:  obfuscation
idy
👓 An ID obfuscator for ActiveRecord
Stars: ✭ 15 (-95.56%)
Mutual labels:  obfuscation
email-concealer-cli
CLI tool for concealing e-mails in a file by replacing their domain
Stars: ✭ 30 (-91.12%)
Mutual labels:  obfuscation
dark-lord-obama
AV-evading Pythonic Reverse Shell with Dynamic Adaption Capabilities
Stars: ✭ 61 (-81.95%)
Mutual labels:  obfuscation
mumbojumbo
Obfuscates golang strings
Stars: ✭ 29 (-91.42%)
Mutual labels:  obfuscation
Networkteam.Neos.MailObfuscator
Email address obfuscation for Neos CMS
Stars: ✭ 13 (-96.15%)
Mutual labels:  obfuscation
email-concealer
Conceal e-mail addresses in a string by replacing their domain
Stars: ✭ 47 (-86.09%)
Mutual labels:  obfuscation
Utls
Fork of the Go standard TLS library, providing low-level access to the ClientHello for mimicry purposes.
Stars: ✭ 306 (-9.47%)
Mutual labels:  obfuscation
ConfuserEx-Mod-By-Bed
Beds Protector | Best free obfuscation out right now
Stars: ✭ 297 (-12.13%)
Mutual labels:  obfuscation
inceptor
Template-Driven AV/EDR Evasion Framework
Stars: ✭ 730 (+115.98%)
Mutual labels:  obfuscation
data obfuscation
Data Obfuscation for C/C++ Code Based on Residue Number Coding (RNC)
Stars: ✭ 15 (-95.56%)
Mutual labels:  obfuscation
obfuscator
Obfuscate PHP source files with basic XOR encryption in userland code at runtime.
Stars: ✭ 20 (-94.08%)
Mutual labels:  obfuscation
AndrODet
AndrODet: An Adaptive Android Obfuscation Detector
Stars: ✭ 25 (-92.6%)
Mutual labels:  obfuscation
defendjs
A free and open source JavaScript and Node.js obfuscator.
Stars: ✭ 26 (-92.31%)
Mutual labels:  obfuscation
Obfuscate
Guaranteed compile-time string literal obfuscation header-only library for C++14
Stars: ✭ 260 (-23.08%)
Mutual labels:  obfuscation
id-mask
IDMask is a Java library for masking internal ids (e.g. from your DB) when they need to be published to hide their actual value and to prevent forging. It has support optional randomisation has a wide support for various Java types including long, UUID and BigInteger. This library bases its security on strong cryptographic primitives.
Stars: ✭ 39 (-88.46%)
Mutual labels:  obfuscation
UniObfuscator
Java obfuscator that hides code in comment tags and Unicode garbage by making use of Java's Unicode escapes.
Stars: ✭ 40 (-88.17%)
Mutual labels:  obfuscation
Pyprotect
A lightweight python code protector, makes your python project harder to reverse engineer
Stars: ✭ 317 (-6.21%)
Mutual labels:  obfuscation
Nt wrapper
A wrapper library around native windows sytem APIs
Stars: ✭ 287 (-15.09%)
Mutual labels:  obfuscation
sus
A now actually pretty good amogus themed javascript obfuscator lol
Stars: ✭ 23 (-93.2%)
Mutual labels:  obfuscation

Obfuscator Build Status Join the chat at https://gitter.im/superblaubeere27/obfuscator Donate

A Java bytecode obfuscator supporting

  • Flow Obfuscation
  • Line Number Removal
  • Number Obfuscation
  • Optimisation
  • Name Obfuscation (Classes, methods and fields) with custom dictionaries
  • Deobfuscator crasher
  • String Encryption
  • Inner Class Removal
  • HWID Locking
  • Invoke Dynamic
  • Reference Proxy
  • Member Shuffling & Hiding

Feel free to join my discord server: Discord Chat

Obfuscated code

Luyten + Procyon

Without


public class HelloWorld {
    public HelloWorld() {
        super();
    }
    
    public static void main(final String[] args) {
        System.out.println("Hello World");
        for (int i = 0; i < 10; ++i) {
            System.out.println(i);
        }
    }
}

Obfuscated (short version for full code visit https://pastebin.com/RFHtgPtX)


public class HelloWorld {
    
    public static void main(final String[] array) {
        // invokedynamic(1:(Ljava/io/PrintStream;Ljava/lang/String;)V, invokedynamic(0:()Ljava/io/PrintStream;), HelloWorld.llII[HelloWorld.lllI[0]])
        float lllllllIlIllIII = HelloWorld.lllI[0];
        while (llIll((int)lllllllIlIllIII, HelloWorld.lllI[1])) {
            // invokedynamic(2:(Ljava/io/PrintStream;I)V, invokedynamic(0:()Ljava/io/PrintStream;), lllllllIlIllIII)
            ++lllllllIlIllIII;
            "".length();
            if (" ".length() == (" ".length() << ("   ".length() << " ".length()) & ~(" ".length() << ("   ".length() << " ".length())))) {
                throw null;
            }
        }
    }
    
}

Usage

--help Prints the help page on the screen

--version Shows the version of the obfuscator

--jarIn <input> Input JAR

--jarOut <output> Output JAR

--config <configFile> Config File

--cp <classPath> Class Path

--scriptFile <scriptFile> A JS file to script certain parts of the obfuscation

--threads Sets the number of threads the obfuscator should use

--verbose Sets logging to verbose mode

Examples

java -jar obfuscator.jar --jarIn helloWorld.jar --jarOut helloWorld-obf.jar

java -jar obfuscator.jar --jarIn helloWorld.jar --jarOut helloWorld-obf.jar --config obfConfig

Example Config

{
  "input": "D:\\Computing\\HelloWorld\\out\\artifacts\\HelloWorld_jar\\HelloWorld.jar",
  "output": "D:\\Computing\\HelloWorld\\out\\artifacts\\HelloWorld_jar\\HelloWorld-obf.jar",
  "script": "function isRemappingEnabledForClass(node) {\n    return true;\n}\nfunction isObfuscatorEnabledForClass(node) {\n    return true;\n}",
  "libraries": [
    "C:\\Program Files\\Java\\jre1.8.0_211\\lib",
    "D:\\Computing\\backdoored_old\\dependencies",
    "D:\\Computing\\backdoored\\libs"
  ],
  "Crasher": {
    "Enabled": false,
    "Invalid Signatures": true,
    "Empty annotation spam": true
  },
  "InvokeDynamic": {
    "Enabled": true
  },
  "HWIDPRotection": {
    "Enabled": false,
    "HWID": ""
  },
  "Optimizer": {
    "Enabled": true,
    "Replace String.equals()": true,
    "Replace String.equalsIgnoreCase()": true,
    "Optimize static string calls": true
  },
  "LineNumberRemover": {
    "Enabled": true,
    "Rename local variables": true,
    "Remove Line Numbers": true,
    "Remove Debug Names": true,
    "Add Local Variables": true,
    "New SourceFile Name": ""
  },
  "StringEncryption": {
    "Enabled": true,
    "HideStrings": true,
    "AES": true
  },
  "NumberObfuscation": {
    "Enabled": true,
    "Extract to Array": true,
    "Obfuscate Zero": true,
    "Shift": false,
    "And": false,
    "Multiple Instructions": true
  },
  "ReferenceProxy": {
    "Enabled": false
  },
  "ShuffleMembers": {
    "Enabled": true
  },
  "InnerClassRemover": {
    "Enabled": true,
    "Remap": true,
    "Remove Metadata": true
  },
  "NameObfuscation": {
    "Enabled": true,
    "Excluded classes": "HelloWorld",
    "Excluded methods": "",
    "Excluded fields": ""
  },
  "General Settings": {
    "Custom dictionary": true,
    "Name dictionary": "hello,world"
  },
  "Packager": {
    "Enabled": false,
    "Use MainClass from the JAR manifest": true,
    "Main class": "HelloWorld"
  },
  "FlowObfuscator": {
    "Enabled": true,
    "Mangle Comparisons": true,
    "Replace GOTO": true,
    "Replace If": true,
    "Bad POP": true,
    "Bad Concat": true,
    "Mangle Switches": false,
    "Mangle Return": false,
    "Mangle Local Variables": false
  },
  "HideMembers": {
    "Enabled": true
  },
  "Inlining": {
    "Enabled": false
  }
}

Excluding Classes

In some situations you need to prevent certain classes from being obfuscated, such as dependencies packaged with your jar or mixins in a forge mod.

You will need to exclude in two places.

Scripting Tab

Here is an example script that will obfuscate and remap all classes except the org.json dependency and mixins.

function isRemappingEnabledForClass(node) {
    var flag1 = !node.name.startsWith("org/json");
    var flag2 = !node.name.startsWith("com/client/mixin");
    return flag1 && flag2;
}
function isObfuscatorEnabledForClass(node) {
    var flag1 = !node.name.startsWith("org/json");
    var flag2 = !node.name.startsWith("com/client/mixin");
    return flag1 && flag2;
}
Name Obfuscation

If you also want to exclude these classes from name obfuscation you will need to go to Transformers -> Name Obfuscation and add these exclusions there.

To Exclude the same classes as we did above, we would need to add the following to Excluded classes, methods and fields.

org.json.**
com.client.mixin.**

If your classes are still being obfuscated after applyinng both of these exclusions please open an issue.

Contributing

1. Fork the repository
  • Click the "Fork" button at the top right hand corner of this page
  • Then run git clone https://github.com/[your github username]/obfuscator.git
2. Import into IntelliJ
  • File -> New -> Project From Existing Sources
  • Select C:\[Path To]\obfuscator\pom.xml
  • Set "Search for projects recursively" and "Import Maven projects automatically" to true and click next
  • Make sure all maven projects are ticked
  • Select the correct Java SDK and go with all the default options for the next pages
3. Editing
  • Make any edits
  • Package the project to make sure that the project is still functional:
    • java -Dmaven.multiModuleProjectDirectory=D:\Computing\obfuscator\obfuscator-core "-Dmaven.home=C:\Program Files\JetBrains\IntelliJ IDEA 2019.1.3\plugins\maven\lib\maven3" "-Dclassworlds.conf=C:\Program Files\JetBrains\IntelliJ IDEA 2019.1.3\plugins\maven\lib\maven3\bin\m2.conf" "-javaagent:C:\Program Files\JetBrains\IntelliJ IDEA 2019.1.3\lib\idea_rt.jar=18889:C:\Program Files\JetBrains\IntelliJ IDEA 2019.1.3\bin" -Dfile.encoding=UTF-8 -classpath "C:\Program Files\JetBrains\IntelliJ IDEA 2019.1.3\plugins\maven\lib\maven3\boot\plexus-classworlds-2.5.2.jar" org.codehaus.classworlds.Launcher -Didea.version2019.1.3 package (Change any paths to be relevant to your system)
3. Commit
  • Run git status to see which files you've changed
  • Run git add [file name] for each of the files you want to submit your changes to
  • Do git commit -m "[A description of the changes]"
  • And finally git push to upload your changes to GitHub
4. Pull Request
  • Go to https://github.com/[your github username]/obfuscator and click "Pull Requests" and then "New Pull Request"
  • Make sure all your changes are included then submit the Pull Request.

Credits

  • MCInjector (FFixer base)
  • FFixer (Obfuscator base)
  • SmokeObfuscator (Some ideas)
  • MarcoMC (Some ideas)
  • ItzSomebody (NameUtils.crazyString(), Crasher)
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].