REVERSE-COMPETITION-HGAME2022-Week1
- easyasm
- creakme
- Flag Checker
- 猫头鹰是不是猫
easyasm
程序一开始将si设置为0,然后si和28比较,如果si小于28则进入循环
循环体中,si作为下标,从输入中取值存入al,然后al左移4位,压入栈
保持下标si不变,再重新从输入中取一次值存入al,然后al右移4位
右移4位后的结果与之前左移4位的结果相加,然后异或0x17,最后与已知比较
整个过程相当于将输入中的每一个值的高4位和低4位交换,然后异或0x17,最后与已知比较
写逆脚本即可得到flag
arr=[0x91, 0x61, 0x01, 0xC1, 0x41, 0xA0, 0x60, 0x41, 0xD1, 0x21,0x14, 0xC1, 0x41, 0xE2, 0x50, 0xE1, 0xE2, 0x54, 0x20, 0xC1,0xE2, 0x60, 0x14, 0x30, 0xD1, 0x51, 0xC0, 0x17]
for i in range(len(arr)-1):arr[i]^=0x17arr[i]=((arr[i]<<4)&0xff)|((arr[i]>>4)&0xff)
print("".join(chr(i) for i in arr))
#hgame{welc0me_to_4sm_w0rld}
creakme
输入经过变形TEA加密与已知的密文res比较,密钥是"ABCD"那一串
常规TEA加密过程如下图
可以发现题目的变形TEA,delta不同,在32轮循环中,多异或一个v3(即sum),而且密钥有交换
对常规TEA的解密过程做相应的变换,已知密文和密钥,解出明文即为flag
#include <stdio.h>
#include <stdint.h>void decrypt(uint32_t* v, uint32_t* k) {uint32_t v0 = v[0], v1 = v[1], sum = 1183502080, i; uint32_t delta = 0x12345678; uint32_t k0 = k[0], k1 = k[1], k2 = k[2], k3 = k[3]; for (i = 0; i<32; i++) { v1 -= sum ^ ((v0 << 4) + k0) ^ (v0 + sum) ^ ((v0 >> 5) + k1);v0 -= sum ^ ((v1 << 4) + k2) ^ (v1 + sum) ^ ((v1 >> 5) + k3);sum -= delta;} v[0] = v0; v[1] = v1;
}int main()
{uint32_t v[2] = { 1222194312, 51123276 };//hgame{H4//1391163586, 3986482669->ppy_v4c4//2921328102, 3126465133->ti0n!}uint32_t k[4] = { 0x44434241,0x48474645,0x4C4B4A49,0x504F4E4D };int n = sizeof(v) / sizeof(uint32_t);decrypt(v, k);for (int i = 0; i < n; i++){for (int j = 0; j < 4; j++){printf("%c", (v[i] >> (j * 8)) & 0xFF);}}printf("\n");return 0;
}
//hgame{H4ppy_v4c4ti0n!}
Flag Checker
apk文件,jadx-gui打开
首先对输入进行RC4加密,密钥为"carol"
然后对RC4加密的结果进行base64变换,最后与已知的base64字符串比较
首先对已知的base64字符串进行逆变换,得到RC4加密的密文
import base64
c="mg6CITV6GEaFDTYnObFmENOAVjKcQmGncF90WhqvCFyhhsyqq1s="
c=base64.b64decode(c)
arr=[]
for i in c:arr.append(ord(i))
print(arr)
#[154, 14, 130, 33, 53, 122, 24, 70, 133, 13, 54, 39, 57, 177, 102, 16, 211, 128, 86, 50, 156, 66, 97, 167, 112, 95, 116, 90, 26, 175, 8, 92, 161, 134, 204, 170, 171, 91]
已知密文和密钥。解RC4得到的明文即为flag
#include<stdio.h>
void rc4_init(unsigned char* s, unsigned char* key, unsigned long Len_k)
{int i = 0, j = 0;char k[256] = { 0 };unsigned char tmp = 0;for (i = 0; i < 256; i++) {s[i] = i;k[i] = key[i % Len_k];}for (i = 0; i < 256; i++) {j = (j + s[i] + k[i]) % 256;tmp = s[i];s[i] = s[j];s[j] = tmp;}
}
void rc4_crypt(unsigned char* Data, unsigned long Len_D, unsigned char* key, unsigned long Len_k) //加解密
{unsigned char s[256];rc4_init(s, key, Len_k);int i = 0, j = 0, t = 0;unsigned long k = 0;unsigned char tmp;for (k = 0; k < Len_D; k++) {i = (i + 1) % 256;j = (j + s[i]) % 256;tmp = s[i];s[i] = s[j];s[j] = tmp;t = (s[i] + s[j]) % 256;Data[k] = Data[k] ^ s[t];}
}
void main()
{unsigned char key[] = "carol";unsigned long key_len = sizeof(key) - 1;unsigned char data[] = { 154, 14, 130, 33, 53, 122, 24, 70, 133, 13, 54, 39, 57, 177, 102, 16, 211, 128, 86, 50, 156, 66, 97, 167, 112, 95, 116, 90, 26, 175, 8, 92, 161, 134, 204, 170, 171, 91 };rc4_crypt(data, sizeof(data), key, key_len);for (int i = 0; i < sizeof(data); i++){printf("%c", data[i]);}printf("\n");return;
}
//hgame{weLC0ME_To-tHE_WORLD_oF-AnDr0|D}
猫头鹰是不是猫
对输入的处理逻辑主要在sub_1347函数中
第17行是对a2所指地址处的数据进行处理,和输入无关,可以调试得到
第23行有输入参与,整个处理过程相当于一个64元一次方程组,在每一个64元一次方程中,输入的64个值作为未知量,每个未知量的系数是从a2所指地址处取出(可调试得到)
调试取出的密文res和两次执行sub_1347函数时第23行a2所指地址处的数据(arr1和arr2)如下
res=[0x25d15d4,0x24c73b4,0x243cf71,0x230134c,0x2132cfe,0x1be2fca,0x142ca26,0xd61955,0x9427a8,0x9b8674,0x90c832,0x8812c7,0x80ba58,0x7981e1,0x72ab68,0x74cb4b,0x723f3f,0x7cc258,0x89cd5c,0x88e2a2,0x8e8906,0x8b88a0,0x8eec8d,0x8f3573,0x8b746f,0x912c82,0x8d7cf2,0x832099,0x7f45a5,0x685aff,0x50a4d2,0x526fe2,0x58923b,0x529ec1,0x516d1a,0x5b7453,0x7028e6,0x89c6fa,0xa5d6ae,0xd37a14,0xb8cfaa,0xb0bb4b,0xae69a4,0xa1154b,0x9dcbe7,0xa1dc20,0xaa07e3,0xb25cb1,0xb2fd98,0xb12f29,0xe428a0,0x11b2184,0x1615722,0x1a502f3,0x1c0aa9d,0x1d4169f,0x1ef8b76,0x233e5bb,0x275a6f0,0x2a9ca35,0x2a8904c,0x2a194ef,0x2926f39,0x28e92c3]
arr1=[0x10,0x10,0x10,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0x12,0x13,0x11,0x11,0x11,0x11,0x10,0xf,0x12,0x14,0x14,0x12,0x10,0x13,0x13,0x12,0x14,0x14,0x13,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x12,0x11,0x11,0x11,0x11,0x11,0x11,0x12,0x10,0x10,0x10,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0xf,0xf,0x10,0xf,0xe,0xd,0xb,0xb,0xd,0xd,0xf,0x11,0x12,0xc,0xc,0xe,0xc,0x10,0x11,0xe,0xe,0x12,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x12,0x10,0x10,0x10,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0x10,0x10,0xe,0xe,0xd,0x9,0xa,0xb,0xa,0xb,0x11,0x9,0xb,0xd,0xf,0xa,0x9,0x9,0xa,0xd,0xf,0xd,0x11,0x11,0x13,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x12,0x10,0x10,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0x10,0xe,0xe,0xd,0xe,0xd,0xf,0x14,0x10,0xe,0xe,0x12,0x10,0x9,0xe,0xe,0xb,0xb,0x7,0x7,0xa,0xc,0xf,0x12,0x14,0x13,0x12,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x12,0x10,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0x11,0xf,0xd,0xd,0xd,0x10,0xe,0x11,0x12,0x10,0xe,0x11,0xe,0x11,0xc,0xa,0xe,0xe,0xa,0xb,0x7,0x8,0xc,0x11,0x15,0x14,0x15,0x15,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x12,0x11,0xd,0xc,0x9,0x9,0x8,0x7,0xd,0x11,0x12,0xf,0xe,0xf,0x11,0xf,0xa,0xd,0xc,0x9,0xa,0x9,0xc,0xe,0x11,0x14,0x14,0x15,0x14,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0x13,0x13,0x11,0xc,0xb,0xa,0xb,0x7,0x7,0x7,0x9,0xe,0xf,0xb,0x9,0xe,0x11,0xd,0xa,0xd,0xc,0xc,0xf,0x11,0xf,0x10,0x11,0x12,0x12,0x12,0x12,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0x13,0x10,0x10,0xb,0x7,0xf,0xd,0xb,0x9,0x7,0x7,0x8,0x8,0x8,0x9,0xa,0xd,0x11,0xf,0xf,0xd,0x10,0x13,0x11,0xe,0xf,0xf,0x10,0xe,0x10,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x11,0x13,0x10,0xe,0x9,0x8,0x7,0x6,0xb,0xb,0xa,0x6,0x4,0x1,0x2,0x2,0x2,0x7,0xe,0x11,0x10,0xf,0x10,0x13,0x11,0x9,0x5,0x9,0xd,0xd,0x12,0x14,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0x10,0xe,0xb,0xb,0x9,0x7,0x8,0x8,0x7,0x9,0xb,0x6,0x2,0x5,0x8,0x9,0x6,0x1,0x8,0xe,0x11,0xf,0xe,0x12,0x8,0x8,0xa,0x5,0xb,0xe,0x11,0x14,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xe,0x10,0xc,0xd,0x8,0xa,0x9,0x8,0x9,0xb,0x9,0x6,0x6,0x0,0x3,0x8,0x5,0x6,0x4,0xc,0x11,0x12,0x11,0xf,0x7,0x8,0x7,0xf,0xe,0x10,0x12,0x12,0x12,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x10,0x10,0x11,0x11,0x11,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0x10,0xc,0xe,0xe,0xd,0xa,0x9,0xa,0xa,0xb,0xb,0xa,0x4,0x6,0x0,0x0,0x0,0x0,0x9,0x4,0xa,0x10,0x13,0x12,0xc,0x4,0x0,0x0,0x9,0xf,0x11,0x11,0x12,0x12,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x12,0x15,0x15,0x17,0x13,0x11,0x11,0x11,0x11,0x11,0x10,0x11,0x11,0x11,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0xe,0xf,0x10,0xb,0x9,0xa,0xa,0xa,0xa,0xa,0xc,0xc,0x6,0x7,0x0,0x0,0x0,0x2,0xa,0x4,0xc,0x10,0x10,0x12,0x11,0x7,0x0,0x0,0xa,0x10,0x12,0x12,0x15,0x14,0x12,0x10,0x10,0x10,0x10,0x10,0x10,0x15,0x14,0x11,0x10,0x12,0x13,0x15,0x11,0x10,0x10,0x10,0x10,0x11,0x10,0x11,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xe,0x10,0x11,0xf,0xd,0xb,0xb,0xb,0x8,0x9,0xc,0xe,0xe,0xc,0x6,0x7,0x2,0x4,0xb,0x6,0x5,0xd,0xf,0x11,0x12,0x12,0xe,0x6,0x7,0xd,0x12,0x11,0xe,0x10,0x14,0x10,0x10,0x10,0xf,0x10,0x10,0x12,0x14,0x10,0x10,0x10,0x10,0x10,0x15,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0xf,0xf,0xf,0xf,0xf,0xf,0xf,0xd,0xf,0xe,0xd,0xb,0xa,0xa,0xa,0xb,0x9,0xb,0xd,0xd,0xf,0xc,0x6,0xa,0xa,0x5,0x9,0xa,0xd,0xe,0xc,0x13,0x11,0xe,0xc,0xb,0xe,0x15,0x12,0x11,0x12,0x13,0x12,0x10,0xf,0xf,0x10,0x10,0x14,0x11,0x10,0x10,0x10,0x10,0x10,0x15,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0xd,0xc,0xb,0xa,0x9,0xa,0x9,0xa,0x8,0x7,0x8,0xb,0xd,0xf,0x10,0xe,0xb,0xb,0xc,0xa,0xa,0xc,0xc,0xa,0x12,0x10,0x13,0x10,0x10,0x11,0x14,0x11,0x10,0xe,0x12,0x12,0x10,0xf,0xf,0xf,0x10,0x16,0x10,0x10,0x10,0x10,0x10,0x10,0x15,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x11,0xf,0xf,0xf,0xf,0xf,0xf,0x10,0xe,0xa,0x8,0x8,0x8,0x8,0x7,0xa,0x8,0x5,0x6,0x7,0xc,0x10,0xf,0xf,0xd,0xb,0xa,0x5,0x6,0xa,0xb,0x7,0xf,0xf,0xe,0xb,0x11,0x11,0x11,0x11,0x10,0x10,0xf,0x10,0xf,0xf,0xf,0xf,0x10,0x15,0x10,0x10,0x10,0x10,0x10,0x10,0x15,0x10,0x10,0x10,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19,0x19,0x19,0x19,0x19,0x19,0x19,0x3,0x1,0x1,0x1,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x15,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x2,0x2,0x1,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x4,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x2,0x1,0x1,0x1,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x1,0x0,0x0,0x0,0x1,0x0,0xd,0x19,0x19,0x18,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19]
arr1和arr2的长度均为4096,即64*64的方阵
以arr1为例,需要注意的是
arr1的前64个元素是输入的第一个字符(比如a1)分别在64个一次方程中的系数,例如:
第1个方程:arr1[0]*a1+arr1[64]*a2+...
第2个方程:arr1[1]*a1+arr1[65]*a2+...
第3个方程:arr1[2]*a1+arr1[66]*a2+...
于是需要对arr1和arr2进行转置处理,如下:
arr=[]
for i in range(64):tmp=""for j in range(64):if j==63:tmp += str((arr1[j * 64 + i]))+";"else:tmp+=str((arr1[j*64+i]))+","print(tmp)
已知密文res,将arr1和arr2进行转置处理后,用Matlab进行求解即可得到flag
arr=[104,103,97,109,101,123,49,48,48,48,49,49,49,48,48,48,48,48,49,49,48,48,48,48,49,48,48,48,48,48,48,48,48,49,49,48,48,48,49,48,49,48,49,49,48,48,48,48,49,48,48,48,49,48,48,49,49,48,48,49,49,49,49,125]
print("".join(chr(i) for i in arr))
#hgame{100011100000110000100000000110001010110000100010011001111}