joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403410
Capabilities:
Terminate process

Disassembly:
sub rsp, 0x28
mov eax, dword [0x0040f330]
mov qword [rsp + 0x40], rbx
mov qword [rsp + 0x48], rdi
movsxd rdi, dword [0x0040f320]
cmp edi, eax
jl 0x4034da
cmp qword [0x0040f328], 0
jne 0x40347a
mov ecx, 0x40
mov dword [0x0040f330], 4
call qword [sym.imp.msvcrt.dll_malloc]
test rax, rax
mov rbx, rax
jne 0x403471
lea rcx, str.malloc
call qword [sym.imp.msvcrt.dll_perror]
lea ecx, [rbx + 1]
call qword [sym.imp.msvcrt.dll_exit]
int3
mov qword [0x0040f328], rax
jmp 0x4034e1
add eax, eax
movsxd rcx, eax
mov dword [0x0040f330], eax
shl rcx, 4
call qword [sym.imp.msvcrt.dll_malloc]
test rax, rax
mov rbx, rax
jne 0x4034ae
lea rcx, str.malloc
call qword [sym.imp.msvcrt.dll_perror]
lea ecx, [rbx + 1]
call qword [sym.imp.msvcrt.dll_exit]
int3
mov rdx, qword [0x0040f328]
mov r8, rdi
mov rcx, rax
shl r8, 4
call sub.msvcrt.dll_memcpy
mov rcx, qword [0x0040f328]
call qword [sym.imp.msvcrt.dll_free]
mov qword [0x0040f328], rbx
jmp 0x4034e1
mov rbx, qword [0x0040f328]
mov rax, rdi
lea rcx, str._Dsun.java.launcherSUN_STANDARD
add rax, rax
inc edi
mov qword [rbx + rax*8], rcx
mov qword [rbx + rax*8 + 8], 0
mov rbx, qword [rsp + 0x40]
mov dword [0x0040f320], edi
mov rdi, qword [rsp + 0x48]
add rsp, 0x28
ret
Function at 0x404c10
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
mov r11, rsp
sub rsp, 0x178
mov rax, qword [0x0040f300]
mov qword [rsp + 0x150], rax
mov qword [r11 + 0x18], rbx
mov qword [r11 + 0x20], rbp
mov qword [r11 - 8], rsi
mov rsi, rdx
mov qword [r11 - 0x10], rdi
mov rbp, rcx
lea r8, [rsp + 0x40]
xor edi, edi
mov r9d, 0x104
mov rcx, rsi
xor edx, edx
mov rbx, rdi
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
test eax, eax
jne 0x404d0c
nop
nop
nop
nop
mov rdx, qword [rbp + 0x10]
lea rcx, [rsp + 0x40]
inc edi
call fcn.00406c40
test eax, eax
je 0x404cb1
test rbx, rbx
je 0x404ca3
lea rcx, [rsp + 0x40]
mov rdx, rbx
call fcn.00406910
test eax, eax
jle 0x404cb1
mov rcx, rbx
call qword [sym.imp.msvcrt.dll_free]
lea rcx, [rsp + 0x40]
call qword [sym.imp.msvcrt.dll__strdup]
mov rbx, rax
lea r8, [rsp + 0x40]
mov r9d, 0x104
mov edx, edi
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
test eax, eax
je 0x404c70
test rbx, rbx
je 0x404d0c
lea rax, [rsp + 0x30]
mov r9d, 0x20019
xor r8d, r8d
mov rdx, rbx
mov rcx, rsi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x404d10
mov rcx, rbx
call qword [sym.imp.msvcrt.dll_free]
mov rcx, qword [rsp + 0x30]
test rcx, rcx
je 0x404d0c
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
jmp 0x404d6c
mov rcx, rbx
call qword [sym.imp.msvcrt.dll_free]
mov rcx, qword [rsp + 0x30]
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
lea rdx, str.JavaHome
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x38], 0x104
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x404cfc
mov rcx, qword [rsp + 0x30]
test rcx, rcx
je 0x404d61
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea rcx, [rsp + 0x40]
call qword [sym.imp.msvcrt.dll__strdup]
mov rdi, qword [rsp + 0x168]
mov rsi, qword [rsp + 0x170]
mov rbp, qword [rsp + 0x198]
mov rbx, qword [rsp + 0x190]
mov rcx, qword [rsp + 0x150]
call fcn.00409d20
add rsp, 0x178
ret

