public ObfuscatedFile CreateObfuscationFile(ObfuscatedFile.Options fileOptions, ModuleContext moduleContext) { ObfuscatedFile ofile = new ObfuscatedFile(fileOptions, moduleContext, new NewAppDomainAssemblyClientFactory()); ofile.DeobfuscatorContext = new DeobfuscatorContext(); try { ofile.Load(CreateDeobfuscatorInfos().Select(di => di.CreateDeobfuscator()).ToList()); } catch (Exception ex) { MessageBox.Show(ex.Message); return null; } return ofile; }
public static IObfuscatedFile SearchDeobfuscator(string filename) { TheAssemblyResolver.Instance.ClearAll(); var fileOptions = new ObfuscatedFile.Options { Filename = filename }; var moduleContext = new ModuleContext(TheAssemblyResolver.Instance); var ofile = new ObfuscatedFile(fileOptions, moduleContext, new NewAppDomainAssemblyClientFactory()) { DeobfuscatorContext = new DeobfuscatorContext(), }; try { ofile.Load(CreateDeobfuscatorInfos().Select(di => di.CreateDeobfuscator()).ToList()); } catch (Exception) { return null; } return ofile; }