Support v3.0 - 3.1
This commit is contained in:
parent
acb53f535b
commit
c970e1f6ca
|
@ -233,7 +233,7 @@ namespace de4dot.code.deobfuscators.Eazfuscator_NET {
|
|||
return false;
|
||||
}
|
||||
|
||||
static List<AssemblyInfo> createAssemblyInfos(string s) {
|
||||
List<AssemblyInfo> createAssemblyInfos(string s) {
|
||||
try {
|
||||
return tryCreateAssemblyInfos(s);
|
||||
}
|
||||
|
@ -242,18 +242,22 @@ namespace de4dot.code.deobfuscators.Eazfuscator_NET {
|
|||
}
|
||||
}
|
||||
|
||||
static List<AssemblyInfo> tryCreateAssemblyInfos(string s) {
|
||||
List<AssemblyInfo> tryCreateAssemblyInfos(string s) {
|
||||
int numElements = decrypterType.Detected ? 3 : 2;
|
||||
var ary = s.Split(',');
|
||||
if (ary.Length == 0 || ary.Length % 3 != 0)
|
||||
if (ary.Length == 0 || ary.Length % numElements != 0)
|
||||
return null;
|
||||
|
||||
var infos = new List<AssemblyInfo>();
|
||||
for (int i = 0; i < ary.Length; i += 3) {
|
||||
for (int i = 0; i < ary.Length; i += numElements) {
|
||||
var info = new AssemblyInfo();
|
||||
|
||||
info.AssemblyFullName = Encoding.UTF8.GetString(Convert.FromBase64String(ary[i]));
|
||||
info.ResourceName = ary[i + 1];
|
||||
if (numElements >= 3)
|
||||
info.Filename = Encoding.UTF8.GetString(Convert.FromBase64String(ary[i + 2]));
|
||||
else
|
||||
info.Filename = Utils.getAssemblySimpleName(info.AssemblyFullName) + ".dll";
|
||||
int index = info.ResourceName.IndexOf('|');
|
||||
if (index >= 0) {
|
||||
var flags = info.ResourceName.Substring(0, index);
|
||||
|
|
|
@ -50,7 +50,7 @@ namespace de4dot.code.deobfuscators.Eazfuscator_NET {
|
|||
|
||||
var getStream2 = getTheOnlyMethod(type, "System.IO.Stream", "(System.Reflection.Assembly,System.Type,System.String)");
|
||||
var getNames = getTheOnlyMethod(type, "System.String[]", "(System.Reflection.Assembly)");
|
||||
if (getStream2 == null || getNames == null)
|
||||
if (getStream2 == null)
|
||||
continue;
|
||||
|
||||
var resource = findGetManifestResourceStreamTypeResource(type, simpleDeobfuscator, deob);
|
||||
|
|
Loading…
Reference in New Issue
Block a user