1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175
| static byte[] b(byte[] flag, int[] bInt) throws Exception { int[] constantArr1 = { 943331329, 170788368, 1008414755, 187049985, 1010368540, 220604441, 940377620, 255209728, 689771012, 221709344, 957157408, 892536332, 722417666, 1026621720, 655302664, 890966315 }; int[] constantArr2 = { 1847617210, 1994607775, 1906299266, 1443467998, 1753140052, 782026644, 743697037, 1500018807, 1015162722, 141403752, 1057274701, 1430471406, 921937966, 1419221067, 962664086, 2133607337 }; for (int i = 0; i < 16; i++) { bInt[i] ^= constantArr2[i]; } int[] mergeBInt = new int[32]; for (int i = 0; i < 16; i++) { mergeBInt[i] = constantArr1[i]; } for (int i = 0; i < 16; i++) { mergeBInt[(i + 16)] = bInt[i]; } byte[] flagcp = flag;
int[] constantArr3 = { 16843776, 0, 65536, 16843780, 16842756, 66564, 4, 65536, 1024, 16843776, 16843780, 1024, 16778244, 16842756, 16777216, 4, 1028, 16778240, 16778240, 66560, 66560, 16842752, 16842752, 16778244, 65540, 16777220, 16777220, 65540, 0, 1028, 66564, 16777216, 65536, 16843780, 4, 16842752, 16843776, 16777216, 16777216, 1024, 16842756, 65536, 66560, 16777220, 1024, 4, 16778244, 66564, 16843780, 65540, 16842752, 16778244, 16777220, 1028, 66564, 16843776, 1028, 16778240, 16778240, 0, 65540, 66560, 0, 16842756 }; int[] constantArr4 = { -2146402272, -2147450880, 32768, 1081376, 1048576, 32, -2146435040, -2147450848, -2147483616, -2146402272, -2146402304, Integer.MIN_VALUE, -2147450880, 1048576, 32, -2146435040, 1081344, 1048608, -2147450848, 0, Integer.MIN_VALUE, 32768, 1081376, -2146435072, 1048608, -2147483616, 0, 1081344, 32800, -2146402304, -2146435072, 32800, 0, 1081376, -2146435040, 1048576, -2147450848, -2146435072, -2146402304, 32768, -2146435072, -2147450880, 32, -2146402272, 1081376, 32, 32768, Integer.MIN_VALUE, 32800, -2146402304, 1048576, -2147483616, 1048608, -2147450848, -2147483616, 1048608, 1081344, 0, -2147450880, 32800, Integer.MIN_VALUE, -2146435040, -2146402272, 1081344 }; int[] constantArr5 = { 520, 134349312, 0, 134348808, 134218240, 0, 131592, 134218240, 131080, 134217736, 134217736, 131072, 134349320, 131080, 134348800, 520, 134217728, 8, 134349312, 512, 131584, 134348800, 134348808, 131592, 134218248, 131584, 131072, 134218248, 8, 134349320, 512, 134217728, 134349312, 134217728, 131080, 520, 131072, 134349312, 134218240, 0, 512, 131080, 134349320, 134218240, 134217736, 512, 0, 134348808, 134218248, 131072, 134217728, 134349320, 8, 131592, 131584, 134217736, 134348800, 134218248, 520, 134348800, 131592, 8, 134348808, 131584 }; int[] constantArr6 = { 8396801, 8321, 8321, 128, 8396928, 8388737, 8388609, 8193, 0, 8396800, 8396800, 8396929, 129, 0, 8388736, 8388609, 1, 8192, 8388608, 8396801, 128, 8388608, 8193, 8320, 8388737, 1, 8320, 8388736, 8192, 8396928, 8396929, 129, 8388736, 8388609, 8396800, 8396929, 129, 0, 0, 8396800, 8320, 8388736, 8388737, 1, 8396801, 8321, 8321, 128, 8396929, 129, 1, 8192, 8388609, 8193, 8396928, 8388737, 8193, 8320, 8388608, 8396801, 128, 8388608, 8192, 8396928 }; int[] constantArr7 = { 256, 34078976, 34078720, 1107296512, 524288, 256, 1073741824, 34078720, 1074266368, 524288, 33554688, 1074266368, 1107296512, 1107820544, 524544, 1073741824, 33554432, 1074266112, 1074266112, 0, 1073742080, 1107820800, 1107820800, 33554688, 1107820544, 1073742080, 0, 1107296256, 34078976, 33554432, 1107296256, 524544, 524288, 1107296512, 256, 33554432, 1073741824, 34078720, 1107296512, 1074266368, 33554688, 1073741824, 1107820544, 34078976, 1074266368, 256, 33554432, 1107820544, 1107820800, 524544, 1107296256, 1107820800, 34078720, 0, 1074266112, 1107296256, 524544, 33554688, 1073742080, 524288, 0, 1074266112, 34078976, 1073742080 }; int[] constantArr8 = { 536870928, 541065216, 16384, 541081616, 541065216, 16, 541081616, 4194304, 536887296, 4210704, 4194304, 536870928, 4194320, 536887296, 536870912, 16400, 0, 4194320, 536887312, 16384, 4210688, 536887312, 16, 541065232, 541065232, 0, 4210704, 541081600, 16400, 4210688, 541081600, 536870912, 536887296, 16, 541065232, 4210688, 541081616, 4194304, 16400, 536870928, 4194304, 536887296, 536870912, 16400, 536870928, 541081616, 4210688, 541065216, 4210704, 541081600, 0, 541065232, 16, 16384, 541065216, 4210704, 16384, 4194320, 536887312, 0, 541081600, 536870912, 4194320, 536887312 }; int[] constantArr9 = { 2097152, 69206018, 67110914, 0, 2048, 67110914, 2099202, 69208064, 69208066, 2097152, 0, 67108866, 2, 67108864, 69206018, 2050, 67110912, 2099202, 2097154, 67110912, 67108866, 69206016, 69208064, 2097154, 69206016, 2048, 2050, 69208066, 2099200, 2, 67108864, 2099200, 67108864, 2099200, 2097152, 67110914, 67110914, 69206018, 69206018, 2, 2097154, 67108864, 67110912, 2097152, 69208064, 2050, 2099202, 69208064, 2050, 67108866, 69208066, 69206016, 2099200, 0, 2, 69208066, 0, 2099202, 69206016, 2048, 67108866, 67110912, 2048, 2097154 }; int[] constantArr10 = { 268439616, 4096, 262144, 268701760, 268435456, 268439616, 64, 268435456, 262208, 268697600, 268701760, 266240, 268701696, 266304, 4096, 64, 268697600, 268435520, 268439552, 4160, 266240, 262208, 268697664, 268701696, 4160, 0, 0, 268697664, 268435520, 268439552, 266304, 262144, 266304, 262144, 268701696, 4096, 64, 268697664, 4096, 266304, 268439552, 64, 268435520, 268697600, 268697664, 268435456, 262144, 268439616, 0, 268701760, 262208, 268435520, 268697600, 268439552, 268439616, 0, 268701760, 266240, 266240, 4160, 4160, 262208, 268435456, 268701696 }; int flagLen = flagcp.length; int var72 = flagLen % 8; if (var72 != 0) { System.out.println("try again"); System.exit(0); } var72 = 2;
int[] var21 = new int[var72]; byte[] var22 = new byte[flagLen]; int var23 = flagLen / 8; int var24 = 0; while (var24 < var23) { int var25 = var24 * 8;
int var26 = 0; while (var26 < 2) { var21[var26] = ((flagcp[(var25 + var26 * 4)] & 0xFF) << 24 | (flagcp[(var25 + var26 * 4 + 1)] & 0xFF) << 16 | (flagcp[(var25 + var26 * 4 + 2)] & 0xFF) << 8 | flagcp[(var25 + var26 * 4 + 3)] & 0xFF); var26++; } int var31 = 0; int var29 = var21[0]; int var28 = var21[1];
int var27 = (var29 >>> 4 ^ var28) & 0xF0F0F0F; var28 ^= var27; var29 ^= var27 << 4; var27 = (var29 >>> 16 ^ var28) & 0xFFFF; var28 ^= var27; var29 ^= var27 << 16; var27 = (var28 >>> 2 ^ var29) & 0x33333333; var29 ^= var27; var28 ^= var27 << 2; var27 = (var28 >>> 8 ^ var29) & 0xFF00FF; var29 ^= var27; var28 ^= var27 << 8; var28 = var28 << 1 | var28 >>> 31 & 0x1; var27 = (var29 ^ var28) & 0xAAAAAAAA; var29 ^= var27; var28 ^= var27; var29 = var29 << 1 | var29 >>> 31 & 0x1; int var30 = 0; while (var30 < 8) { var27 = var28 << 28 | var28 >>> 4; var27 ^= mergeBInt[(var31++)]; var26 = constantArr9[(var27 & 0x3F)]; var26 |= constantArr7[(var27 >>> 8 & 0x3F)]; var26 |= constantArr5[(var27 >>> 16 & 0x3F)]; var26 |= constantArr3[(var27 >>> 24 & 0x3F)]; var27 = var28 ^ mergeBInt[(var31++)]; var26 |= constantArr10[(var27 & 0x3F)]; var26 |= constantArr8[(var27 >>> 8 & 0x3F)]; var26 |= constantArr6[(var27 >>> 16 & 0x3F)]; var26 |= constantArr4[(var27 >>> 24 & 0x3F)]; var29 ^= var26; var27 = var29 << 28 | var29 >>> 4; var27 ^= mergeBInt[(var31++)]; var26 = constantArr9[(var27 & 0x3F)]; var26 |= constantArr7[(var27 >>> 8 & 0x3F)]; var26 |= constantArr5[(var27 >>> 16 & 0x3F)]; var26 |= constantArr3[(var27 >>> 24 & 0x3F)]; var27 = var29 ^ mergeBInt[(var31++)]; var26 |= constantArr10[(var27 & 0x3F)]; var26 |= constantArr8[(var27 >>> 8 & 0x3F)]; var26 |= constantArr6[(var27 >>> 16 & 0x3F)]; var26 |= constantArr4[(var27 >>> 24 & 0x3F)]; var28 ^= var26; var30++; } var28 = var28 << 31 | var28 >>> 1; var27 = (var29 ^ var28) & 0xAAAAAAAA; var29 ^= var27; var28 ^= var27; var29 = var29 << 31 | var29 >>> 1; var27 = (var29 >>> 8 ^ var28) & 0xFF00FF; var28 ^= var27; var29 ^= var27 << 8; var27 = (var29 >>> 2 ^ var28) & 0x33333333; var28 ^= var27; var29 ^= var27 << 2; var27 = (var28 >>> 16 ^ var29) & 0xFFFF; var29 ^= var27; var28 ^= var27 << 16; var27 = (var28 >>> 4 ^ var29) & 0xF0F0F0F; var29 ^= var27; var28 ^= var27 << 4; var21[0] = var28; var21[1] = var29;
int var32 = var24 * 8; int var33 = 0; while (var33 < 2) { var22[(var32 + var33 * 4)] = ((byte) (var21[var33] >>> 24)); var22[(var32 + var33 * 4 + 1)] = ((byte) (var21[var33] >>> 16)); var22[(var32 + var33 * 4 + 2)] = ((byte) (var21[var33] >>> 8)); var22[(var32 + var33 * 4 + 3)] = ((byte) var21[var33]); var33++; } var24++; } byte var66 = var22[(var22.length - 1)];
return var22; }
|