Function at 0x404e80
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov r8, qword [rcx]
xor r10d, r10d
xor r11d, r11d
movzx eax, byte [r8]
mov qword [rsp + 0x20], rdi
mov rdi, rcx
test al, al
je 0x404eb3
nop
nop
cmp al, 0x20
je 0x404ea8
cmp al, 9
jne 0x404eb3
mov al, byte [r8 + 1]
inc r8
test al, al
jne 0x404ea0
cmp byte [r8], r10b
mov qword [rsp + 0x18], rbx
mov rbx, r8
je 0x404f3a
test r11d, r11d
jne 0x404ed1
movzx eax, byte [r8]
cmp al, 0x20
je 0x404f1c
cmp al, 9
je 0x404f1c
movzx ecx, byte [r8]
cmp cl, 0x5c
jne 0x404ef3
cmp byte [r8 + 1], 0x22
jne 0x404ef3
mov eax, r10d
cdq
and eax, 1
xor eax, edx
sub eax, edx
jne 0x404ef3
inc r8
jmp 0x404f03
cmp cl, 0x22
jne 0x404f03
xor eax, eax
test r11d, r11d
sete al
mov r11d, eax
movzx eax, byte [r8]
inc r8
cmp al, 0x5c
jne 0x404f13
inc r10d
jmp 0x404f16
xor r10d, r10d
cmp byte [r8], 0
jne 0x404ec0
cmp byte [r8], 0
je 0x404f29
mov byte [r8], 0
inc r8
mov qword [rdi], r8
mov rax, rbx
mov rdi, qword [rsp + 0x20]
mov rbx, qword [rsp + 0x18]
ret
mov rdi, qword [rsp + 0x20]
mov rax, rbx
mov rbx, qword [rsp + 0x18]
mov qword [rcx], r8
ret
Function at 0x405c30
Capabilities:
Terminate process

Disassembly:
sub rsp, 0x68
mov qword [rsp + 0x60], rbx
mov qword [rsp + 0x58], rsi
mov rsi, rcx
mov rbx, rdx
mov rcx, r8
mov edx, r9d
mov qword [rsp + 0x50], rdi
mov rdi, r8
call fcn.004059f0
test al, al
jne 0x405c86
mov rcx, qword [sym.imp.msvcrt.dll__iob]
lea r8, str.Error:_could_not_find_Java_2_Runtime_Environment.
lea rdx, [0x0040dbbc]
add rcx, 0x60
call qword [sym.imp.msvcrt.dll_fprintf]
mov ecx, 2
call qword [sym.imp.msvcrt.dll_exit]
int3
lea rdx, str.amd64
xor r8d, r8d
mov rcx, rdi
call fcn.00403520
cmp eax, 1
jge 0x405cc8
mov rcx, qword [sym.imp.msvcrt.dll__iob]
lea r8, str.Error:_no_known_VMs.__check_for_corrupt_jvm.cfg_file_
lea rdx, [0x0040dbbc]
add rcx, 0x60
call qword [sym.imp.msvcrt.dll_fprintf]
mov ecx, 1
call qword [sym.imp.msvcrt.dll_exit]
int3
xor r8d, r8d
mov rdx, rbx
mov rcx, rsi
call fcn.004019b0
mov rbx, qword [rsp + 0x90]
mov edx, 0x2f
mov rcx, rax
mov byte [rbx], 0
mov rsi, rax
call qword [sym.imp.msvcrt.dll_strchr]
test rax, rax
jne 0x405d20
lea edx, [rax + 0x5c]
mov rcx, rsi
call qword [sym.imp.msvcrt.dll_strchr]
test rax, rax
jne 0x405d20
lea rdx, str._s_bin_sjvm.dll
mov r9, rsi
mov r8, rdi
mov rcx, rbx
call qword [sym.imp.msvcrt.dll_sprintf]
jmp 0x405d33
lea rdx, str._sjvm.dll
mov r8, rsi
mov rcx, rbx
call qword [sym.imp.msvcrt.dll_sprintf]
lea rdx, [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.msvcrt.dll__stat]
test eax, eax
je 0x405dd1
xor eax, eax
mov rcx, 0xffffffffffffffff
mov rdi, rsi
repne scasb al, byte [rdi]
mov rdi, rbx
not rcx
lea r8, [rcx - 1]
mov rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
lea rdi, str.Error:_no___s_JVM_at___s.
not rcx
dec rcx
add r8, rcx
mov rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
not rcx
dec rcx
add rcx, r8
call fcn.00401000
lea rdx, str.Error:_no___s_JVM_at___s.
mov r9, rbx
mov rcx, rax
mov r8, rsi
mov rdi, rax
call qword [sym.imp.msvcrt.dll_sprintf]
mov rcx, qword [sym.imp.msvcrt.dll__iob]
lea rdx, [0x0040dbbc]
add rcx, 0x60
mov r8, rdi
call qword [sym.imp.msvcrt.dll_fprintf]
mov ecx, 4
call qword [sym.imp.msvcrt.dll_exit]
int3
mov rdi, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x60]
add rsp, 0x68
ret
Function at 0x405df0
Capabilities:
Read file on windows

