Remove obfuscator init calls from .ctors
This commit is contained in:
parent
9136e674e5
commit
4abe33f729
|
@ -261,18 +261,23 @@ namespace de4dot.code.deobfuscators.dotNET_Reactor3 {
|
|||
if (Operations.DecryptStrings == OpDecryptString.None)
|
||||
canRemoveDecrypterType = false;
|
||||
|
||||
addCctorInitCallToBeRemoved(nativeLibSaver.InitMethod);
|
||||
removeInitCall(nativeLibSaver.InitMethod);
|
||||
addResourceToBeRemoved(nativeLibSaver.Resource, "Native lib resource");
|
||||
addTypeToBeRemoved(nativeLibSaver.Type, "Native lib saver type");
|
||||
|
||||
foreach (var initMethod in decrypterType.InitMethods)
|
||||
addCctorInitCallToBeRemoved(initMethod);
|
||||
removeInitCall(initMethod);
|
||||
|
||||
dumpUnpackedFiles();
|
||||
|
||||
startedDeobfuscating = true;
|
||||
}
|
||||
|
||||
void removeInitCall(MethodDefinition initMethod) {
|
||||
addCctorInitCallToBeRemoved(initMethod);
|
||||
addCtorInitCallToBeRemoved(initMethod);
|
||||
}
|
||||
|
||||
void dumpUnpackedFiles() {
|
||||
foreach (var unpackedFile in unpackedFiles)
|
||||
DeobfuscatedFile.createAssemblyFile(unpackedFile.data, Win32Path.GetFileNameWithoutExtension(unpackedFile.filename), Win32Path.GetExtension(unpackedFile.filename));
|
||||
|
|
Loading…
Reference in New Issue
Block a user