joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400230fc
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 0x14002312c
xor eax, eax
jmp 0x1400231ef
mov rbp, rbx
cmp word [rax], si
je 0x140023151
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x140023138
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x140023134
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.140020628
movsxd r14, eax
test eax, eax
jne 0x14002318f
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x140023125
mov rcx, r14
call fcn.14001dd1c
mov rdi, rax
test rax, rax
jne 0x1400231a8
xor ecx, ecx
call fcn.14001b06c
jmp 0x140023184
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.140020628
test eax, eax
jne 0x1400231d9
mov rcx, rdi
call fcn.14001b06c
jmp 0x1400231e3
xor ecx, ecx
call fcn.14001b06c
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 0x14002320c
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 0x140023293
mov rsi, rbx
cmp word [rax], bp
je 0x140023252
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x14002323c
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x140023238
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.14001dd1c
mov rdi, rax
test rax, rax
je 0x140023280
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.14000cba0
mov rbp, rdi
xor ecx, ecx
call fcn.14001b06c
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 0x140027c74
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.1400150f8
mov rax, qword [rbp - 0x31]
mov ebx, 0xfde9
cmp dword [rax + 0xc], ebx
jne 0x140027cfe
cmp byte [rbp - 0x21], r15b
je 0x140027cf9
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, ebx
jmp 0x140027d34
call fcn.14001f544
test eax, eax
jne 0x140027d20
cmp byte [rbp - 0x21], r15b
je 0x140027d18
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, 1
jmp 0x140027d34
cmp byte [rbp - 0x21], r15b
je 0x140027d31
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.1400156e4
test eax, eax
jne 0x140027dd4
xor edx, edx
lea rcx, [rbp - 0x39]
call fcn.1400150f8
mov rax, qword [rbp - 0x31]
cmp dword [rax + 0xc], ebx
jne 0x140027d73
cmp byte [rbp - 0x21], r15b
je 0x140027da8
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
jmp 0x140027da8
call fcn.14001f544
test eax, eax
jne 0x140027d94
cmp byte [rbp - 0x21], r15b
je 0x140027d8d
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov ebx, 1
jmp 0x140027da8
cmp byte [rbp - 0x21], r15b
je 0x140027da5
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.1400156e4
mov rdi, qword [rbp - 9]
test eax, eax
jne 0x140027dd4
mov rcx, qword [rbp + 0x27]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov ebx, eax
jmp 0x140027dd7
mov ebx, r15d
cmp byte [rbp + 0xf], r15b
je 0x140027de5
mov rcx, rdi
call fcn.14001b06c
cmp byte [rbp + 0x3f], r15b
je 0x140027df4
mov rcx, qword [rbp + 0x27]
call fcn.14001b06c
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 0x1400293ac
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.14001c9a4
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.14001c9a4
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x1400294fc
cmp rax, 0xffffffffffffffff
je 0x1400294fc
xor edi, edi
test rbp, rbp
jle 0x1400294a7
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.14001f2b8
mov rbx, rax
test rax, rax
jne 0x140029434
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x14002949d
mov edx, 0x8000
mov ecx, r14d
call fcn.14001a2d8
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.14001d680
cmp eax, 0xffffffff
je 0x14002947d
cdqe
sub rbp, rax
test rbp, rbp
jg 0x140029444
mov edx, r15d
mov ecx, r14d
call fcn.14001a2d8
jmp 0x14002949d
cmp byte [rsi + 0x38], dil
je 0x140029494
cmp dword [rsi + 0x34], 5
jne 0x140029494
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
cmp byte [rsi + 0x30], dil
je 0x14002949d
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.14001b06c
jmp 0x140029510
jns 0x140029510
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.14001c9a4
cmp rax, 0xffffffffffffffff
jne 0x1400294c8
cmp byte [rsi + 0x30], dil
je 0x140029510
mov edi, dword [rsi + 0x2c]
jmp 0x140029510
mov ecx, r14d
call fcn.140018790
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x140029510
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 0x140029510
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x140029509
mov eax, dword [rsi + 0x2c]
jmp 0x14002950e
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.14001c9a4
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 0x401010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x004097e0]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x004097f0]
mov dword [rax], 1
mov rax, qword [0x00409800]
mov dword [rax], 1
mov rax, qword [0x00409780]
cmp word [rax], 0x5a4d
jne 0x40105a
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x4010c0
mov rax, qword [0x004097d0]
mov dword [0x0040c020], ecx
mov eax, dword [rax]
test eax, eax
je 0x4010b0
mov ecx, 2
call sym.__set_app_type
call sym.__p__fmode
mov rdx, qword [0x004098b0]
mov edx, dword [rdx]
mov dword [rax], edx
call sym.__p__commode
mov rdx, qword [0x00409890]
mov edx, dword [rdx]
mov dword [rax], edx
call sym._setargv
mov rax, qword [0x00409730]
cmp dword [rax], 1
je 0x4010f8
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x401077
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x401110
cmp dx, 0x20b
jne 0x40105a
cmp dword [rax + 0x84], 0xe
jbe 0x40105a
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x40105a
mov rcx, qword [sym._matherr]
call sym.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x40105a
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x40105a