Disassembly:
mov rax, rsp
sub rsp, 0x88
mov qword [rax + 0x10], rbp
mov qword [rax + 0x20], rdi
mov eax, 0xffffffff
cmp qword [rdx + 8], rax
mov rdi, rdx
mov ebp, ecx
je 0x405f6e
cmp qword [rdx], rax
je 0x405f6e
mov edx, dword [rdx + 0x10]
xor r8d, r8d
call qword [sym.imp.msvcrt.dll__lseek]
test eax, eax
js 0x405f6e
mov rcx, qword [rdi + 8]
mov qword [rsp + 0x90], rbx
inc rcx
call qword [sym.imp.msvcrt.dll_malloc]
test rax, rax
mov rbx, rax
je 0x405e85
mov qword [rsp + 0xa0], rsi
mov rsi, qword [rdi + 8]
mov rdx, rax
mov r8d, esi
mov ecx, ebp
call qword [sym.imp.msvcrt.dll__read]
movsxd rcx, eax
cmp rcx, rsi
je 0x405ea5
mov rcx, rbx
call qword [sym.imp.msvcrt.dll_free]
xor eax, eax
mov rsi, qword [rsp + 0xa0]
mov rbx, qword [rsp + 0x90]
mov rdi, qword [rsp + 0xa8]
mov rbp, qword [rsp + 0x98]
add rsp, 0x88
ret
mov eax, dword [rdi + 0x14]
test eax, eax
jne 0x405eb4
mov byte [rsi + rbx], al
mov rax, rbx
jmp 0x405e7d
cmp eax, 8
jne 0x405e7b
xor eax, eax
mov r9d, 0x58
lea r8, [0x0040dd98]
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x60], rax
mov eax, dword [rdi + 8]
lea edx, [r9 - 0x67]
lea rcx, [rsp + 0x20]
mov dword [rsp + 0x28], eax
mov qword [rsp + 0x20], rbx
call fcn.004070f0
test eax, eax
js 0x405e72
mov rcx, qword [rdi]
inc rcx
call qword [sym.imp.msvcrt.dll_malloc]
test rax, rax
mov rsi, rax
je 0x405e72
mov qword [rsp + 0x30], rax
mov eax, dword [rdi]
lea rcx, [rsp + 0x20]
mov edx, 1
mov dword [rsp + 0x38], eax
call fcn.00407240
test eax, eax
jns 0x405f48
mov rcx, rbx
call qword [sym.imp.msvcrt.dll_free]
mov rcx, rsi
call qword [sym.imp.msvcrt.dll_free]
xor eax, eax
jmp 0x405e7d
mov rax, qword [rdi]
mov rcx, rbx
mov byte [rsi + rax], 0
call qword [sym.imp.msvcrt.dll_free]
lea rcx, [rsp + 0x20]
call fcn.00407090
test eax, eax
js 0x405f38
mov rax, rsi
jmp 0x405e7d
xor eax, eax
jmp 0x405e8d
Function at 0x405f80
Capabilities:
Read file on windows

