reversed c files
This commit is contained in:
parent
e2da66f178
commit
819b501105
20
level1.c
Normal file
20
level1.c
Normal file
@ -0,0 +1,20 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
|
||||
int main (void)
|
||||
{
|
||||
int cmp;
|
||||
char *str = "__stack_check";
|
||||
char buffer[100];
|
||||
|
||||
printf("Please enter key: ");
|
||||
scanf("%99s", buffer);
|
||||
|
||||
cmp = strcmp(buffer, str);
|
||||
if (cmp == 0)
|
||||
printf("Good job.\n");
|
||||
else
|
||||
printf("Nope.\n");
|
||||
return (0);
|
||||
}
|
||||
51
level2.c
Normal file
51
level2.c
Normal file
@ -0,0 +1,51 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
void no()
|
||||
{
|
||||
printf("Nope.\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
void yes()
|
||||
{
|
||||
printf("Good job.\n");
|
||||
exit(0);
|
||||
}
|
||||
|
||||
int main(void)
|
||||
{
|
||||
char input[24];
|
||||
char output[9];
|
||||
char char_ascii_in_chars[4];
|
||||
int char_ascii = 0;
|
||||
int inp_idx = 2;
|
||||
int out_idx = 1;
|
||||
int len = 0;
|
||||
|
||||
printf("please enter key: ");
|
||||
if (scanf("%23s", input) != 1)
|
||||
no();
|
||||
if (input[0] != '0' || input[1] != '0')
|
||||
no();
|
||||
fflush(stdin);
|
||||
|
||||
memset(output, 0, 9);
|
||||
output[0] = 'd';
|
||||
char_ascii_in_chars[3] = '\0';
|
||||
while (strlen(output) < 8 && inp_idx < strlen(input))
|
||||
{
|
||||
char_ascii_in_chars[0] = input[inp_idx++];
|
||||
char_ascii_in_chars[1] = input[inp_idx++];
|
||||
char_ascii_in_chars[2] = input[inp_idx++];
|
||||
char_ascii = atoi(char_ascii_in_chars);
|
||||
output[out_idx++] = (char)char_ascii;
|
||||
}
|
||||
output[out_idx] = '\0';
|
||||
|
||||
if (strcmp(output, "delabere") == 0)
|
||||
yes();
|
||||
else
|
||||
no();
|
||||
}
|
||||
51
level3.c
Normal file
51
level3.c
Normal file
@ -0,0 +1,51 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
void no()
|
||||
{
|
||||
printf("Nope.\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
void yes()
|
||||
{
|
||||
printf("Good job.\n");
|
||||
exit(0);
|
||||
}
|
||||
|
||||
int main(void)
|
||||
{
|
||||
char input[31];
|
||||
char output[9];
|
||||
char char_ascii_in_chars[4];
|
||||
int char_ascii = 0;
|
||||
int inp_idx = 2;
|
||||
int out_idx = 1;
|
||||
int len = 0;
|
||||
|
||||
printf("please enter key: ");
|
||||
if (scanf("%30s", input) != 1)
|
||||
no();
|
||||
if (input[0] != '4' || input[1] != '2')
|
||||
no();
|
||||
fflush(stdin);
|
||||
|
||||
memset(output, 0, 9);
|
||||
output[0] = '*';
|
||||
char_ascii_in_chars[3] = '\0';
|
||||
while (strlen(output) < 8 && inp_idx < strlen(input))
|
||||
{
|
||||
char_ascii_in_chars[0] = input[inp_idx++];
|
||||
char_ascii_in_chars[1] = input[inp_idx++];
|
||||
char_ascii_in_chars[2] = input[inp_idx++];
|
||||
char_ascii = atoi(char_ascii_in_chars);
|
||||
output[out_idx++] = (char)char_ascii;
|
||||
}
|
||||
output[out_idx] = '\0';
|
||||
|
||||
if (strcmp(output, "********") == 0)
|
||||
yes();
|
||||
else
|
||||
no();
|
||||
}
|
||||
3
passwords.txt
Normal file
3
passwords.txt
Normal file
@ -0,0 +1,3 @@
|
||||
level1: __stack_check
|
||||
level2: 00101108097098101114101
|
||||
level3: 42042042042042042042042
|
||||
@ -1,11 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<FILE_INFO>
|
||||
<BASIC_INFO>
|
||||
<STATE NAME="CONTENT_TYPE" TYPE="string" VALUE="Program" />
|
||||
<STATE NAME="PARENT" TYPE="string" VALUE="/" />
|
||||
<STATE NAME="FILE_ID" TYPE="string" VALUE="7f0019c7f1179232689728" />
|
||||
<STATE NAME="FILE_TYPE" TYPE="int" VALUE="0" />
|
||||
<STATE NAME="READ_ONLY" TYPE="boolean" VALUE="false" />
|
||||
<STATE NAME="NAME" TYPE="string" VALUE="level1" />
|
||||
</BASIC_INFO>
|
||||
</FILE_INFO>
|
||||
Binary file not shown.
@ -1,5 +0,0 @@
|
||||
VERSION=1
|
||||
/
|
||||
00000000:level1:7f0019c7f1179232689728
|
||||
NEXT-ID:1
|
||||
MD5:d41d8cd98f00b204e9800998ecf8427e
|
||||
@ -1,5 +0,0 @@
|
||||
VERSION=1
|
||||
/
|
||||
00000000:level1:7f0019c7f1179232689728
|
||||
NEXT-ID:1
|
||||
MD5:d41d8cd98f00b204e9800998ecf8427e
|
||||
@ -1,6 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<FILE_INFO>
|
||||
<BASIC_INFO>
|
||||
<STATE NAME="OWNER" TYPE="string" VALUE="willem" />
|
||||
</BASIC_INFO>
|
||||
</FILE_INFO>
|
||||
@ -1,15 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<PROJECT>
|
||||
<PROJECT_DATA_XML_NAME NAME="DISPLAY_DATA">
|
||||
<SAVE_STATE>
|
||||
<ARRAY NAME="EXPANDED_PATHS" TYPE="string">
|
||||
<A VALUE="reverse_me_level_1:" />
|
||||
</ARRAY>
|
||||
<STATE NAME="SHOW_TABLE" TYPE="boolean" VALUE="true" />
|
||||
</SAVE_STATE>
|
||||
</PROJECT_DATA_XML_NAME>
|
||||
<TOOL_MANAGER ACTIVE_WORKSPACE="Workspace">
|
||||
<WORKSPACE NAME="Workspace" ACTIVE="true" />
|
||||
</TOOL_MANAGER>
|
||||
</PROJECT>
|
||||
|
||||
@ -1,11 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<FILE_INFO>
|
||||
<BASIC_INFO>
|
||||
<STATE NAME="CONTENT_TYPE" TYPE="string" VALUE="ProgramUserData" />
|
||||
<STATE NAME="PARENT" TYPE="string" VALUE="/" />
|
||||
<STATE NAME="FILE_ID" TYPE="string" VALUE="7f0018cdd1420914782470" />
|
||||
<STATE NAME="FILE_TYPE" TYPE="int" VALUE="0" />
|
||||
<STATE NAME="READ_ONLY" TYPE="boolean" VALUE="false" />
|
||||
<STATE NAME="NAME" TYPE="string" VALUE="udf_7f0019c7f1179232689728" />
|
||||
</BASIC_INFO>
|
||||
</FILE_INFO>
|
||||
Binary file not shown.
@ -1,4 +0,0 @@
|
||||
VERSION=1
|
||||
/
|
||||
NEXT-ID:0
|
||||
MD5:d41d8cd98f00b204e9800998ecf8427e
|
||||
@ -1,5 +0,0 @@
|
||||
VERSION=1
|
||||
/
|
||||
00000000:udf_7f0019c7f1179232689728:7f0018cdd1420914782470
|
||||
NEXT-ID:1
|
||||
MD5:d41d8cd98f00b204e9800998ecf8427e
|
||||
@ -1,2 +0,0 @@
|
||||
IADD:00000000:/udf_7f0019c7f1179232689728
|
||||
IDSET:/udf_7f0019c7f1179232689728:7f0018cdd1420914782470
|
||||
@ -1,4 +0,0 @@
|
||||
VERSION=1
|
||||
/
|
||||
NEXT-ID:0
|
||||
MD5:d41d8cd98f00b204e9800998ecf8427e
|
||||
@ -1,4 +0,0 @@
|
||||
VERSION=1
|
||||
/
|
||||
NEXT-ID:0
|
||||
MD5:d41d8cd98f00b204e9800998ecf8427e
|
||||
Loading…
Reference in New Issue
Block a user