Function at 0x401668
Capabilities:
Execute command

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
call sym.__main
mov rax, qword [sym.imp.KERNEL32.dll_GetConsoleWindow]
call rax
mov qword [rbp - 0x10], rax
mov edx, 1
lea rax, [sym.CtrlHandler]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_SetConsoleCtrlHandler]
call rax
test eax, eax
je 0x40171a
cmp qword [rbp - 0x10], 0
je 0x40171a
mov rax, qword [rbp - 0x10]
mov edx, 0
mov rcx, rax
mov rax, qword [sym.imp.USER32.dll_GetSystemMenu]
call rax
mov r8d, 1
mov edx, 0xf060
mov rcx, rax
mov rax, qword [sym.imp.USER32.dll_EnableMenuItem]
call rax
mov dword [rbp - 4], 0xa
jmp 0x40170f
lea rax, [0x0040902e]
mov rcx, rax
call sym.system
mov eax, dword [rbp - 4]
mov edx, eax
lea rax, str.Goodbye_in:__d_n_n__
mov rcx, rax
call sym.printf
mov ecx, 0x3e8
mov rax, qword [sym.imp.KERNEL32.dll_Sleep]
call rax
sub dword [rbp - 4], 1
cmp dword [rbp - 4], 0
jg 0x4016da
call sym.bsod
mov eax, 0
add rsp, 0x30
pop rbp
ret

Function at 0x4019f0
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 dword [rax]
Function at 0x401a60
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x0040c0b4]
test esi, esi
mov rbx, rcx
jle 0x401b90
mov rax, qword [0x0040c0b8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x401aab
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x401b35
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x401a90
mov rcx, rbx
call sym.__mingw_GetSectionForAddress
test rax, rax
mov rdi, rax
je 0x401bb2
mov rax, qword [0x0040c0b8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call sym._GetPEImageBase
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x0040c0b8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x401b97
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x401b2e
lea edx, [rax - 0x40]
and edx, 0xffffffbf
jne 0x401b40
add dword [0x0040c0b4], 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
cmp eax, 2
mov r8d, 0x40
mov eax, 4
mov rcx, qword [rsp + 0x20]
cmove r8d, eax
mov rdx, qword [rsp + 0x38]
add rbx, qword [0x0040c0b8]
mov r9, rbx
mov qword [rbx + 8], rcx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x401b2e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call sym.__report_error
nop dword [rax]
xor esi, esi
jmp 0x401ab8
mov rax, qword [0x0040c0b8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [rdi + 8]
mov r8, qword [rax + rbx + 0x18]
call sym.__report_error
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call sym.__report_error
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x402150
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x0040c120]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x0040c100]
test rbx, rbx
je 0x4021ac
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 rsi, rsi
je 0x4021a3
test eax, eax
jne 0x4021a3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x402188
mov rcx, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x4023c0
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x4023d8
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x4023e0
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret
Function at 0x4023f0
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx r8d, word [rcx + 6]
movzx eax, word [rcx + 0x14]
test r8w, r8w
lea rax, [rcx + rax + 0x18]
je 0x40243d
lea ecx, [r8 - 1]
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax + rax]
mov r8d, dword [rax + 0xc]
cmp rdx, r8
mov rcx, r8
jb 0x402434
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x40243f
add rax, 0x28
cmp rax, r9
jne 0x402420
xor eax, eax
ret