Disassembly:
sub rsp, 0x28
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x38], rbp
mov rbp, rdx
mov edx, 0xffffffea
mov qword [rsp + 0x48], rdi
mov ebx, ecx
lea r8d, [rdx + 0x18]
call qword [sym.imp.msvcrt.dll__lseek]
test eax, eax
mov edi, eax
js 0x405fc2
mov r8d, 0x16
mov rdx, rbp
mov ecx, ebx
call qword [sym.imp.msvcrt.dll__read]
test eax, eax
jns 0x405fdb
mov eax, 0xffffffff
mov rdi, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x38]
mov rbx, qword [rsp + 0x30]
add rsp, 0x28
ret
movzx eax, byte [rbp + 2]
movzx ecx, byte [rbp + 3]
shl ecx, 8
or ecx, eax
movzx eax, byte [rbp + 1]
shl ecx, 8
or ecx, eax
movzx eax, byte [rbp]
shl ecx, 8
or ecx, eax
cmp ecx, 0x6054b50
jne 0x406018
mov eax, edi
mov rdi, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x38]
mov rbx, qword [rsp + 0x30]
add rsp, 0x28
ret
xor edx, edx
mov ecx, ebx
mov qword [rsp + 0x20], r12
lea r8d, [rdx + 2]
call qword [sym.imp.msvcrt.dll__lseek]
test eax, eax
mov r12d, eax
jns 0x40603c
mov eax, 0xffffffff
jmp 0x4060ff
mov qword [rsp + 0x40], rsi
mov esi, 0x10015
mov r8d, 2
cmp eax, esi
mov ecx, ebx
cmovl esi, eax
mov edx, esi
neg edx
call qword [sym.imp.msvcrt.dll__lseek]
test eax, eax
js 0x4060f5
mov ecx, 0x10015
call qword [sym.imp.msvcrt.dll_malloc]
test rax, rax
mov rdi, rax
je 0x4060f5
mov r8d, esi
mov rdx, rax
mov ecx, ebx
call qword [sym.imp.msvcrt.dll__read]
test eax, eax
js 0x4060ec
movsxd rsi, eax
add eax, 0xffffffea
movsxd rbx, eax
add rsi, rdi
add rbx, rdi
cmp rbx, rdi
jb 0x4060ec
nop
cmp byte [rbx], 0x50
jne 0x4060e4
movzx eax, byte [rbx + 2]
movzx ecx, byte [rbx + 3]
shl ecx, 8
or ecx, eax
movzx eax, byte [rbx + 1]
shl ecx, 8
or ecx, eax
shl ecx, 8
or ecx, 0x50
cmp ecx, 0x6054b50
jne 0x4060e4
movzx eax, byte [rbx + 0x15]
shl eax, 8
movsxd rcx, eax
movzx eax, byte [rbx + 0x14]
or rcx, rax
lea rax, [rcx + rbx + 0x16]
cmp rax, rsi
je 0x406118
dec rbx
cmp rbx, rdi
jae 0x4060a0
mov rcx, rdi
call qword [sym.imp.msvcrt.dll_free]
mov eax, 0xffffffff
mov rsi, qword [rsp + 0x40]
mov r12, qword [rsp + 0x20]
mov rdi, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x38]
mov rbx, qword [rsp + 0x30]
add rsp, 0x28
ret
mov rax, qword [rbx]
mov rcx, rdi
mov qword [rbp], rax
mov rax, qword [rbx + 8]
mov qword [rbp + 8], rax
mov eax, dword [rbx + 0x10]
mov dword [rbp + 0x10], eax
movzx eax, word [rbx + 0x14]
mov word [rbp + 0x14], ax
call qword [sym.imp.msvcrt.dll_free]
mov r11d, r12d
sub r11, rsi
lea rax, [rbx + r11]
jmp 0x4060fa
Function at 0x4099d0
Capabilities:
Terminate process

