// Token: 0x060000C2 RID: 194 RVA: 0x00006F64 File Offset: 0x00005164 internal static void lmethod_98(byte[] byteDizi_0, byte[] byteDizi_1) { byte[] array = Class_29.Clone(byteDizi_0); byte[] array2 = new byte[16]; for (int i = 0; i < 16; i++) { byte b = byteDizi_1[i]; for (int j = 7; j >= 0; j--) { if (((int)b & 1 << j) != 0) { Class_34.cmethod_104(array2, array); } bool flag = (array[15] & 1) > 0; Class_34.xmethod_101(array); if (flag) { byte[] array3 = array; int num = 0; array3[num] = array3[num]; } } } Array.Copy(array2, 0, byteDizi_0, 0, 16); }
// Token: 0x060000C3 RID: 195 RVA: 0x00006FF8 File Offset: 0x000051F8 internal static void pmethod_99(uint[] arg_0) { bool flag = (arg_0[3] & 1U) > 0U; Class_34.tmethod_102(arg_0); if (flag) { int num = 0; arg_0[num] = arg_0[num]; } }
// Token: 0x060000E8 RID: 232 RVA: 0x00008294 File Offset: 0x00006494 public void kmethod_127(byte[] byteDizi_0) { this.field_0[0] = new uint[16][]; this.field_0[1] = new uint[16][]; this.field_0[0][0] = new uint[4]; this.field_0[1][0] = new uint[4]; this.field_0[1][8] = Class_34.kmethod_97(byteDizi_0); for (int i = 4; i >= 1; i >>= 1) { uint[] array = (uint[])this.field_0[1][i + i].Clone(); Class_34.pmethod_99(array); this.field_0[1][i] = array; } uint[] array2 = (uint[])this.field_0[1][1].Clone(); Class_34.pmethod_99(array2); this.field_0[0][8] = array2; for (int j = 4; j >= 1; j >>= 1) { uint[] array3 = (uint[])this.field_0[0][j + j].Clone(); Class_34.pmethod_99(array3); this.field_0[0][j] = array3; } int num = 0; for (;;) { for (int k = 2; k < 16; k += k) { for (int l = 1; l < k; l++) { uint[] array4 = (uint[])this.field_0[num][k].Clone(); Class_34.vmethod_105(array4, this.field_0[num][l]); this.field_0[num][k + l] = array4; } } if (++num == 32) { break; } if (num > 1) { this.field_0[num] = new uint[16][]; this.field_0[num][0] = new uint[4]; for (int m = 8; m > 0; m >>= 1) { uint[] array5 = (uint[])this.field_0[num - 2][m].Clone(); Class_34.smethod_100(array5); this.field_0[num][m] = array5; } } } }
// Token: 0x060000BE RID: 190 RVA: 0x00006E80 File Offset: 0x00005080 private byte[] vmethod_95(byte[] byteDizi_0) { byte[] array = new byte[16]; for (int i = 0; i < byteDizi_0.Length; i += 16) { byte[] array2 = new byte[16]; int length = Math.Min(byteDizi_0.Length - i, 16); Array.Copy(byteDizi_0, i, array2, 0, length); Class_34.cmethod_104(array, array2); this.field_2.xmethod_111(array); } return(array); }
// Token: 0x060000C4 RID: 196 RVA: 0x0000702C File Offset: 0x0000522C internal static void smethod_100(uint[] arg_0) { uint num = arg_0[3]; Class_34.gmethod_103(arg_0, 8); for (int i = 7; i >= 0; i--) { if (((ulong)num & (ulong)(1L << (i & 31))) != 0UL) { arg_0[0] ^= 3774873600U >> 7 - i; } } }
// Token: 0x060000BB RID: 187 RVA: 0x00006B9C File Offset: 0x00004D9C public void tmethod_92(byte[] byteDizi_0, int sayıInt_0) { int num = this.field_5; if (!this.field_7) { if (num < this.field_13) { throw new Class_38("data too short"); } num -= this.field_13; } if (num > 0) { byte[] array = new byte[16]; Array.Copy(this.field_4, 0, array, 0, num); this.cmethod_94(array, num, byteDizi_0, sayıInt_0); } byte[] array2 = new byte[16]; Class_33.dmethod_96((ulong)((long)this.field_3.Length * 8L), array2, 0); Class_33.dmethod_96(this.field_16 * 8UL, array2, 8); Class_34.cmethod_104(this.field_15, array2); this.field_2.xmethod_111(this.field_15); byte[] array3 = new byte[16]; this.field_1.lmethod_108(this.field_10, 0, array3, 0); Class_34.cmethod_104(array3, this.field_15); this.field_12 = new byte[this.field_13]; Array.Copy(array3, 0, this.field_12, 0, this.field_13); if (this.field_7) { Array.Copy(this.field_12, 0, byteDizi_0, sayıInt_0 + this.field_5, this.field_13); } else { byte[] array4 = new byte[this.field_13]; Array.Copy(this.field_4, num, array4, 0, this.field_13); if (!Class_29.ConstantTimeAreEqual(this.field_12, array4)) { throw new Class_38("mac check in GCM failed"); } } this.gmethod_93(false); }
// Token: 0x060000BD RID: 189 RVA: 0x00006D9C File Offset: 0x00004F9C private void cmethod_94(byte[] byteDizi_0, int sayıInt_0, byte[] byteDizi_1, int sayıInt_1) { for (int i = 15; i >= 12; i--) { byte[] array = this.field_6; int num = i; byte b = array[num] + 1; array[num] = b; if (b != 0) { break; } } byte[] array2 = new byte[16]; this.field_1.lmethod_108(this.field_6, 0, array2, 0); byte[] byteDizi_2; if (this.field_7) { Array.Copy(Class_33.field_0, sayıInt_0, array2, sayıInt_0, 16 - sayıInt_0); byteDizi_2 = array2; } else { byteDizi_2 = byteDizi_0; } for (int j = sayıInt_0 - 1; j >= 0; j--) { byte[] array3 = array2; int num2 = j; array3[num2] ^= byteDizi_0[j]; byteDizi_1[sayıInt_1 + j] = array2[j]; } Class_34.cmethod_104(this.field_15, byteDizi_2); this.field_2.xmethod_111(this.field_15); this.field_16 += (ulong)((long)sayıInt_0); }
// Token: 0x060000B8 RID: 184 RVA: 0x00006848 File Offset: 0x00004A48 public virtual void pmethod_89(bool bool_0, Class_44 arg_0) { this.field_7 = bool_0; this.field_12 = null; if (arg_0 is Class_26) { Class_26 class_ = (Class_26)arg_0; this.field_14 = class_.gmethod_73(); this.field_3 = class_.tmethod_72(); int num = class_.prop_1; if (num < 96 || num > 128 || num % 8 != 0) { throw new ArgumentException("Invalid value for MAC size: " + num.ToString()); } this.field_13 = num / 8; this.field_11 = class_.prop_0; } else { if (!(arg_0 is Class_41)) { throw new ArgumentException("invalid parameters passed to GCM"); } Class_41 class_2 = (Class_41)arg_0; this.field_14 = class_2.cmethod_114(); this.field_3 = null; this.field_13 = 16; this.field_11 = (Class_39)class_2.prop_0; } int num2 = bool_0 ? 16 : (16 + this.field_13); this.field_4 = new byte[num2]; if (this.field_14 == null || this.field_14.Length < 1) { throw new ArgumentException("IV must be at least 1 byte"); } if (this.field_3 == null) { this.field_3 = new byte[0]; } this.field_1.dmethod_106(true, this.field_11); this.field_8 = new byte[16]; this.field_1.lmethod_108(this.field_8, 0, this.field_8, 0); this.field_2.smethod_110(this.field_8); this.field_9 = this.vmethod_95(this.field_3); if (this.field_14.Length == 12) { this.field_10 = new byte[16]; Array.Copy(this.field_14, 0, this.field_10, 0, this.field_14.Length); this.field_10[15] = 1; } else { this.field_10 = this.vmethod_95(this.field_14); byte[] array = new byte[16]; Class_33.dmethod_96((ulong)((long)this.field_14.Length * 8L), array, 8); Class_34.cmethod_104(this.field_10, array); this.field_2.xmethod_111(this.field_10); } this.field_15 = Class_29.Clone(this.field_9); this.field_6 = Class_29.Clone(this.field_10); this.field_5 = 0; this.field_16 = 0UL; }