Function at 0x402440
Capabilities:
Parse pe header

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rsi, rcx
call sym.strlen
cmp rax, 8
ja 0x4024d0
mov rdx, qword [0x00409780]
xor ebx, ebx
cmp word [rdx], 0x5a4d
jne 0x4024be
movsxd rax, dword [rdx + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
jne 0x4024be
cmp word [rax + 0x18], 0x20b
jne 0x4024be
movzx edx, word [rax + 0x14]
lea rbx, [rax + rdx + 0x18]
movzx edx, word [rax + 6]
test dx, dx
je 0x4024d0
lea eax, [rdx - 1]
lea rax, [rax + rax*4]
lea rdi, [rbx + rax*8 + 0x28]
jmp 0x4024a9
add rbx, 0x28
cmp rbx, rdi
je 0x4024d0
mov r8d, 8
mov rdx, rsi
mov rcx, rbx
call sym.strncmp
test eax, eax
jne 0x4024a0
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
xor ebx, ebx
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret

Function at 0x4024e0
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x00409780]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x402500
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x402508
ret
cmp word [r8 + 0x18], 0x20b
jne 0x402500
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x40255d
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x402554
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x402500
add rax, 0x28
cmp rax, r9
jne 0x402540
xor eax, eax
ret

Function at 0x402560
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x00409780]
xor ecx, ecx
cmp word [rax], 0x5a4d
jne 0x40257f
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x402588
mov eax, ecx
ret
cmp word [rax + 0x18], 0x20b
jne 0x40257f
movzx ecx, word [rax + 6]
mov eax, ecx
ret

Function at 0x4025a0
Capabilities:
Parse pe header

Disassembly:
mov r8, qword [0x00409780]
xor eax, eax
cmp word [r8], 0x5a4d
jne 0x4025c0
movsxd rdx, dword [r8 + 0x3c]
add rdx, r8
cmp dword [rdx], 0x4550
je 0x4025c8
ret
cmp word [rdx + 0x18], 0x20b
jne 0x4025c0
movzx r8d, word [rdx + 6]
movzx eax, word [rdx + 0x14]
test r8w, r8w
lea rax, [rdx + rax + 0x18]
je 0x402610
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea rdx, [rax + rdx*8 + 0x28]
nop dword [rax]
test byte [rax + 0x27], 0x20
je 0x402607
test rcx, rcx
je 0x4025c0
sub rcx, 1
add rax, 0x28
cmp rdx, rax
jne 0x4025f8
xor eax, eax
ret

Function at 0x402620
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x00409780]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x40263f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x402648
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret
Function at 0x402660
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x00409780]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x402680
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x402688
ret
cmp word [r8 + 0x18], 0x20b
jne 0x402680
movzx r9d, word [r8 + 6]
sub rcx, rdx
movzx edx, word [r8 + 0x14]
test r9w, r9w
lea rdx, [r8 + rdx + 0x18]
je 0x402680
lea eax, [r9 - 1]
lea rax, [rax + rax*4]
lea r9, [rdx + rax*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rdx + 0xc]
cmp rcx, r8
mov rax, r8
jb 0x4026d4
add eax, dword [rdx + 8]
cmp rcx, rax
jb 0x4026e0
add rdx, 0x28
cmp rdx, r9
jne 0x4026c0
xor eax, eax
ret
mov eax, dword [rdx + 0x24]
not eax
shr eax, 0x1f
ret