Disassembly:
mov rax, rsp
sub rsp, 0x68
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rdi, rcx
lea rsi, [0x0040f430]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_RtlCaptureContext]
mov rbx, qword [0x0040f528]
lea rdx, [rsp + 0x70]
mov rcx, rbx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_RtlLookupFunctionEntry]
test rax, rax
je 0x409a51
mov rdx, qword [rsp + 0x70]
mov qword [rsp + 0x38], 0
lea rcx, [rsp + 0x40]
mov qword [rsp + 0x30], rcx
lea rcx, [rsp + 0x48]
mov r9, rax
mov qword [rsp + 0x28], rcx
xor ecx, ecx
mov r8, rbx
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_RtlVirtualUnwind]
mov r11, qword [0x0040f528]
jmp 0x409a6d
mov r11, qword [rsp + 0x68]
lea rax, [rsp + 0x68]
add rax, 8
mov qword [0x0040f528], r11
mov qword [0x0040f4c8], rax
mov rax, qword [0x0040f300]
mov qword [0x0040f3a0], r11
mov qword [0x0040f4b0], rdi
mov dword [0x0040f390], 0xc0000409
mov dword [0x0040f394], 1
mov qword [rsp + 0x50], rax
mov rax, qword [0x0040f2f8]
xor ecx, ecx
mov qword [rsp + 0x50], rax
call qword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
lea rcx, [0x0040a540]
call qword [sym.imp.KERNEL32.dll_UnhandledExceptionFilter]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov edx, 0xc0000409
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
mov rdi, qword [rsp + 0x88]
mov rsi, qword [rsp + 0x80]
mov rbx, qword [rsp + 0x78]
add rsp, 0x68
ret
cmp rcx, qword [0x0040f300]
jne 0x409d39
rol rcx, 0x10
test cx, 0xffff
jne 0x409d35
ret
ror rcx, 0x10
jmp 0x4099d0
Function at 0x409b10
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x58
mov qword [rsp + 0x70], rbx
mov qword [rsp + 0x78], rdi
cmp word [0x00400000], 0x5a4d
je 0x409b31
xor ebx, ebx
mov dword [rsp + 0x60], ebx
jmp 0x409bad
movsxd rax, dword [0x0040003c]
lea rcx, [0x00400000]
add rax, rcx
cmp dword [rax], 0x4550
je 0x409b52
xor ebx, ebx
mov dword [rsp + 0x60], ebx
jmp 0x409bad
movzx ecx, word [rax + 0x18]
cmp ecx, 0x10b
je 0x409b90
cmp ecx, 0x20b
je 0x409b6e
xor ebx, ebx
mov dword [rsp + 0x60], ebx
jmp 0x409bad
cmp dword [rax + 0x84], 0xe
ja 0x409b7f
xor ebx, ebx
mov dword [rsp + 0x60], ebx
jmp 0x409bad
xor ebx, ebx
cmp dword [rax + 0xf8], ebx
setne bl
mov dword [rsp + 0x60], ebx
jmp 0x409bad
cmp dword [rax + 0x74], 0xe
ja 0x409b9e
xor ebx, ebx
mov dword [rsp + 0x60], ebx
jmp 0x409bad
xor ebx, ebx
cmp dword [rax + 0xe8], ebx
setne bl
mov dword [rsp + 0x60], ebx
mov ecx, 1
call qword [sym.imp.msvcrt.dll___set_app_type]
mov qword [0x0040f910], 0xffffffffffffffff
mov qword [0x0040f918], 0xffffffffffffffff
mov rcx, qword [sym.imp.msvcrt.dll__fmode]
mov eax, dword [0x0040f90c]
mov dword [rcx], eax
mov rcx, qword [sym.imp.msvcrt.dll__commode]
mov eax, dword [0x0040f908]
mov dword [rcx], eax
call fcn.00588000
cmp dword [0x0040f310], 0
jne 0x409c07
lea rcx, [0x00409d00]
call qword [sym.imp.msvcrt.dll___setusermatherr]
lea rdx, [0x0040a280]
lea rcx, [0x0040a278]
call sub.msvcrt.dll__initterm
mov r11d, dword [0x0040f904]
mov dword [rsp + 0x68], r11d
lea rax, [rsp + 0x68]
mov qword [rsp + 0x20], rax
mov r9d, dword [0x0040f900]
lea r8, [rsp + 0x38]
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x30]
call qword [sym.imp.msvcrt.dll___getmainargs]
lea rdx, [0x0040a270]
lea rcx, [0x0040a260]
call sub.msvcrt.dll__initterm
mov r11, qword [rsp + 0x38]
mov rax, qword [sym.imp.msvcrt.dll___initenv]
mov qword [rax], r11
mov r8, qword [rsp + 0x38]
mov rdx, qword [rsp + 0x40]
mov ecx, dword [rsp + 0x30]
call fcn.00403bf0
mov edi, eax
mov dword [rsp + 0x34], eax
test ebx, ebx
jne 0x409c93
mov ecx, eax
call qword [sym.imp.msvcrt.dll_exit]
call qword [sym.imp.msvcrt.dll__cexit]
jmp 0x409cb4
mov eax, edi
mov rbx, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x78]
add rsp, 0x58
ret
Function at 0x14002915c
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.14001c754
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.14001c754
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x1400292ac
cmp rax, 0xffffffffffffffff
je 0x1400292ac
xor edi, edi
test rbp, rbp
jle 0x140029257
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.14001f068
mov rbx, rax
test rax, rax
jne 0x1400291e4
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x14002924d
mov edx, 0x8000
mov ecx, r14d
call fcn.14001a088
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.14001d430
cmp eax, 0xffffffff
je 0x14002922d
cdqe
sub rbp, rax
test rbp, rbp
jg 0x1400291f4
mov edx, r15d
mov ecx, r14d
call fcn.14001a088
jmp 0x14002924d
cmp byte [rsi + 0x38], dil
je 0x140029244
cmp dword [rsi + 0x34], 5
jne 0x140029244
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
cmp byte [rsi + 0x30], dil
je 0x14002924d
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.14001ae1c
jmp 0x1400292c0
jns 0x1400292c0
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.14001c754
cmp rax, 0xffffffffffffffff
jne 0x140029278
cmp byte [rsi + 0x30], dil
je 0x1400292c0
mov edi, dword [rsi + 0x2c]
jmp 0x1400292c0
mov ecx, r14d
call fcn.140018540
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x1400292c0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [rsi + 0x38], 1
mov edi, 0xd
mov dword [rsi + 0x34], eax
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
jmp 0x1400292c0
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x1400292b9
mov eax, dword [rsi + 0x2c]
jmp 0x1400292be
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.14001c754
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 0x140001f8c
Capabilities:
Parse pe header

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

