EIS2017
EIS2017 两道逆向
* ReverseMe
核心函数是sub_403CC0
这块数据是后面check时要用到的
我们输入的字符串首先会进行一个循环左移
然后与sub_401460的返回值进行异或
sub_401460就是把我们前面的数据进行下列处理
然后最后要求,处理后的字符串与下列数据相等
* 代码如下
1 | a=[0x31,0x41,0x32,0x46,0x39,0x34,0x33,0x43,0x34,0x44,0x38,0x43,0x35,0x42,0x36,0x45,0x41,0x33,0x43,0x39,0x42,0x43,0x41,0x44,0x37,0x45,0x0] |
将得到的数字进行循环右移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// EIS-re1.cpp : 定义控制台应用程序的入口点。
//
using namespace std;
int main()
{
int b[] = { 21,
37,
77,
237,
149,
133,
204,
229,
125,
201,
220,
21,
217,
149,
192,
201,
77,
149,
125,
201,
196,
157,
161,
81,
245, };
for (int i = 0;i <= 24;i++) {
int *a = &b[i];
_asm {
push ebp
push edi
push esi
push ebx
mov eax, a
mov edx, [eax]
ror dl, 2
mov[eax], dl
pop ebx
pop esi
pop edi
pop ebp
}
char r = *a;
cout <<r;
}
return 0;
}
* flag
* IgniteMe
这个很简单。。我直接上图和代码。
sub_4013c0就是先与0x55异或再加721
2
3
4
5
6
7
8
9num=[0x0d,0x13,0x17,0x11,0x2,0x1,0x20,0x1d,0xc,0x2,0x19,0x2f,0x17,0x2b,0x24,0x1f,0x1e,0x16,0x9,0xf,0x15,0x27,0x13,0x26]
charr="GONDPHyGjPEKruv{{pj]X@rF"
flag=''
for i in range(24):
a=num[i]^ord(charr[i])
a=a-72
a=a^0x55
flag=flag+chr(a)
print (flag.lower())