Function at 0x4026f0
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov r11, qword [0x00409780]
xor r9d, r9d
cmp word [r11], 0x5a4d
jne 0x402712
movsxd r8, dword [r11 + 0x3c]
add r8, r11
cmp dword [r8], 0x4550
je 0x402720
mov rax, r9
ret
cmp word [r8 + 0x18], 0x20b
jne 0x402712
mov eax, dword [r8 + 0x90]
test eax, eax
je 0x402712
movzx r10d, word [r8 + 6]
movzx edx, word [r8 + 0x14]
test r10w, r10w
lea rdx, [r8 + rdx + 0x18]
je 0x402712
lea r8d, [r10 - 1]
lea r8, [r8 + r8*4]
lea r10, [rdx + r8*8 + 0x28]
nop word cs:[rax + rax]
mov r9d, dword [rdx + 0xc]
cmp rax, r9
mov r8, r9
jb 0x402775
add r8d, dword [rdx + 8]
cmp rax, r8
jb 0x402788
add rdx, 0x28
cmp r10, rdx
jne 0x402760
xor r9d, r9d
mov rax, r9
ret
add rax, r11
jmp 0x402797
sub ecx, 1
add rax, 0x14
mov r8d, dword [rax + 4]
test r8d, r8d
jne 0x4027a7
mov edx, dword [rax + 0xc]
test edx, edx
je 0x40277e
test ecx, ecx
jg 0x402790
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
ret
Function at 0x14000c010
Capabilities:
Get common file path

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x478
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x3f0], 0xfffffffffffffffe
mov qword [rbp + 0x3e0], rcx
mov qword [rbp + 0x3c8], 0
mov qword [rbp + 0x3d0], 2
mov qword [rbp + 0x3d8], 0
mov r8d, 0x200
mov eax, 2
mov qword [rbp + 0x3e8], rax
xor ebx, ebx
xor edi, edi
xor r12d, r12d
cmp r8, 0x201
jae 0x14000c0b0
jmp 0x14000c09f
jae 0x14000c170
cmp r8, 0x201
jae 0x14000c0b0
mov esi, 0x200
lea r13, [rbp - 0x58]
mov r15, r8
jmp 0x14000c108
sub r8, r12
sub rdi, r12
cmp rdi, r8
jae 0x14000c0df
lea rcx, [rbp + 0x3c8]
mov rdx, r12
call fcn.1400223f0
mov rbx, qword [rbp + 0x3c8]
mov rax, qword [rbp + 0x3d0]
mov qword [rbp + 0x3e8], rax
mov eax, 0xffffffff
cmp rbx, rax
mov r12d, 0xffffffff
cmovb r12, rbx
mov qword [rbp + 0x3d8], r12
mov rdi, rbx
mov rsi, r12
mov r13, qword [rbp + 0x3e8]
mov r15, r12
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov ecx, r15d
mov rdx, r13
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov r14d, eax
test eax, eax
jne 0x14000c131
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x14000c1d8
mov r8d, r14d
cmp r15, r8
jne 0x14000c090
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x14000c205
add r15, r15
mov eax, 0xffffffff
cmp r15, rax
cmovae r15, rax
mov r8, r15
cmp r8, 0x201
jb 0x14000c09f
jmp 0x14000c0b0
cmp rsi, r8
jb 0x14000c21f
lea rcx, [rbp + 0x3a8]
mov rdx, r13
call fcn.14000e200
movups xmm0, xmmword [rbp + 0x3a8]
movups xmm1, xmmword [rbp + 0x3b8]
mov rsi, qword [rbp + 0x3e0]
movups xmmword [rsi + 0x10], xmm1
movups xmmword [rsi], xmm0
test rbx, rbx
je 0x14000c1c1
add rbx, rbx
mov r8d, 2
mov rcx, qword [rbp + 0x3e8]
mov rdx, rbx
call fcn.140009860
mov rax, rsi
add rsp, 0x478
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
shl rax, 0x20
or rax, 2
mov rsi, qword [rbp + 0x3e0]
mov qword [rsi + 8], rax
movabs rax, 0x8000000000000000
mov qword [rsi], rax
test rbx, rbx
jne 0x14000c1a9
jmp 0x14000c1c1
lea rcx, str.internal_error:_entered_unreachable_code_rustc_07dca489ac2d933c78d3c5158e3f43beefeb02celibrary_alloc_src_vecmod.rs
lea r8, str.library_std_src_syswindowsmod.rs
mov edx, 0x28
call fcn.140022e00
jmp 0x14000c234
lea rax, str.library_std_src_syswindowsmod.rs
mov rcx, r8
mov rdx, rsi
mov r8, rax
call fcn.140023250
ud2
Function at 0x140012a40
Capabilities:
Write file on windows

