Package de.geolykt.starloader.deobf
Class IntermediaryGenerator
java.lang.Object
de.geolykt.starloader.deobf.IntermediaryGenerator
-
Constructor Summary
ConstructorsConstructorDescriptionIntermediaryGenerator(@Nullable Path map, Path output, @Nullable Collection<org.objectweb.asm.tree.ClassNode> nodes) IntermediaryGenerator(File input, Path map, Path output) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddResources(@NotNull File input) Adds resources from a jar file at a given location.computeFullHierarchy(Map<String, List<String>> nearbyHierarchy) voidvoidProposes new field names within enum class that can be easily guessed by the computer.List<org.objectweb.asm.tree.ClassNode>voidvoidremapClassesV2(boolean findLocalClasses) voidvoiduseAlternateClassNaming(boolean toggle) Sets whether alternate class naming should be employed.
-
Constructor Details
-
IntermediaryGenerator
public IntermediaryGenerator(@Nullable @Nullable Path map, Path output, @Nullable @Nullable Collection<org.objectweb.asm.tree.ClassNode> nodes) -
IntermediaryGenerator
-
-
Method Details
-
addResources
Adds resources from a jar file at a given location. This is used for thedeobfuscate()operation if and only if an output folder was chosen.- Parameters:
input- The file to scan for resources- Throws:
IOException- if an IO issue occurred
-
computeFullHierarchy
-
deobfuscate
public void deobfuscate() -
doProposeEnumFieldsV2
public void doProposeEnumFieldsV2()Proposes new field names within enum class that can be easily guessed by the computer. -
getAsClassNodes
-
remapClassesV2
public void remapClassesV2() -
remapClassesV2
public void remapClassesV2(boolean findLocalClasses) -
remapGetters
public void remapGetters() -
useAlternateClassNaming
public void useAlternateClassNaming(boolean toggle) Sets whether alternate class naming should be employed. This is very useful if obftools has to be updated or when the application to link to has changed. Making use of this feature eliminates large portions of issues where the classes have changed their name, but using the old name is still fully valid. This can cause subtle bugs that are very hard to trace. If the alternate naming scheme is on, classes are enumerated with the characters [0-9], where as they are enumerated with the characters [a-z] when the alternate naming scheme is off.- Parameters:
toggle- Whether to use the alternate class naming scheme.
-