zzzzz

  • Home
  • About
  • Tags
  • Archives

RaCTF2021 WriteUp

Posted on 2021-08-16

reverse

verybabyrev

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
int __cdecl __noreturn main(int argc, const char **argv, const char **envp)
{
__int64 s1[12]; // [rsp+0h] [rbp-100h] BYREF
char v4; // [rsp+60h] [rbp-A0h]
char s[140]; // [rsp+70h] [rbp-90h] BYREF
int v6; // [rsp+FCh] [rbp-4h]

setvbuf(stdout, 0LL, 2, 0LL);
memset(s, 0, 0x80uLL);
s1[0] = 0x45481D1217111313LL;
s1[1] = 0x95F422C260B4145LL;
s1[2] = 0x541B56563D6C5F0BLL;
s1[3] = 0x585C0B3C2945415FLL;
s1[4] = 0x402A6C54095D5F00LL;
s1[5] = 0x4B5F4248276A0606LL;
s1[6] = 0x6C5E5D432C2D4256LL;
s1[7] = 0x6B315E434707412DLL;
s1[8] = 0x5E54491C6E3B0A5ALL;
s1[9] = 0x2828475E05342B1ALL;
s1[10] = 0x60450073B26111FLL;
s1[11] = 0xA774803050B0D04LL;
v4 = 0;
printf("Enter your flag: ");
fgets(s, 128, stdin);
v6 = 0;
if ( s[0] != 'r' )
{
puts("Nope!");
exit(0);
}
while ( v6 <= 126 )
{
s[v6] ^= s[v6 + 1];
++v6;
}
if ( !memcmp(s1, s, 97uLL) )
{
puts("Correct!");
exit(1);
}
puts("Nope!");
exit(0);
}
Read more »

WinSock2 实现简单服务器

Posted on 2021-08-12

不管用啥语言写,原理都是差不多的,用Server Socket持续监听某个端口,每次accept到一个请求,就对这个Client Socket的发送的内容进行接收、分析,再发送给客户端一些信息。

Read more »

Golang 多个源文件夹的编译执行

Posted on 2021-08-12

新建项目

1
go mod init PROJECT_NAME # 比如github.com/zsy-arch/GoApp1

创建源文件及文件夹:

Read more »

Sublime text 4 GoFmter

Posted on 2021-08-12

这几天在学习Go语言,又心血来潮向回去用用Sublime Text,发现已经Sublime Text 4了 = =,安装gofmt又一直不成功,就自己写了小插件,

Read more »

WinDBG查看内核初始化过程

Posted on 2021-07-16

环境:

  1. host:Win11 预览版
  2. guest:VMwarre Pro 16 + Windows 10 18362 x64
  3. 其他工具:VirtualKD-Redux、WinDBG
    Read more »

汇编学习(2)32位模式下NASM与GCC

Posted on 2021-07-15

32位模式下NASM与GCC

C文件依然没变:

1
2
3
4
5
6
7
8
9
10
#include <stdio.h>

extern int do_something(int);

int main(int argc, char const *argv[])
{
int a = do_something(10);
printf("%d\n", a);
return 0;
}
Read more »

Assembly 汇编学习(1)

Posted on 2021-07-15

汇编学习(1)

环境:Windows 11,WSL2(Ubuntu),MINGW-GCC,NASM

Read more »

2021 07 14总结

Posted on 2021-07-14

本日复盘

T1: MRCTF2019 Re/Shit

PE —— 导入地址表(IAT)

逆向时能直接看到源代码的题目还算比较少见,程序用到了PE中的IAT,花指令,而且如果源代码里没有decode函数的话,解密算法肯定也是一道难关= =。

Read more »

Windows Debugging(1) process and thread

Posted on 2021-07-13

Windows 调试(1)进程和线程

WinDBG 命令

  1. 列出系统内所有进程的属性
Read more »

Windows Kernel(1) NTLDR

Posted on 2021-07-13

Windows 内核加载器(NTLDR)

当一台计算机启动后,会读取引导驱动器(软盘,硬盘等等)的第一个扇区0x7c00处的代码,即MBR代码。然后,MBR代码搜索系统活动分区表,并加载分区引导记录PBR代码到内存中。PBR代码负责解析FAT或NTFS文件格式,并找到NTLDR。随后,从PBR代码转到NTLDR的前半部分——startup.com的代码中来。startup.com将会检测物理地址,开启A20地址线,重定位GDT、IDT,开启保护模式,加载osloader.exe。随后osloader.exe开始启动。

Read more »
Prev123

70 posts
25 tags
RSS
GitHub E-Mail
Friends
  • 快来占坑
© 2025 zsy
Powered by Hexo
|
Theme — NexT.Gemini v5.1.4