forked from USTC-Hackergame/hackergame2020-writeups
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Untitled01.c
executable file
·79 lines (74 loc) · 1.52 KB
/
Untitled01.c
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
#include <stdio.h>
#include <windows.h>
void usleep(__int64 usec)
{
HANDLE timer;
LARGE_INTEGER ft;
ft.QuadPart = -(10*usec); // Convert to 100 nanosecond interval, negative value indicates relative time
timer = CreateWaitableTimer(NULL, TRUE, NULL);
SetWaitableTimer(timer, &ft, 0, NULL, NULL, 0);
WaitForSingleObject(timer, INFINITE);
CloseHandle(timer);
}
int main()
{
char flag[100];
int n = 20;
flag[n++] = 'f';
flag[n++] = 'l';
flag[n++] = 'a';
flag[n++] = 'g';
flag[n++] = '{';
flag[n++] = 'A';
flag[n++] = 'r';
flag[n++] = 'e';
flag[n++] = '_';
flag[n++] = 'y';
flag[n++] = 'o';
flag[n++] = 'u';
flag[n++] = '_';
flag[n++] = 'e';
flag[n++] = 'y';
flag[n++] = 'e';
flag[n++] = 's';
flag[n++] = '1';
flag[n++] = 'g';
flag[n++] = 'h';
flag[n++] = 't';
flag[n++] = '_';
flag[n++] = 'g';
flag[n++] = '0';
flag[n++] = '0';
flag[n++] = 'D';
flag[n++] = '?';
flag[n++] = '_';
flag[n++] = 'c';
flag[n++] = 'a';
flag[n++] = 'n';
flag[n++] = '_';
flag[n++] = 'y';
flag[n++] = 'o';
flag[n++] = 'u';
flag[n++] = '_';
flag[n++] = 'd';
flag[n++] = 'I';
flag[n++] = 's';
flag[n++] = 't';
flag[n++] = '1';
flag[n++] = 'n';
flag[n++] = 'g';
flag[n++] = 'u';
flag[n++] = 'i';
flag[n++] = 's';
flag[n++] = 'h';
flag[n++] = '_';
flag[n++] = '1';
flag[n++] = 'i';
flag[n++] = 'I';
flag[n++] = '?';
flag[n++] = '}';
flag[n++] = '\0';
printf("%s\n", flag + 20);
usleep(500000);
return 0;
}