ssheera/Some-Java-Obfuscator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

50 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A modified version of cheatbreaker-obf to test out some ideas I had

Native obfuscators shouldn't be used for production

  • StripTransformer
    • Strips debug information from classes, methods and fields
  • ChecksumTransformer
    • Inserts block of code inside configurable class which will check if the target method is modified, uses modified asm to check constant pool and method bytecode
  • InlinerTransformer (Disabled)
    • Tries to inline methods, does need massive improvements
  • VariableTransformer
    • Just converted local variables to java.lang.Object[]
  • ConstantPoolTransformer (Unstable)
    • Uses native method to modify constant pool and applies some simple number obfuscation
    • Uses basic xor encryption which shows the key it would be best to change it
  • CodeHiderTransformer (Unstable)
    • Uses natives to hide method bytecode from the code attribute
  • PackerTransformer
    • Packs classes into a single file which are loaded afterwards
  • ToStringTransformer
    • Saw something cool in a source obfuscator and decided to implement it, converts strins to new Object() { toString... return "String" }.toString()
  • ExceptionTransformer
    • Turns local storing to storing of exception objects
  • CodeHider
    • won't go over exceptions
    • skips methodhandle and class ldc
    • skips synthetic methods
    • breaks on classes with generated methods
    • can break randomly due to constant pool not being updated when generating bytes

You use the obfuscator by creating a config file much like the one provided and parsing it through command line

java -jar obfuscator.jar --config config.yml

String Obfuscation

Variable Obfuscation

Inliner Obfuscation

Checksum Obfuscation

ConstantPool Obfuscation

Packer Obfuscation

CodeHider Obfuscation

Exception Obfuscation

  • cheatbreaker-obf for base
  • most of utils methods aren't mine
  • yaml classes for config stolen from bukkit

About

Some java obfuscator I made to test out transformer ideas

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •