joyce8/EMBER2024-capa huggingface dataset:
Function at 0x18000c660
Capabilities:
Enumerate processes

Disassembly:
push rbp
push r15
push r14
push rsi
push rdi
push rbx
sub rsp, 0x168
lea rbp, [rsp + 0x80]
mov qword [rbp + 0xe0], 0xfffffffffffffffe
mov ebx, edx
mov rsi, rcx
mov ecx, 2
xor edx, edx
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov rdi, rax
mov qword [rbp + 0xd8], rax
lea rax, [0x18005cd90]
mov qword [rbp + 0xd0], rax
cmp rdi, 0xffffffffffffffff
je 0x18000c6e4
mov dword [rbp - 0x60], 0x130
lea rdx, [rbp - 0x60]
mov rcx, rdi
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x18000c6e4
lea r14, [rbp - 0x58]
lea r15, [rbp - 0x60]
cmp dword [rbp - 0x58], ebx
je 0x18000c70d
mov rcx, rdi
mov rdx, r15
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x18000c6d0
mov qword [rsi], 0
cmp rdi, 0xffffffffffffffff
je 0x18000c6fa
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, rsi
add rsp, 0x168
pop rbx
pop rdi
pop rsi
pop r14
pop r15
pop rbp
ret
lea r8, [rbp - 0x34]
mov rcx, rsi
mov rdx, r14
call fcn.18000cda0
jmp 0x18000c6eb

Function at 0x180012460
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push rsi
push rdi
push rbx
sub rsp, 0x20
test r8, r8
jle 0x1800124f6
mov rsi, r8
mov rdi, rdx
mov rbx, rcx
cmp qword [rcx + 0x68], 0
je 0x1800124fd
mov r15, rsi
jmp 0x1800124bb
cmp r15, r14
cmovb r14, r15
mov rcx, rdi
mov r8, r14
call fcn.18005a6e0
add rdi, r14
sub r15, r14
mov rax, qword [rbx + 0x50]
sub dword [rax], r14d
mov rax, qword [rbx + 0x38]
add qword [rax], r14
test r15, r15
jle 0x1800124ee
mov rax, qword [rbx + 0x38]
mov rdx, qword [rax]
test rdx, rdx
je 0x1800124d3
mov rax, qword [rbx + 0x50]
mov r14d, dword [rax]
test r14d, r14d
jg 0x180012490
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax + 0x38]
cmp eax, 0xffffffff
je 0x1800124ee
mov byte [rdi], al
inc rdi
dec r15
test r15, r15
jg 0x1800124bb
sub rsi, r15
jmp 0x1800125ea
xor esi, esi
jmp 0x1800125ea
mov rax, qword [rbx + 0x38]
mov rdx, qword [rax]
test rdx, rdx
je 0x180012550
mov rax, qword [rbx + 0x50]
movsxd r15, dword [rax]
test r15, r15
je 0x180012550
cmp r15, rsi
cmovae r15, rsi
mov rcx, rdi
mov r8, r15
call fcn.18005a6e0
add rdi, r15
mov r14, rsi
sub r14, r15
mov rax, qword [rbx + 0x50]
sub dword [rax], r15d
mov rax, qword [rbx + 0x38]
movsxd rcx, r15d
add qword [rax], rcx
cmp qword [rbx + 0x80], 0
jne 0x180012561
jmp 0x1800125e7
mov r14, rsi
cmp qword [rbx + 0x80], 0
je 0x1800125e7
mov rax, qword [rbx + 0x18]
lea rcx, [rbx + 0x70]
cmp qword [rax], rcx
jne 0x180012590
mov ecx, dword [rbx + 0x90]
mov rdx, qword [rbx + 0x88]
mov qword [rax], rdx
mov rax, qword [rbx + 0x38]
mov qword [rax], rdx
sub ecx, edx
mov rax, qword [rbx + 0x50]
mov dword [rax], ecx
nop dword [rax]
cmp r14, 0x1000
jb 0x1800125c3
mov r9, qword [rbx + 0x80]
mov edx, 1
mov r8d, 0xfff
mov rcx, rdi
call fcn.180039be8
add rdi, rax
sub r14, rax
cmp rax, 0xfff
je 0x180012590
jmp 0x1800125e7
test r14, r14
je 0x1800125e4
mov r9, qword [rbx + 0x80]
mov edx, 1
mov rcx, rdi
mov r8, r14
call fcn.180039be8
sub r14, rax
jmp 0x1800125e7
xor r14d, r14d
sub rsi, r14
mov rax, rsi
add rsp, 0x20
pop rbx
pop rdi
pop rsi
pop r14
pop r15
ret
Function at 0x180022c40
Capabilities:
Get file size
Read file via mapping

Disassembly:
push r14
push rsi
push rdi
push rbx
sub rsp, 0x48
mov rdi, rdx
cmp qword [rcx + 0x18], 8
jb 0x180022c56
mov rcx, qword [rcx]
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov dword [rsp + 0x20], 3
xor ebx, ebx
mov edx, 0x80000000
mov r8d, 1
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
je 0x180022d08
mov rsi, rax
lea rdx, [rsp + 0x40]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x180022d15
mov rax, qword [rsp + 0x40]
mov qword [rdi], rax
mov r9, rax
shr r9, 0x20
mov dword [rsp + 0x20], eax
mov qword [rsp + 0x28], 0
xor ebx, ebx
mov rcx, rsi
xor edx, edx
mov r8d, 2
call qword [sym.imp.KERNEL32.dll_CreateFileMappingA]
test rax, rax
je 0x180022cff
mov r14, rax
mov rax, qword [rdi]
mov qword [rsp + 0x20], rax
mov rcx, r14
mov edx, 4
xor r8d, r8d
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov rbx, rax
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, rbx
add rsp, 0x48
pop rbx
pop rdi
pop rsi
pop r14
ret
xor ebx, ebx
jmp 0x180022cff

Function at 0x18002c340
Capabilities:
Encode data using xor

Disassembly:
mov r8, qword [rcx + 0x10]
test r8, r8
je 0x18002c438
cmp qword [rcx + 0x18], 0x10
jb 0x18002c357
mov rcx, qword [rcx]
mov rax, r8
and rax, 3
je 0x18002c3a7
xor r9d, r9d
nop word cs:[rax + rax]
movzx r10d, byte [rcx + r9]
add r10d, edx
mov r11d, r10d
shl r11d, 0xa
add r11d, r10d
mov edx, r11d
shr edx, 6
xor edx, r11d
inc r9
cmp rax, r9
jne 0x18002c370
add rcx, r9
mov rax, r8
sub rax, r9
cmp r8, 4
jae 0x18002c3b4
jmp 0x18002c438
mov rax, r8
cmp r8, 4
jb 0x18002c438
xor r8d, r8d
nop word [rax + rax]
movzx r9d, byte [rcx + r8]
add r9d, edx
mov edx, r9d
shl edx, 0xa
add edx, r9d
mov r9d, edx
shr r9d, 6
xor r9d, edx
movzx edx, byte [rcx + r8 + 1]
add edx, r9d
mov r9d, edx
shl r9d, 0xa
add r9d, edx
mov edx, r9d
shr edx, 6
xor edx, r9d
movzx r9d, byte [rcx + r8 + 2]
add r9d, edx
mov edx, r9d
shl edx, 0xa
add edx, r9d
mov r9d, edx
shr r9d, 6
xor r9d, edx
movzx edx, byte [rcx + r8 + 3]
add edx, r9d
mov r9d, edx
shl r9d, 0xa
add r9d, edx
mov edx, r9d
shr edx, 6
xor edx, r9d
add r8, 4
cmp rax, r8
jne 0x18002c3c0
lea eax, [rdx + rdx*8]
mov ecx, eax
shr ecx, 0xb
xor ecx, eax
mov eax, ecx
shl eax, 0xf
add eax, ecx
ret
Function at 0x18002d010
Capabilities:
Encode data using base64

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x28
lea rbp, [rsp + 0x20]
mov qword [rbp], 0xfffffffffffffffe
mov rdi, rdx
mov rsi, rcx
lea rax, [r8 + 2]
movabs rcx, 0xaaaaaaaaaaaaaaab
mul rcx
mov r15, rdx
add r15, rdx
xorps xmm0, xmm0
movups xmmword [rsi + 0x10], xmm0
movups xmmword [rsi], xmm0
and r15, 0xfffffffffffffffc
js 0x18002d27b
mov ebx, r9d
mov r14, r8
cmp r15, 0xf
ja 0x18002d185
mov qword [rsi + 0x10], r15
mov qword [rsi + 0x18], 0xf
mov rcx, rsi
xor edx, edx
mov r8, r15
call fcn.18005ad80
add r15, rsi
mov r12, r15
mov byte [r12], 0
cmp qword [rsi + 0x18], 0x10
mov rax, rsi
jb 0x18002d09f
mov rax, qword [rsi]
mov rcx, qword [rbp + 0x70]
cmp r14, 3
jb 0x18002d1be
lea r8, [r14 - 2]
xor edx, edx
nop word cs:[rax + rax]
movzx r9d, byte [rdi + rdx]
shr r9d, 2
movzx r9d, byte [rcx + r9]
mov byte [rax], r9b
movzx r9d, byte [rdi + rdx]
shl r9d, 4
and r9d, 0x30
movzx r10d, byte [rdi + rdx + 1]
shr r10d, 4
or r10d, r9d
movzx r9d, byte [rcx + r10]
mov byte [rax + 1], r9b
movzx r9d, byte [rdi + rdx + 1]
and r9d, 0xf
movzx r10d, byte [rdi + rdx + 2]
shr r10d, 6
lea r9d, [r10 + r9*4]
movzx r9d, byte [rcx + r9]
mov byte [rax + 2], r9b
movzx r9d, byte [rdi + rdx + 2]
and r9d, 0x3f
movzx r9d, byte [rcx + r9]
mov byte [rax + 3], r9b
add rax, 4
add rdx, 3
cmp rdx, r8
jb 0x18002d0c0
cmp rdx, r14
jae 0x18002d1c9
movzx r8d, byte [rdi + rdx]
shr r8d, 2
movzx r8d, byte [rcx + r8]
mov byte [rax], r8b
dec r14
movzx r8d, byte [rdi + rdx]
shl r8d, 4
and r8d, 0x30
cmp rdx, r14
jne 0x18002d211
movzx ecx, byte [rcx + r8]
mov byte [rax + 1], cl
test bl, bl
je 0x18002d244
mov byte [rax + 2], 0x3d
mov byte [rax + 3], 0x3d
jmp 0x18002d267
mov rax, r15
or rax, 0xf
cmp rax, 0x17
mov r13d, 0x16
cmovae r13, rax
cmp r13, 0xfff
jb 0x18002d1d2
lea rcx, [r13 + 0x28]
call fcn.18002f6c0
mov r12, rax
add r12, 0x27
and r12, 0xffffffffffffffe0
mov qword [r12 - 8], rax
jmp 0x18002d1de
xor edx, edx
cmp rdx, r14
jb 0x18002d13e
test bl, bl
je 0x18002d244
jmp 0x18002d267
lea rcx, [r13 + 1]
call fcn.18002f6c0
mov r12, rax
mov qword [rsi], r12
mov qword [rsi + 0x10], r15
mov qword [rsi + 0x18], r13
mov rcx, r12
xor edx, edx
mov r8, r15
call fcn.18005ad80
add r12, r15
mov byte [r12], 0
cmp qword [rsi + 0x18], 0x10
mov rax, rsi
jae 0x18002d09c
jmp 0x18002d09f
movzx r9d, byte [rdx + rdi + 1]
shr r9d, 4
movzx r8d, r8b
or r8, r9
movzx r8d, byte [rcx + r8]
mov byte [rax + 1], r8b
movzx edx, byte [rdx + rdi + 1]
and edx, 0xf
movzx ecx, byte [rcx + rdx*4]
mov byte [rax + 2], cl
test bl, bl
je 0x18002d244
mov byte [rax + 3], 0x3d
jmp 0x18002d267
cmp qword [rsi + 0x18], 0x10
mov rdi, rsi
jb 0x18002d251
mov rdi, qword [rsi]
mov rcx, rdi
call fcn.180038b90
cmp qword [rsi + 0x10], rax
jb 0x18002d280
mov qword [rsi + 0x10], rax
mov byte [rdi + rax], 0
mov rax, rsi
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret
call fcn.180005fe0
call fcn.18000fb80
int3
Function at 0x180031890
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rdi, rcx
mov rdx, rcx
mov ecx, 0x105
call fcn.180031230
mov ebx, eax
test eax, eax
jne 0x1800318c0
and dword [rsp + 0x38], eax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x3c], eax
jmp 0x18003191c
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x180031913
test al, 0x10
je 0x180031913
bt eax, 0xa
jae 0x18003190c
mov r9d, 0x2000000
lea rcx, [rsp + 0x38]
mov r8d, 0x80
mov rdx, rdi
call fcn.180031934
mov rcx, qword [rsp + 0x38]
mov edi, eax
cmp rcx, 0xffffffffffffffff
je 0x180031908
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x18003192c
test edi, edi
jne 0x180031913
and dword [rsp + 0x3c], 0
jmp 0x180031918
or dword [rsp + 0x3c], 0xffffffff
mov dword [rsp + 0x38], ebx
mov rax, qword [rsp + 0x38]
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
call fcn.1800448ec
int3

Function at 0x180031d24
Capabilities:
Get geographical location

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x40
mov rbx, rdx
lea r8, [rsp + 0x60]
mov edi, ecx
mov edx, 0x20000001
lea rcx, str._x_sys_default_locale
mov r9d, 2
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoEx]
test eax, eax
jne 0x180031d5e
xor r9d, r9d
mov dword [rsp + 0x60], r9d
jmp 0x180031d63
mov r9d, dword [rsp + 0x60]
and qword [rsp + 0x30], 0
mov r8d, edi
and dword [rsp + 0x28], 0
xor edx, edx
mov ecx, 0x1300
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
mov edx, eax
test eax, eax
je 0x180031dac
mov r8, qword [rbx]
dec r8
add r8, rdx
movzx ecx, byte [r8]
lea rax, [0x18005eff0]
cmp byte [rcx + rax], 0
je 0x180031dac
dec r8
sub rdx, 1
jne 0x180031d92
mov rbx, qword [rsp + 0x50]
mov rax, rdx
add rsp, 0x40
pop rdi
ret
Function at 0x180049d8c
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x180049da2
mov al, 1
jmp 0x180049e02
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x180049db3
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x180049e00
mov ecx, dword [rcx + 0x18]
nop
call fcn.180054c4c
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x180049e00
mov r9d, 1
lea r8, [rsp + 0x38]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x180049e00
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x180049e00
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x180049e02
xor al, al
add rsp, 0x20
pop rbx
ret