Disassembly:
sub rsp, 0x28
mov rax, qword [str.x0__]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [str.t0__]
mov dword [rax], 1
mov rax, qword [str.p0__]
mov dword [rax], 1
mov rax, qword [0x1402cff10]
cmp word [rax], 0x5a4d
jne 0x14000105a
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400010c0
mov rax, qword [0x1402cff50]
mov dword [0x1402d300c], ecx
mov eax, dword [rax]
test eax, eax
je 0x1400010b0
mov ecx, 2
call sym.__set_app_type
call dbg.__p__fmode
mov rdx, qword [0x1402d0020]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg.__p__commode
mov rdx, qword [0x1402d0000]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x1402cfec0]
cmp dword [rax], 1
je 0x1400010f8
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x140001077
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x140001110
cmp dx, 0x20b
jne 0x14000105a
cmp dword [rax + 0x84], 0xe
jbe 0x14000105a
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x14000105a
mov rcx, qword [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x14000105a
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x14000105a
Function at 0x140186740
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rbx, rcx
lea rax, [rsp + 0x58]
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call dbg.__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 dbg.__acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sym.vfprintf
call sym.abort
nop
nop dword [rax]

Function at 0x1401867b0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x1402d30a4]
mov rbx, rcx
test esi, esi
jle 0x1401868e0
mov rax, qword [0x1402d30a8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x1401867fb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140186885
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x1401867e0
mov rcx, rbx
call dbg.__mingw_GetSectionForAddress
mov rdi, rax
test rax, rax
je 0x140186902
mov rax, qword [0x1402d30a8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call dbg._GetPEImageBase
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x1402d30a8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x1401868e7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x14018687e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140186890
add dword [0x1402d30a4], 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 0x40
mov eax, 4
cmove r8d, eax
add rbx, qword [0x1402d30a8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x14018687e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call dbg.__report_error
nop dword [rax]
xor esi, esi
jmp 0x140186808
mov rax, qword [0x1402d30a8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call dbg.__report_error
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140186e70
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x1402d3100]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1402d30e0]
test rbx, rbx
je 0x140186ecc
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax]
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x140186ec3
test rsi, rsi
je 0x140186ec3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140186ea8
mov rcx, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]