Disassembly:
push rsi
push rdi
sub rsp, 0xa8
mov rdi, rdx
mov rsi, rcx
mov rcx, qword [rsp + 0xe0]
movups xmm0, xmmword [0x140026928]
movaps xmmword [rsp + 0x60], xmm0
mov eax, 0xffffffff
cmp r9, rax
cmovb rax, r9
test rcx, rcx
je 0x140012a84
mov rdx, qword [rsp + 0xe8]
mov qword [rsp + 0x80], rdx
test rcx, rcx
mov qword [rsp + 0x78], rcx
lea rdx, [rsp + 0x80]
cmove rdx, rcx
mov qword [rsp + 0x38], rdx
mov dword [rsp + 0x30], eax
mov qword [rsp + 0x28], r8
lea rax, [rsp + 0x60]
mov qword [rsp + 0x20], rax
mov qword [rsp + 0x40], 0
mov rcx, rdi
xor edx, edx
xor r8d, r8d
xor r9d, r9d
call qword [sym.imp.ntdll.dll_NtWriteFile]
cmp eax, 0x103
jne 0x140012aea
mov rcx, rdi
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [rsp + 0x60]
cmp eax, 0x103
je 0x140012b21
test eax, eax
js 0x140012afb
mov rax, qword [rsp + 0x68]
mov qword [rsi + 8], rax
xor eax, eax
jmp 0x140012b14
mov ecx, eax
call qword [sym.imp.ntdll.dll_RtlNtStatusToDosError]
shl rax, 0x20
or rax, 2
mov qword [rsi + 8], rax
mov eax, 1
mov qword [rsi], rax
add rsp, 0xa8
pop rdi
pop rsi
ret
mov dword [rsp + 0x58], 0
mov byte [rsp + 0x5c], 0
lea rax, str.fatal_runtime_error:_I_O_error:_operation_failed_to_complete_synchronously_n
mov qword [rsp + 0x78], rax
mov qword [rsp + 0x80], 1
lea rax, [rsp + 0x50]
mov qword [rsp + 0x88], rax
xorps xmm0, xmm0
movups xmmword [rsp + 0x90], xmm0
lea rcx, [rsp + 0x58]
lea rdx, [rsp + 0x78]
call fcn.14000df40
mov qword [rsp + 0x70], rax
lea rcx, [rsp + 0x70]
call fcn.14000a310
mov ecx, 7
int 0x29
ud2
Function at 0x140020760
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push r14
push rsi
push rdi
push rbx
sub rsp, 0x28
test r8, r8
je 0x1400207da
mov rax, rdx
mov rdx, qword [rsp + 0x70]
mov esi, ecx
shr esi, 8
lea r8, [rax + r8*2]
xor r11d, r11d
mov rbx, rax
movzx edi, byte [rax + 1]
add rax, 2
lea r10, [r11 + rdi]
cmp byte [rbx], sil
jne 0x1400207d0
cmp r11, r10
ja 0x140020871
cmp r10, rdx
ja 0x140020883
add r11, r9
xor ebx, ebx
nop dword [rax]
cmp rdi, rbx
je 0x1400207d2
lea r14, [rbx + 1]
cmp byte [r11 + rbx], cl
mov rbx, r14
jne 0x1400207b0
jmp 0x140020847
ja 0x1400207da
mov r11, r10
cmp rax, r8
jne 0x140020782
mov rdx, qword [rsp + 0x80]
test rdx, rdx
je 0x14002084b
mov r8, qword [rsp + 0x78]
add rdx, r8
movzx ecx, cx
mov al, 1
nop word cs:[rax + rax]
lea r10, [r8 + 1]
movzx r9d, byte [r8]
test r9b, r9b
js 0x140020820
mov r8, r10
sub ecx, r9d
jns 0x14002083e
jmp 0x14002084d
cmp r10, rdx
je 0x140020859
movzx r10d, byte [r8 + 1]
add r8, 2
and r9d, 0x7f
shl r9d, 8
or r9d, r10d
sub ecx, r9d
js 0x14002084d
xor al, 1
cmp r8, rdx
jne 0x140020800
jmp 0x14002084d
xor eax, eax
jmp 0x14002084d
mov al, 1
and al, 1
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r14
ret
lea rcx, [0x14002882b]
lea r8, str.librarycore_srcunicodeprintable.rs
mov edx, 0x2b
call fcn.140022e00
lea r8, str.librarycore_srcunicodeprintable.rs
mov rcx, r11
mov rdx, r10
call fcn.1400232d0
lea r8, str.librarycore_srcunicodeprintable.rs
mov rcx, r10
call fcn.140023250
int3

Function at 0x140021e5c
Capabilities:
Parse pe header

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