ItzSomebody / radon

[Abandoned] Scuffed java bytecode obfuscator
GNU General Public License v3.0
362 stars 74 forks source link

[BUG] Software not changing anything #94

Closed ghost closed 3 years ago

ghost commented 3 years ago

Description of Bug: The software does not change a single thing except compress the assets a bit more

Expected behavior: The final jar should have been obfuscated, or at least optimized

Radon version: Radon 3

Configuration: The default (or example) config. Here it is written out:

input: "ccl-1.0.0.jar"
output: "ccl-obf.jar"
libraries:
  - "/usr/lib/jvm/java-8-openjdk-amd64/lib/ct.sym"
flow_obfuscation:
  # Insert fake switches in the bytecode more CFG edges
  insert_bogus_switch_jumps: true

  # Insert fake if-confitions to create more CFG edges
  insert_bogus_jumps: true

  # Reorder the bytecode by splitting it in half multiple times
  split_blocks: true

  # Replace IF_ACMP<EQ/NE> with try-catch blocks
  mutilate_null_check: true

# Obfuscate API references
reference_obfuscation:
  # Hide method invocations using a relatively fast dynamic invoker
  hide_with_fast_indy: true

# Encrypt string constants
string_encryption:
  # Compute decryption keys based on the context of the decryption call
  # Note: slows down runtime
  check_context: true

  # Pool strings into field
  pool_strings: true

# Apply ACC_SYNTHETIC (0x1000) and ACC_BRIDGE (0x0040) access flags to classes/methods/fields
hide_code:
  # Apply ACC_SYNTHETIC (0x1000) access flags
  hide_classes: true

  # Apply ACC_SYNTHETIC (0x1000) and ACC_BRIDGE (0x0040) access flags
  hide_methods: true

  # Apply ACC_SYNTHETIC (0x1000) access flags
  hide_fields: true

# Scramble numerical constants
number_obfuscation:
  # Allow Radon to tamper with integers
  integer_tampering: true

  # Allow Radon to tamper with longs
  long_tampering: true

  # Use bitwise (&, |, ^, <<, >>, >>>) operations to obscure (integers and longs only)
  bitwise_operations: true

  # Use arithmetic (+, -, *, /, %) operations to obscure
  arithmetic_operations: true

# Randomize the order of fields and methods
member_shuffler:
  # Randomize the order of fields
  shuffle_fields: true

  # Randomize the order of methods
  shuffle_methods: true

# Level of compression to use on the output JAR
compression_level: 9

# Name generation dictionary to use (custom)
dictionary: "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"

# Initial string length for randomly generated strings
randomized_string_length: 1
shrinker:
  # Remove InnerClass attributes
  remove_inner_classes: true

  # Remove runtime-invisible annotations
  remove_invisible_annotations: true

  # Remove runtime-invisible parameter annotations
  remove_invisible_parameter_annotations: true

  # Remove runtime-invisible type annotations
  remove_invisible_type_annotations: true

  # Remove line numbers from stacktraces
  remove_line_numbers: true

  # Remove local variable information
  remove_local_variables: true

  # Removes OuterClass and OuterMethod attributes
  remove_outer_method: true

  # Remove class/method/field signatures
  remove_signature: true

  # Remove SourceDebug attributes
  remove_source_debug: true

  # Remove SourceFile attributes
  remove_source_file: true

  # Remove ACC_SYNTHETIC (0x1000) and ACC_BRIDGE (0x0040) access flags
  remove_synthetic: true

  # Remove unknown attributes
  remove_unknown_attributes: true

# Optimize the bytecode
optimizer:
  # Inline GOTO->GOTO sequences
  inline_goto_goto: true

  # Inline GOTO->(RETURN/IRETURN/LRETURN/FRETURN/DRETURN/ARETURN) sequences
  inline_goto_return: true

  # Remove nops
  remove_nops: true

Relevant errors: No errors

Screenshots: Before: image

After: image

Reproduction steps:

  1. Make a jarfile
  2. Run the obfuscator
  3. Observe
ItzSomebody commented 3 years ago

I thought this was a huge fluke until I saw you used radon 3. A majority of radon's transformers are not even implemented yet, so what you are getting is expected behavior. In addition to that, radon 3 also uses a slightly different (not documented yet) layout for the configuration file. As a result, the radon 2 example config shouldn't even work for radon 3.