Function at 0x18004a698
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
lea r9, [0x18007f870]
mov rax, r15
mov rbp, r15
and eax, 0x3f
sar rbp, 6
mov ecx, 4
xor esi, esi
mov r14, rdx
lea rdi, [rax + rax*8]
mov rax, qword [r9 + rbp*8]
lea r13d, [rcx + 6]
mov r10, qword [rax + rdi*8 + 0x28]
test r8, r8
je 0x18004a6ef
cmp word [rdx], r13w
jne 0x18004a6ef
or byte [rax + rdi*8 + 0x38], cl
jmp 0x18004a6f4
and byte [rax + rdi*8 + 0x38], 0xfb
lea r8, [rdx + r8*2]
mov rbx, r14
cmp r14, r8
jae 0x18004a819
mov r11d, 0xd
lea r12d, [r11 - 0xb]
movzx ecx, word [rdx]
cmp cx, 0x1a
je 0x18004a83a
lea r9, [rdx + 2]
cmp cx, r11w
je 0x18004a72d
mov rdx, r9
mov word [rbx], cx
jmp 0x18004a754
cmp r9, r8
jae 0x18004a764
cmp word [r9], r13w
mov rax, r12
mov ecx, 4
cmove rax, rcx
add rdx, rax
mov eax, r13d
cmp word [r9], r13w
cmovne ax, r11w
mov word [rbx], ax
mov rax, r12
add rbx, rax
cmp rdx, r8
jb 0x18004a70e
jmp 0x18004a819
lea r9, [rsp + 0x80]
mov qword [rsp + 0x20], rsi
mov r8d, r12d
lea rdx, [rsp + 0x70]
mov rcx, r10
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x18004a80e
cmp dword [rsp + 0x80], esi
je 0x18004a80e
lea r8, [0x18007f870]
mov rax, qword [r8 + rbp*8]
test byte [rax + rdi*8 + 0x38], 0x48
je 0x18004a7e6
movzx eax, word [rsp + 0x70]
cmp ax, r13w
jne 0x18004a7b6
mov word [rbx], r13w
jmp 0x18004a816
mov ecx, 0xd
mov word [rsp + 0x78], ax
mov word [rbx], cx
mov rax, qword [r8 + rbp*8]
lea rcx, [rax + rdi*8]
mov al, byte [rsp + rsi + 0x78]
mov byte [rcx + rsi + 0x3a], al
inc rsi
cmp rsi, r12
jl 0x18004a7c3
mov rax, qword [r8 + rbp*8]
mov byte [rax + rdi*8 + 0x3c], r13b
jmp 0x18004a816
cmp word [rsp + 0x70], r13w
jne 0x18004a7f3
cmp rbx, r14
je 0x18004a7b0
mov rdx, 0xfffffffffffffffe
mov ecx, r15d
lea r8d, [rdx + 3]
call fcn.18004b898
cmp word [rsp + 0x70], r13w
je 0x18004a819
mov ecx, 0xd
mov word [rbx], cx
add rbx, r12
sub rbx, r14
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
lea r8, [0x18007f870]
mov rdx, qword [r8 + rbp*8]
mov al, byte [rdx + rdi*8 + 0x38]
test al, 0x40
jne 0x18004a813
or al, r12b
mov byte [rdx + rdi*8 + 0x38], al
jmp 0x18004a819
Function at 0x18004b3a8
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.180059f00
sub rsp, rax
mov rax, qword [0x18007c680]
xor rax, rsp
mov qword [rsp + 0x1040], rax
mov r15, r8
mov rbp, rdx
mov rbx, rcx
call fcn.180048fa4
xor edi, edi
movsxd r14, eax
cmp dword [rbx + 0x10], edi
jne 0x18004b3f7
mov rax, rbp
jmp 0x18004b4ff
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, [0x180000000]
xor r8d, r8d
mov rdx, qword [rax + rbx*8 + 0x7f870]
mov ecx, r14d
mov rdx, qword [rdx + r12*8 + 0x30]
call fcn.18004b890
mov r13, rax
lea rax, [0x180000000]
mov rcx, qword [rax + rbx*8 + 0x7f870]
cmp r13, qword [rcx + r12*8 + 0x30]
jne 0x18004b4fb
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 0x18004b4fb
mov r9, r15
xor r8d, r8d
mov rdx, rbp
mov ecx, r14d
call fcn.18004b890
test rax, rax
js 0x18004b4fb
mov eax, dword [rsp + 0x30]
cmp rsi, rax
jg 0x18004b4fb
lea rdx, [rsp + 0x40]
add rdx, rax
lea rcx, [rsp + 0x40]
test rsi, rsi
je 0x18004b4ed
lea r8, [0x180000000]
cmp rcx, rdx
jae 0x18004b4ed
cmp byte [rcx], 0xd
jne 0x18004b4d3
lea rax, [rdx - 1]
cmp rcx, rax
jae 0x18004b4e2
cmp byte [rcx + 1], 0xa
jne 0x18004b4e2
inc rcx
jmp 0x18004b4e2
movzx eax, byte [rcx]
movsx rax, byte [rax + r8 + 0x7caf0]
add rcx, rax
inc rdi
inc rcx
cmp rdi, rsi
jne 0x18004b4b5
lea rax, [rsp + 0x40]
sub rcx, rax
lea rax, [rcx + r13]
jmp 0x18004b4ff
or rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x1040]
xor rcx, rsp
call fcn.180059ed0
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 0x18004f5a8
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 0x18004f5d8
xor eax, eax
jmp 0x18004f69b
mov rbp, rbx
cmp word [rax], si
je 0x18004f5fd
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x18004f5e4
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x18004f5e0
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.18004f4c8
movsxd r14, eax
test eax, eax
jne 0x18004f63b
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x18004f5d1
mov rcx, r14
call fcn.18004be64
mov rdi, rax
test rax, rax
jne 0x18004f654
xor ecx, ecx
call fcn.180047794
jmp 0x18004f630
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.18004f4c8
test eax, eax
jne 0x18004f685
mov rcx, rdi
call fcn.180047794
jmp 0x18004f68f
xor ecx, ecx
call fcn.180047794
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 0x18004f6b8
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 0x18004f73f
mov rsi, rbx
cmp word [rax], bp
je 0x18004f6fe
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x18004f6e8
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x18004f6e4
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.18004be64
mov rdi, rax
test rax, rax
je 0x18004f72c
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.18005a6e0
mov rbp, rdi
xor ecx, ecx
call fcn.180047794
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 0x180054258
Capabilities:
Get geographical location

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
mov esi, edx
mov ebx, ecx
call fcn.180045b38
mov ecx, ebx
lea r8, [rsp + 0x30]
and ecx, 0x3ff
mov r9d, 2
bts ecx, 0xa
mov edx, 0x20000001
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
xor edx, edx
test eax, eax
je 0x1800542f9
cmp ebx, dword [rsp + 0x30]
je 0x1800542f2
test esi, esi
je 0x1800542f2
mov r10, qword [rdi + 0x98]
mov r9d, edx
movzx r8d, word [r10]
lea rcx, [r10 + 2]
lea eax, [r8 - 0x41]
cmp ax, 0x19
jbe 0x1800542cd
sub r8w, 0x61
cmp r8w, 0x19
ja 0x1800542da
movzx r8d, word [rcx]
inc r9d
add rcx, 2
jmp 0x1800542b7
or rax, 0xffffffffffffffff
inc rax
cmp word [r10 + rax*2], dx
jne 0x1800542de
cmp r9d, eax
setne dl
mov eax, edx
jmp 0x1800542fb
mov eax, 1
jmp 0x1800542fb
xor eax, eax
mov rbx, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x18005862c
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.18003b2b8
mov rax, qword [rbp - 0x31]
mov ebx, 0xfde9
cmp dword [rax + 0xc], ebx
jne 0x1800586b6
cmp byte [rbp - 0x21], r15b
je 0x1800586b1
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, ebx
jmp 0x1800586ec
call fcn.180047a98
test eax, eax
jne 0x1800586d8
cmp byte [rbp - 0x21], r15b
je 0x1800586d0
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, 1
jmp 0x1800586ec
cmp byte [rbp - 0x21], r15b
je 0x1800586e9
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.180044b70
test eax, eax
jne 0x18005878c
xor edx, edx
lea rcx, [rbp - 0x39]
call fcn.18003b2b8
mov rax, qword [rbp - 0x31]
cmp dword [rax + 0xc], ebx
jne 0x18005872b
cmp byte [rbp - 0x21], r15b
je 0x180058760
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
jmp 0x180058760
call fcn.180047a98
test eax, eax
jne 0x18005874c
cmp byte [rbp - 0x21], r15b
je 0x180058745
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov ebx, 1
jmp 0x180058760
cmp byte [rbp - 0x21], r15b
je 0x18005875d
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.180044b70
mov rdi, qword [rbp - 9]
test eax, eax
jne 0x18005878c
mov rcx, qword [rbp + 0x27]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov ebx, eax
jmp 0x18005878f
mov ebx, r15d
cmp byte [rbp + 0xf], r15b
je 0x18005879d
mov rcx, rdi
call fcn.180047794
cmp byte [rbp + 0x3f], r15b
je 0x1800587ac
mov rcx, qword [rbp + 0x27]
call fcn.180047794
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 0x180058cbc
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.18004b898
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.18004b898
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x180058e0c
cmp rax, 0xffffffffffffffff
je 0x180058e0c
xor edi, edi
test rbp, rbp
jle 0x180058db7
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.18004771c
mov rbx, rax
test rax, rax
jne 0x180058d44
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x180058dad
mov edx, 0x8000
mov ecx, r14d
call fcn.1800566fc
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.18004998c
cmp eax, 0xffffffff
je 0x180058d8d
cdqe
sub rbp, rax
test rbp, rbp
jg 0x180058d54
mov edx, r15d
mov ecx, r14d
call fcn.1800566fc
jmp 0x180058dad
cmp byte [rsi + 0x38], dil
je 0x180058da4
cmp dword [rsi + 0x34], 5
jne 0x180058da4
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
cmp byte [rsi + 0x30], dil
je 0x180058dad
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.180047794
jmp 0x180058e20
jns 0x180058e20
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.18004b898
cmp rax, 0xffffffffffffffff
jne 0x180058dd8
cmp byte [rsi + 0x30], dil
je 0x180058e20
mov edi, dword [rsi + 0x2c]
jmp 0x180058e20
mov ecx, r14d
call fcn.180054c4c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x180058e20
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 0x180058e20
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x180058e19
mov eax, dword [rsi + 0x2c]
jmp 0x180058e1e
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.18004b898
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 0x180059ff0
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x18005a018
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x18005a018
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret