joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14000bd50
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
mov r8d, 4
movzx edx, cl
lea rax, [0x140034de0]
shr ecx, 8
xor ecx, dword [rax + rdx*4]
sub r8, 1
jne 0x14000bd56
mov eax, ecx
ret

Function at 0x14000fb9c
Capabilities:
Read file on windows

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r14
sub rsp, 0x20
and dword [r9], 0
mov rdi, r9
xor r10d, r10d
mov esi, r8d
mov rbp, rdx
mov rbx, rcx
mov r14d, 0x40000000
mov ecx, dword [rbx + 0x1c]
mov r8d, esi
sub r8d, r10d
mov edx, r10d
cmp r8d, r14d
cmova r8d, r14d
add rdx, rbp
call fcn.1400214f8
test eax, eax
jle 0x14000fbfd
mov r10d, dword [rdi]
add r10d, eax
mov dword [rdi], r10d
cmp r10d, esi
jb 0x14000fbce
test eax, eax
jns 0x14000fc1f
call fcn.14001f6a0
mov ecx, dword [rax]
call fcn.14001f72c
or edi, 0xffffffff
mov r8, rax
mov edx, edi
mov rcx, rbx
call fcn.14000f134
mov eax, edi
jmp 0x14000fc2c
test eax, eax
jne 0x14000fc2a
mov dword [rbx + 0x50], 1
xor eax, eax
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x48]
add rsp, 0x20
pop r14
ret
Function at 0x14001b408
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov eax, 0x1050
call fcn.140014cc0
sub rsp, rax
mov rax, qword [0x140045068]
xor rax, rsp
mov qword [rsp + 0x1040], rax
mov r15, r8
mov rbp, rdx
mov rbx, rcx
call fcn.140025444
xor edi, edi
movsxd r14, eax
cmp dword [rbx + 0x10], edi
jne 0x14001b457
mov rax, rbp
jmp 0x14001b55f
mov rax, qword [rbx]
mov rcx, r14
sub rax, qword [rbx + 8]
and ecx, 0x3f
cqo
mov rbx, r14
sub rax, rdx
sar rbx, 6
sar rax, 1
mov r9, r15
lea r12, [rcx + rcx*8]
mov rsi, rax
lea rax, [0x140000000]
xor r8d, r8d
mov rdx, qword [rax + rbx*8 + 0x486d0]
mov ecx, r14d
mov rdx, qword [rdx + r12*8 + 0x30]
call fcn.14001f520
mov r13, rax
lea rax, [0x140000000]
mov rcx, qword [rax + rbx*8 + 0x486d0]
cmp r13, qword [rcx + r12*8 + 0x30]
jne 0x14001b55b
mov rcx, qword [rcx + r12*8 + 0x28]
lea r9, [rsp + 0x30]
mov r8d, 0x1000
mov qword [rsp + 0x20], rdi
lea rdx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14001b55b
mov r9, r15
xor r8d, r8d
mov rdx, rbp
mov ecx, r14d
call fcn.14001f520
test rax, rax
js 0x14001b55b
mov eax, dword [rsp + 0x30]
cmp rsi, rax
jg 0x14001b55b
lea rdx, [rsp + 0x40]
add rdx, rax
lea rcx, [rsp + 0x40]
test rsi, rsi
je 0x14001b54d
lea r8, [0x140000000]
cmp rcx, rdx
jae 0x14001b54d
cmp byte [rcx], 0xd
jne 0x14001b533
lea rax, [rdx - 1]
cmp rcx, rax
jae 0x14001b542
cmp byte [rcx + 1], 0xa
jne 0x14001b542
inc rcx
jmp 0x14001b542
movzx eax, byte [rcx]
movsx rax, byte [rax + r8 + 0x45090]
add rcx, rax
inc rdi
inc rcx
cmp rdi, rsi
jne 0x14001b515
lea rax, [rsp + 0x40]
sub rcx, rax
lea rax, [rcx + r13]
jmp 0x14001b55f
or rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x1040]
xor rcx, rsp
call fcn.14002faf0
mov rbx, qword [rsp + 0x1090]
add rsp, 0x1050
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
Function at 0x14001c234
Capabilities:
Get disk information

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x240
mov rax, qword [0x140045068]
xor rax, rsp
mov qword [rsp + 0x230], rax
lea rdx, [0x140038d20]
mov rbp, rcx
call fcn.140026c44
xor edi, edi
test rax, rax
je 0x14001c31a
mov ebx, edi
call fcn.14001f6a0
mov r14d, dword [rax]
call fcn.14001f6a0
mov r8d, 0x104
lea rcx, [rsp + 0x20]
mov rdx, rbp
mov dword [rax], edi
call fcn.140026b90
mov rsi, rax
test rax, rax
je 0x14001c2ab
call fcn.14001f6a0
mov dword [rax], r14d
jmp 0x14001c2d5
call fcn.14001f6a0
cmp dword [rax], 0x22
jne 0x14001c312
call fcn.14001f6a0
xor r8d, r8d
mov rdx, rbp
xor ecx, ecx
mov dword [rax], r14d
call fcn.140026b90
mov rbx, rax
mov rsi, rax
test rax, rax
je 0x14001c312
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], di
jne 0x14001c2d9
cmp rax, 3
je 0x14001c2f4
mov rcx, rsi
call fcn.14001c190
test al, al
je 0x14001c305
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 1
jbe 0x14001c305
mov dil, 1
mov rcx, rbx
call fcn.140019698
mov al, dil
jmp 0x14001c31c
mov rcx, rbx
call fcn.140019698
xor al, al
mov rcx, qword [rsp + 0x230]
xor rcx, rsp
call fcn.14002faf0
lea r11, [rsp + 0x240]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret

Function at 0x1400204b0
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x1400202a0
Function at 0x14002104c
Capabilities:
Read file on windows

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x30
movsxd rbp, ecx
mov r9, r8
mov rax, rbp
lea rcx, [0x1400486d0]
and eax, 0x3f
mov r10, rbp
sar r10, 6
xor edi, edi
mov rsi, rdx
mov r14, rbp
lea r8, [rax + rax*8]
mov rax, qword [rcx + r10*8]
mov ecx, 4
mov qword [rsp + 0x78], rcx
mov r11, qword [rax + r8*8 + 0x28]
lea r12d, [rcx + 6]
test r9, r9
je 0x1400210aa
cmp word [rdx], r12w
jne 0x1400210aa
or byte [rax + r8*8 + 0x38], cl
jmp 0x1400210b0
and byte [rax + r8*8 + 0x38], 0xfb
lea rdx, [rdx + r9*2]
mov rcx, rsi
mov rbx, rsi
cmp rsi, rdx
jae 0x14002120b
mov r9d, 0x1a
lea r13d, [r9 - 0xd]
movzx eax, word [rcx]
cmp ax, r9w
je 0x1400211e6
lea r9, [rcx + 2]
cmp ax, r13w
je 0x1400210e9
mov rcx, r9
jmp 0x14002110c
cmp r9, rdx
jae 0x140021123
cmp word [r9], r12w
mov eax, 2
cmove rax, qword [rsp + 0x78]
add rcx, rax
mov eax, r12d
cmp word [r9], r12w
cmovne ax, r13w
mov word [rbx], ax
mov r9d, 0x1a
add rbx, 2
cmp rcx, rdx
jb 0x1400210cd
jmp 0x14002120b
lea r9, [rsp + 0x80]
mov qword [rsp + 0x20], rdi
mov r8d, 2
lea rdx, [rsp + 0x70]
mov rcx, r11
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1400211e0
cmp dword [rsp + 0x80], edi
je 0x1400211e0
mov rdx, r14
lea r11, [0x1400486d0]
sar rdx, 6
and r14d, 0x3f
mov rax, qword [r11 + rdx*8]
lea r8, [r14 + r14*8]
test byte [rax + r8*8 + 0x38], 0x48
je 0x1400211b9
movzx eax, word [rsp + 0x70]
cmp ax, r12w
jne 0x14002118c
mov word [rbx], r12w
jmp 0x140021207
mov word [rbx], r13w
mov word [rsp + 0x78], ax
mov rax, qword [r11 + rdx*8]
lea rcx, [rax + r8*8]
mov al, byte [rsp + rdi + 0x78]
mov byte [rcx + rdi + 0x3a], al
inc rdi
cmp rdi, 2
jl 0x140021195
mov rax, qword [r11 + rdx*8]
mov byte [rax + r8*8 + 0x3c], r12b
jmp 0x140021207
cmp word [rsp + 0x70], r12w
jne 0x1400211c6
cmp rbx, rsi
je 0x140021186
mov rdx, 0xfffffffffffffffe
mov ecx, ebp
lea r8d, [rdx + 3]
call fcn.14001f528
cmp word [rsp + 0x70], r12w
je 0x14002120b
mov word [rbx], r13w
jmp 0x140021207
lea r11, [0x1400486d0]
mov rcx, qword [r11 + r10*8]
mov al, byte [rcx + r8*8 + 0x38]
test al, 0x40
jne 0x140021203
or al, 2
mov byte [rcx + r8*8 + 0x38], al
jmp 0x14002120b
mov word [rbx], r9w
add rbx, 2
sub rbx, rsi
sar rbx, 1
lea eax, [rbx + rbx]
add rsp, 0x30
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x140025614
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push r14
sub rsp, 0x20
mov rsi, rcx
test rcx, rcx
jne 0x140025646
call fcn.14001f6a0
mov dword [rax], 0x16
call fcn.140023c9c
jmp 0x140025765
mov eax, dword [rcx + 0x14]
shr eax, 0xd
test al, 1
je 0x140025765
mov eax, dword [rcx + 0x14]
shr eax, 0xc
test al, 1
jne 0x140025765
mov eax, dword [rcx + 0x14]
shr eax, 1
test al, 1
je 0x140025675
lock or dword [rcx + 0x14], 0x10
jmp 0x140025765
lock or dword [rcx + 0x14], 1
mov eax, dword [rcx + 0x14]
test eax, 0x4c0
jne 0x140025689
call fcn.14002b708
mov rdi, qword [rsi + 8]
mov rcx, rsi
mov ebx, dword [rsi + 0x20]
mov qword [rsi], rdi
call fcn.140025444
mov r8d, ebx
mov rdx, rdi
mov ecx, eax
call fcn.1400214f8
mov dword [rsi + 0x10], eax
lea ecx, [rax + 1]
cmp ecx, 1
jbe 0x140025753
mov eax, dword [rsi + 0x14]
or edi, 0xffffffff
test al, 6
jne 0x14002571e
mov rcx, rsi
call fcn.140025444
cmp eax, edi
je 0x140025709
mov rcx, rsi
call fcn.140025444
cmp eax, 0xfffffffe
je 0x140025709
mov rcx, rsi
call fcn.140025444
movsxd rbx, eax
lea r14, [0x1400486d0]
mov rcx, rsi
sar rbx, 6
call fcn.140025444
and eax, 0x3f
lea rcx, [rax + rax*8]
mov rax, qword [r14 + rbx*8]
lea rdx, [rax + rcx*8]
jmp 0x140025710
lea rdx, [0x1400455f0]
mov al, byte [rdx + 0x38]
and al, 0x82
cmp al, 0x82
jne 0x14002571e
lock or dword [rsi + 0x14], 0x20
cmp dword [rsi + 0x20], 0x200
jne 0x140025742
mov eax, dword [rsi + 0x14]
shr eax, 6
test al, 1
je 0x140025742
mov eax, dword [rsi + 0x14]
shr eax, 8
test al, 1
jne 0x140025742
mov dword [rsi + 0x20], 0x1000
mov rax, qword [rsi]
add dword [rsi + 0x10], edi
movzx edi, byte [rax]
inc rax
mov qword [rsi], rax
jmp 0x140025768
neg eax
sbb eax, eax
and eax, 8
add eax, 8
lock or dword [rsi + 0x14], eax
and dword [rsi + 0x10], 0
or edi, 0xffffffff
mov rbx, qword [rsp + 0x30]
mov eax, edi
mov rdi, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop r14
ret
Function at 0x1400289d0
Capabilities:
Clear file content

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x20
mov rbx, rdx
mov rsi, r8
xor edx, edx
mov r14d, ecx
lea r8d, [rdx + 1]
call fcn.14001f528
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.14001f528
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x140028b20
cmp rax, 0xffffffffffffffff
je 0x140028b20
xor edi, edi
test rbp, rbp
jle 0x140028acb
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.140025e9c
mov rbx, rax
test rax, rax
jne 0x140028a58
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x140028ac1
mov edx, 0x8000
mov ecx, r14d
call fcn.14002052c
mov r15d, eax
mov eax, 0x1000
mov r8d, ebp
cmp rbp, rax
mov r9, rsi
mov rdx, rbx
mov ecx, r14d
cmovge r8d, eax
call fcn.14002243c
cmp eax, 0xffffffff
je 0x140028aa1
cdqe
sub rbp, rax
test rbp, rbp
jg 0x140028a68
mov edx, r15d
mov ecx, r14d
call fcn.14002052c
jmp 0x140028ac1
cmp byte [rsi + 0x38], dil
je 0x140028ab8
cmp dword [rsi + 0x34], 5
jne 0x140028ab8
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], InitCommonControls
cmp byte [rsi + 0x30], dil
je 0x140028ac1
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.140023d6c
jmp 0x140028b34
jns 0x140028b34
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.14001f528
cmp rax, 0xffffffffffffffff
jne 0x140028aec
cmp byte [rsi + 0x30], dil
je 0x140028b34
mov edi, dword [rsi + 0x2c]
jmp 0x140028b34
mov ecx, r14d
call fcn.140027330
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x140028b34
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [rsi + 0x38], 1
mov edi, InitCommonControls
mov dword [rsi + 0x34], eax
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], InitCommonControls
jmp 0x140028b34
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x140028b2d
mov eax, dword [rsi + 0x2c]
jmp 0x140028b32
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.14001f528
mov rbx, qword [rsp + 0x40]
mov eax, edi
mov rdi, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop r12
ret
Function at 0x140029d58
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor ebp, ebp
mov rbx, rax
test rax, rax
je 0x140029ddf
mov rsi, rbx
cmp word [rax], bp
je 0x140029d9e
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x140029d88
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x140029d84
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.140023da8
mov rdi, rax
test rax, rax
je 0x140029dcc
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.140015f10
mov rbp, rdi
xor ecx, ecx
call fcn.140023d6c
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rbp
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x6d7d0bf0
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x6d7f15e4]
test esi, esi
mov rbx, rcx
mov rbp, rdx
mov rdi, r8
jle 0x6d7d0d78
mov rax, qword [0x6d7f15e8]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp rbx, rdx
jb 0x6d7d0c3c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp rbx, rdx
jb 0x6d7d0cc5
add ecx, 1
add rax, 0x28
cmp ecx, esi
jne 0x6d7d0c20
mov rcx, rbx
call sym.__mingw_GetSectionForAddress
test rax, rax
mov r12, rax
je 0x6d7d0dad
mov rax, qword [0x6d7f15e8]
lea rsi, [rsi + rsi*4]
shl rsi, 3
add rax, rsi
mov qword [rax + 0x20], r12
mov dword [rax], 0
call sym._GetPEImageBase
mov ecx, dword [r12 + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x6d7f15e8]
mov qword [rax + rsi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x6d7d0d90
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x6d7d0cbe
sub eax, 0x40
and eax, 0xffffffbf
jne 0x6d7d0d20
add dword [0x6d7f15e4], 1
cmp edi, 8
jae 0x6d7d0cf3
test dil, 4
jne 0x6d7d0d64
test edi, edi
je 0x6d7d0ce8
movzx eax, byte [rbp]
test dil, 2
mov byte [rbx], al
jne 0x6d7d0d7f
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov eax, edi
sub edi, 1
mov rdx, qword [rbp + rax - 8]
cmp edi, 8
mov qword [rbx + rax - 8], rdx
jb 0x6d7d0ce8
and edi, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov rcx, qword [rbp + rdx]
cmp eax, edi
mov qword [rbx + rdx], rcx
jb 0x6d7d0d0c
jmp 0x6d7d0ce8
add rsi, qword [0x6d7f15e8]
mov r8d, 0x40
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r9, rsi
mov qword [rsi + 8], rcx
mov qword [rsi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x6d7d0cbe
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call sym.__report_error
mov eax, dword [rbp]
mov edi, edi
mov dword [rbx], eax
mov eax, dword [rbp + rdi - 4]
mov dword [rbx + rdi - 4], eax
jmp 0x6d7d0ce8
xor esi, esi
jmp 0x6d7d0c47
mov edi, edi
movzx eax, word [rbp + rdi - 2]
mov word [rbx + rdi - 2], ax
jmp 0x6d7d0ce8
mov rax, qword [0x6d7f15e8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [r12 + 8]
mov r8, qword [rax + rsi + 0x18]
call sym.__report_error
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call sym.__report_error
nop
nop dword [rax]

Function at 0x6d7d1500
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x6d7f18c0]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x6d7f18a0]
test rbx, rbx
je 0x6d7d1554
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x6d7d154b
test rsi, rsi
je 0x6d7d154b
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x6d7d1530
lea rcx, [0x6d7f18c0]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x6d7d1790
Capabilities:
Parse pe header

Disassembly:
cmp word [rcx], 0x5a4d
je 0x6d7d17a0
xor eax, eax
ret
jmp sym._ValidateImageBase.part.0

Function at 0x6d7d17b0
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
lea rax, [rcx + rax + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x6d7d17f1
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
mov r8d, dword [rax + 0xc]
cmp r8, rdx
mov rcx, r8
ja 0x6d7d17e8
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x6d7d17f3
add rax, 0x28
cmp rax, r9
jne 0x6d7d17d4
xor eax, eax
ret

Function at 0x6d7d1890
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r8, qword [0x6d7ee1f0]
cmp word [r8], 0x5a4d
mov rdx, rcx
jne 0x6d7d18fd
mov rcx, r8
call sym._ValidateImageBase.part.0
test eax, eax
je 0x6d7d18fd
movsxd rax, dword [r8 + 0x3c]
mov rcx, rdx
sub rcx, r8
add r8, rax
movzx edx, word [r8 + 6]
movzx eax, word [r8 + 0x14]
test edx, edx
lea rax, [r8 + rax + 0x18]
je 0x6d7d18fd
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x6d7d18f4
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x6d7d18ff
add rax, 0x28
cmp rax, r9
jne 0x6d7d18e0
xor eax, eax
add rsp, 0x28
ret

Function at 0x6d7d1a00
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r8, qword [0x6d7ee1f0]
xor eax, eax
cmp word [r8], 0x5a4d
mov rdx, rcx
je 0x6d7d1a20
add rsp, 0x28
ret
mov rcx, r8
call sym._ValidateImageBase.part.0
test eax, eax
je 0x6d7d1a18
movsxd rax, dword [r8 + 0x3c]
mov rcx, rdx
sub rcx, r8
add r8, rax
movzx edx, word [r8 + 6]
movzx eax, word [r8 + 0x14]
test edx, edx
lea rax, [r8 + rax + 0x18]
je 0x6d7d1a7d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop dword [rax + rax]
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x6d7d1a74
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x6d7d1a84
add rax, 0x28
cmp rax, r9
jne 0x6d7d1a60
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret

Function at 0x6d7d1aa0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x6d7ee1f0]
cmp word [r11], 0x5a4d
mov r9d, ecx
jne 0x6d7d1b0e
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x6d7d1b0e
movsxd rax, dword [r11 + 0x3c]
add rax, r11
mov edx, dword [rax + 0x90]
test edx, edx
je 0x6d7d1b0e
movzx ecx, word [rax + 0x14]
lea rcx, [rax + rcx + 0x18]
movzx eax, word [rax + 6]
test eax, eax
je 0x6d7d1b0e
sub eax, 1
lea rax, [rax + rax*4]
lea rax, [rcx + rax*8 + 0x28]
mov r10d, dword [rcx + 0xc]
cmp rdx, r10
mov r8, r10
jb 0x6d7d1b05
add r8d, dword [rcx + 8]
cmp rdx, r8
jb 0x6d7d1b15
add rcx, 0x28
cmp rcx, rax
jne 0x6d7d1af0
xor eax, eax
add rsp, 0x28
ret
add rdx, r11
jne 0x6d7d1b28
jmp 0x6d7d1b0e
sub r9d, 1
add rdx, 0x14
mov ecx, dword [rdx + 4]
test ecx, ecx
jne 0x6d7d1b36
mov eax, dword [rdx + 0xc]
test eax, eax
je 0x6d7d1b0e
test r9d, r9d
jg 0x6d7d1b20
mov eax, dword [rdx + 0xc]
add rax, r11
add rsp, 0x28
ret
Function at 0x6d7d1e70
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
lea rax, [rsp + 0x58]
mov rbx, rcx
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call sym.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call sym.__acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sym.vfprintf
call sym.abort
nop
nop
nop
nop
nop
nop
nop
nop
Function at 0x1800014e0
Capabilities:
Print debug messages

Disassembly:
sub rsp, 0x28
movzx eax, byte [0x18000bb9d]
test eax, eax
jne 0x1800014f8
mov byte [0x18000bb9d], 1
jmp 0x1800014fa
jmp 0x180001531
cmp dword [0x180007160], 0x1db0
je 0x180001512
cmp dword [0x180007160], 0x1db1
jne 0x180001519
call fcn.180001260
jmp 0x18000151e
call fcn.180001390
mov rdx, qword [0x180007168]
lea rcx, str.PspTerminateThreadByPointer:__p_n
call sub.ntoskrnl.exe_DbgPrint
add rsp, 0x28
ret
Function at 0x180002250
Capabilities:
Check os version

Disassembly:
push rdi
sub rsp, 0x160
cmp dword [0x18000bb8c], 0
je 0x18000226d
mov eax, dword [0x18000bb8c]
jmp 0x180002377
mov dword [rsp + 0x30], 0x11c
lea rdi, [rsp + 0x34]
xor eax, eax
mov ecx, 0x118
rep stosb byte [rdi], al
mov qword [rsp + 0x150], 0
lea rdx, str.RtlGetVersion
lea rcx, [rsp + 0x20]
call qword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
lea rcx, [rsp + 0x20]
call qword [sym.imp.ntoskrnl.exe_MmGetSystemRoutineAddress]
mov qword [rsp + 0x150], rax
cmp qword [rsp + 0x150], 0
je 0x1800022cd
lea rcx, [rsp + 0x30]
call qword [rsp + 0x150]
jmp 0x1800022e5
xor r9d, r9d
lea r8, [rsp + 0x3c]
lea rdx, [rsp + 0x38]
lea rcx, [rsp + 0x34]
call qword [sym.imp.ntoskrnl.exe_PsGetVersion]
cmp dword [rsp + 0x34], 5
jne 0x1800022ff
cmp dword [rsp + 0x38], 1
jne 0x1800022ff
mov dword [0x18000bb8c], 0x33
jmp 0x180002371
cmp dword [rsp + 0x34], 6
jne 0x180002319
cmp dword [rsp + 0x38], 1
jne 0x180002319
mov dword [0x18000bb8c], 0x3d
jmp 0x180002371
cmp dword [rsp + 0x34], 6
jne 0x180002333
cmp dword [rsp + 0x38], 2
jne 0x180002333
mov dword [0x18000bb8c], 0x3e
jmp 0x180002371
cmp dword [rsp + 0x34], 6
jne 0x18000234d
cmp dword [rsp + 0x38], 3
jne 0x18000234d
mov dword [0x18000bb8c], 0x3f
jmp 0x180002371
cmp dword [rsp + 0x34], 0xa
jne 0x180002367
cmp dword [rsp + 0x38], 0
jne 0x180002367
mov dword [0x18000bb8c], 0x64
jmp 0x180002371
mov dword [0x18000bb8c], 0x64
mov eax, dword [0x18000bb8c]
add rsp, 0x160
pop rdi
ret
Function at 0x1800032b0
Capabilities:
Create device object
Create thread
Print debug messages

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x128
mov dword [rsp + 0x110], 0
mov rcx, qword [rsp + 0x130]
lea rax, [0x180001700]
mov qword [rcx + 0x70], rax
mov rcx, qword [rsp + 0x130]
lea rax, [0x180001760]
mov qword [rcx + 0x80], rax
mov rcx, qword [rsp + 0x130]
lea rax, [0x180001630]
mov qword [rcx + 0xe0], rax
mov rcx, qword [rsp + 0x130]
lea rax, [0x1800017b0]
mov qword [rcx + 0x68], rax
lea rdx, str.DeviceBEIKESHOUHU
lea rcx, [rsp + 0xc0]
call qword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
lea r11, [rsp + 0x108]
mov qword [rsp + 0x30], r11
mov byte [rsp + 0x28], 0
mov dword [rsp + 0x20], 0
mov r9d, 0x22
lea r8, [rsp + 0xc0]
xor edx, edx
mov rcx, qword [rsp + 0x130]
call qword [sym.imp.ntoskrnl.exe_IoCreateDevice]
mov dword [rsp + 0x110], eax
cmp dword [rsp + 0x110], 0
jge 0x180003388
mov eax, dword [rsp + 0x110]
jmp 0x18000358b
lea rdx, str.DosDevicesGlobalBEIKESHOUHU
lea rcx, [rsp + 0xa8]
call qword [sym.imp.ntoskrnl.exe_RtlInitUnicodeString]
lea rdx, [rsp + 0xc0]
lea rcx, [rsp + 0xa8]
call qword [sym.imp.ntoskrnl.exe_IoCreateSymbolicLink]
mov dword [rsp + 0x110], eax
cmp dword [rsp + 0x110], 0
jge 0x1800033de
mov rcx, qword [rsp + 0x108]
call qword [sym.imp.ntoskrnl.exe_IoDeleteDevice]
mov eax, dword [rsp + 0x110]
jmp 0x18000358b
lea rcx, str.BeiKeShouHu_Driver_loaded____n
call sub.ntoskrnl.exe_DbgPrint
call fcn.180001890
call fcn.180002250
mov qword [rsp + 0x100], 0
mov dword [rsp + 0x78], 0x30
mov qword [rsp + 0x80], 0
mov dword [rsp + 0x90], 0
mov qword [rsp + 0x88], 0
mov qword [rsp + 0x98], 0
mov qword [rsp + 0xa0], 0
mov qword [rsp + 0xb8], 0
mov dword [rsp + 0xd0], 0x30
mov qword [rsp + 0xd8], 0
mov dword [rsp + 0xe8], 0
mov qword [rsp + 0xe0], 0
mov qword [rsp + 0xf0], 0
mov qword [rsp + 0xf8], 0
mov qword [rsp + 0x70], 0
mov dword [rsp + 0x40], 0x30
mov qword [rsp + 0x48], 0
mov dword [rsp + 0x58], 0
mov qword [rsp + 0x50], 0
mov qword [rsp + 0x60], 0
mov qword [rsp + 0x68], 0
mov rax, qword [rsp + 0x130]
mov qword [rsp + 0x30], rax
lea rax, [0x180002800]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], 0
xor r9d, r9d
lea r8, [rsp + 0x78]
mov edx, 0x1fffff
lea rcx, [rsp + 0x100]
call qword [sym.imp.ntoskrnl.exe_PsCreateSystemThread]
mov r11, qword [rsp + 0x130]
mov qword [rsp + 0x30], r11
lea rax, [0x180002870]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], 0
xor r9d, r9d
lea r8, [rsp + 0xd0]
mov edx, 0x1fffff
lea rcx, [rsp + 0xb8]
call qword [sym.imp.ntoskrnl.exe_PsCreateSystemThread]
mov r11, qword [rsp + 0x130]
mov qword [rsp + 0x30], r11
lea rax, [0x180001f60]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], 0
xor r9d, r9d
lea r8, [rsp + 0x40]
mov edx, 0x1fffff
lea rcx, [rsp + 0x70]
call qword [sym.imp.ntoskrnl.exe_PsCreateSystemThread]
xor eax, eax
add rsp, 0x128
ret
Function at 0x180009b80
Capabilities:
Execute syscall

Disassembly:
mov r10, rcx
mov eax, 0x3f
syscall
ret

Function at 0x180009b8b
Capabilities:
Execute syscall

Disassembly:
mov r10, rcx
mov eax, 0x3a
syscall
ret