joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140036350
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
push rdi
sub rsp, 0x28
mov ecx, dword [0x140048100]
test ecx, ecx
je 0x140036430
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jb 0x140036384
mov rdi, rax
cmp qword [rax + 8], 0
je 0x140036384
add rdi, 0x10
jmp 0x140036426
mov ecx, dword [0x140048100]
test ecx, ecx
je 0x140036443
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 1
je 0x140036424
mov rsi, rax
test rax, rax
jne 0x1400363f3
movzx eax, byte [0x140059168]
mov ecx, 0x18
mov edx, 8
call fcn.140002ec0
test rax, rax
je 0x140036466
mov rsi, rax
lea rax, [0x1400480e8]
mov qword [rsi], rax
mov qword [rsi + 8], 0
mov ecx, dword [0x140048100]
test ecx, ecx
je 0x140036456
dec ecx
mov rdx, rsi
call sub.KERNEL32.dll_TlsSetValue
lea rdi, [rsi + 0x10]
mov rcx, qword [rsi + 0x10]
cmp qword [rsi + 8], 0
mov qword [rsi + 8], 1
mov qword [rsi + 0x10], 0
je 0x140036426
test rcx, rcx
je 0x140036426
lock dec qword [rcx]
jne 0x140036426
call fcn.140036480
jmp 0x140036426
xor edi, edi
mov rax, rdi
add rsp, 0x28
pop rdi
pop rsi
ret
lea rcx, [0x1400480e8]
call fcn.1400178d0
mov ecx, eax
jmp 0x140036366
lea rcx, [0x1400480e8]
call fcn.1400178d0
mov ecx, eax
jmp 0x140036394
lea rcx, [0x1400480e8]
call fcn.1400178d0
mov ecx, eax
jmp 0x1400363eb
mov ecx, 8
mov edx, 0x18
call fcn.1400034a0
ud2

Function at 0x140036a60
Capabilities:
Generate random numbers via rtlgenrandom

Disassembly:
push rsi
sub rsp, 0x80
xorps xmm0, xmm0
movaps xmmword [rsp + 0x30], xmm0
lea rcx, [rsp + 0x30]
mov edx, 0x10
call sub.ADVAPI32.dll_SystemFunction036
test al, al
je 0x140036a96
mov rax, qword [rsp + 0x30]
mov rdx, qword [rsp + 0x38]
add rsp, 0x80
pop rsi
ret
call sub.KERNEL32.dll_GetLastError
shl rax, 0x20
or rax, 2
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x28]
mov qword [rsp + 0x40], rax
lea rax, [0x140035ad0]
mov qword [rsp + 0x48], rax
lea rax, str.fallback_RNG_broken:
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], 1
mov qword [rsp + 0x70], 0
lea rax, [rsp + 0x40]
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x68], 1
lea rdx, str.library_std_src_syswindows_rand.rs
lea rcx, [rsp + 0x50]
call fcn.140004000
ud2
Function at 0x14003d7db
Capabilities:
Accept command line arguments

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x60
mov rax, rdx
mov rsi, rcx
lea rdx, [rsp + 0x2c]
mov rcx, rax
call sub.SHELL32.dll_CommandLineToArgvW
test rax, rax
je 0x14003d874
mov rdi, rax
movsxd r12, dword [rsp + 0x2c]
lea rbx, [rsp + 0x30]
mov qword [rbx], 8
xorps xmm0, xmm0
movups xmmword [rbx + 8], xmm0
shl r12, 3
xor r13d, r13d
lea r14, [rsp + 0x48]
cmp r12, r13
je 0x14003d859
mov r15, qword [rdi + r13]
mov rcx, r15
call sub.msvcrt.dll_wcslen
mov rcx, r14
mov rdx, r15
mov r8, rax
call fcn.14003bfd3
mov rcx, rbx
mov rdx, r14
call fcn.14003daf1
add r13, 8
jmp 0x14003d829
mov rcx, rdi
call sub.KERNEL32.dll_LocalFree
movups xmm0, xmmword [rsp + 0x30]
movups xmmword [rsi], xmm0
mov rax, qword [rsp + 0x40]
mov qword [rsi + 0x10], rax
jmp 0x14003d882
mov qword [rsi], 8
xorps xmm0, xmm0
movups xmmword [rsi + 8], xmm0
add rsp, 0x60
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
Function at 0x140044cf9
Capabilities:
Generate random numbers via winapi
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
push rdi
sub rsp, 0x38
mov rsi, rcx
mov ecx, dword [0x140048120]
test ecx, ecx
je 0x140044e09
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jb 0x140044d34
cmp qword [rax + 8], 0
je 0x140044d34
mov rcx, rax
add rcx, 0x10
mov rax, qword [rax + 0x10]
jmp 0x140044dea
mov ecx, dword [0x140048120]
test ecx, ecx
je 0x140044e1c
dec ecx
call sub.KERNEL32.dll_TlsGetValue
mov rdi, rax
cmp rax, 1
je 0x140044dff
test rdi, rdi
jne 0x140044da3
mov al, byte [0x140059168]
mov ecx, 0x20
mov edx, 8
call fcn.140002ec0
test rax, rax
je 0x140044e42
mov rdi, rax
lea rax, [0x140048108]
mov qword [rdi], rax
and qword [rdi + 8], 0
mov ecx, dword [0x140048120]
test ecx, ecx
je 0x140044e2f
dec ecx
mov rdx, rdi
call sub.KERNEL32.dll_TlsSetValue
xorps xmm0, xmm0
lea rdx, [rsp + 0x20]
movaps xmmword [rdx], xmm0
xor ecx, ecx
mov r8d, 0x10
mov r9d, 2
call sub.bcrypt.dll_BCryptGenRandom
test eax, eax
js 0x140044dd1
mov rax, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x28]
jmp 0x140044dd6
call fcn.140036a60
mov qword [rdi + 8], 1
lea rcx, [rdi + 0x10]
mov qword [rdi + 0x10], rax
mov qword [rdi + 0x18], rdx
mov rdx, qword [rcx + 8]
lea r8, [rax + 1]
mov qword [rcx], r8
mov qword [rsi + 8], rax
mov qword [rsi + 0x10], rdx
xor edi, edi
mov qword [rsi], rdi
add rsp, 0x38
pop rdi
pop rsi
ret
lea rcx, [0x140048108]
call fcn.1400178d0
mov ecx, eax
jmp 0x140044d12
lea rcx, [0x140048108]
call fcn.1400178d0
mov ecx, eax
jmp 0x140044d44
lea rcx, [0x140048108]
call fcn.1400178d0
mov ecx, eax
jmp 0x140044d9b
mov ecx, 8
mov edx, 0x20
call fcn.1400034a0
ud2
Function at 0x140045c66
Capabilities:
Reference wmi statements

Disassembly:
push r14
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x40
and qword [rsp + 0x38], 0
mov rsi, rdx
mov rdi, rcx
cmp qword [rdx + 0x10], 0
je 0x140045d2a
lea rcx, [0x140053222]
call sub.OLEAUT32.dll_SysAllocString
mov rbx, rax
lea rcx, str.SELECT__FROM_MSAcpi_ThermalZoneTemperature
call sub.OLEAUT32.dll_SysAllocString
mov r14, rax
mov rcx, qword [rsi + 0x18]
mov rax, qword [rcx]
lea rdx, [rsp + 0x38]
mov qword [rsp + 0x28], rdx
and qword [rsp + 0x20], 0
mov rdx, rbx
mov r8, r14
mov r9d, 0x30
call qword [rax + 0xa0]
mov ebp, eax
mov rcx, rbx
call sub.OLEAUT32.dll_SysFreeString
mov rcx, r14
call sub.OLEAUT32.dll_SysFreeString
test ebp, ebp
js 0x140045d2a
mov rbx, qword [rsp + 0x38]
mov rcx, qword [rsi + 0x20]
mov rdx, qword [rsi + 0x28]
call fcn.140040a9b
mov qword [rsi + 0x20], 1
mov qword [rsi + 0x28], rbx
mov rax, qword [rsi + 0x30]
mov qword [rdi + 0x30], rax
movups xmm0, xmmword [rsi]
movups xmm1, xmmword [rsi + 0x10]
movups xmmword [rdi + 0x10], xmm1
movups xmmword [rdi], xmm0
mov rax, qword [rsi + 0x20]
mov qword [rdi + 0x20], rax
mov rax, qword [rsi + 0x28]
mov qword [rdi + 0x28], rax
jmp 0x140045d39
mov qword [rdi], 2
mov rcx, rsi
call fcn.140040a1f
nop
add rsp, 0x40
pop rbx
pop rbp
pop rdi
pop rsi
pop r14
ret

Function at 0x1400470c0
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 fcn.140047e60
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call fcn.140047e60
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop dword [rax]
Function at 0x140047130
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x1400591f4]
mov rbx, rcx
test esi, esi
jle 0x140047260
mov rax, qword [0x1400591f8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x14004717b
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140047205
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140047160
mov rcx, rbx
call fcn.140047b80
mov rdi, rax
test rax, rax
je 0x140047282
mov rax, qword [0x1400591f8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.140047cc0
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x1400591f8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140047267
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x1400471fe
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140047210
add dword [0x1400591f4], 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 [0x1400591f8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x1400471fe
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.1400470c0
nop dword [rax]
xor esi, esi
jmp 0x140047188
mov rax, qword [0x1400591f8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.1400470c0
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.1400470c0
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x1400477f0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x140059260]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140059240]
test rbx, rbx
je 0x14004784c
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 0x140047843
test rsi, rsi
je 0x140047843
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140047828
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 0x140047b80
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x140053e10]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140047ba0
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140047ba8
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140047ba0
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x140047bfd
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]
mov rdx, r8
cmp rcx, r8
jb 0x140047bf4
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x140047ba0
add rax, 0x28
cmp rax, r9
jne 0x140047be0
xor eax, eax
ret

Function at 0x140047c00
Capabilities:
Parse pe header

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

Function at 0x140047cc0
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140053e10]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x140047cdf
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x140047ce8
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret
Function at 0x14073b870
Capabilities:
Terminate process

Disassembly:
cld
pop r11
jmp 0x14073b87d
inc rsi
mov byte [rdi], dl
inc rdi
mov dl, byte [rsi]
add ebx, ebx
jne 0x14073b88d
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
mov dl, byte [rsi]
jb 0x14073b875
lea eax, [rcx + 1]
jmp 0x14073b89b
dec eax
call r11
adc eax, eax
call r11
adc eax, eax
add ebx, ebx
jne 0x14073b8ae
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
mov dl, byte [rsi]
jae 0x14073b894
sub eax, 3
jb 0x14073b8ce
shl eax, 8
movzx edx, dl
or eax, edx
inc rsi
xor eax, 0xffffffff
je 0x14073b91d
sar eax, 1
movsxd rbp, eax
jb 0x14073b904
jmp 0x14073b8dc
add ebx, ebx
jne 0x14073b8da
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jb 0x14073b904
inc ecx
add ebx, ebx
jne 0x14073b8ea
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jb 0x14073b904
call r11
adc ecx, ecx
add ebx, ebx
jne 0x14073b8fd
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jae 0x14073b8ec
add ecx, 2
jmp 0x14073b909
call r11
adc ecx, ecx
cmp rbp, 0xfffffffffffffb00
adc ecx, 2
call fcn.14073b832
jmp 0x14073b87d
pop rsi
pop rdi
pop rax
mov dword [rdi], eax
sub rsp, 0x28
lea rdi, [rsi + 0x733000]
mov eax, dword [rdi]
or eax, eax
je 0x14073b989
mov ebx, dword [rdi + 4]
lea rcx, [rax + rsi + 0x74bd2c]
add rbx, rsi
add rdi, 8
call qword [sym.imp.KERNEL32.DLL_LoadLibraryA]
xchg rbp, rax
mov al, byte [rdi]
inc rdi
or al, al
je 0x14073b92d
jns 0x14073b962
movzx rdx, word [rdi]
add rdi, 2
jmp 0x14073b96c
mov rcx, rdi
mov rdx, rdi
dec eax
repne scasb al, byte [rdi]
mov rcx, rbp
call qword [sym.imp.KERNEL32.DLL_GetProcAddress]
or rax, rax
je 0x14073b983
mov qword [rbx], rax
add rbx, 8
jmp 0x14073b94d
jmp qword [sym.imp.KERNEL32.DLL_ExitProcess]
add rsp, 0x28
add rdi, 4
lea rbx, [rsi - 4]
xor eax, eax
mov al, byte [rdi]
inc rdi
or eax, eax
je 0x14073b9cd
cmp al, 0xef
ja 0x14073b9b5
add rbx, rax
mov rax, qword [rbx]
bswap rax
add rax, rsi
mov qword [rbx], rax
jmp 0x14073b995
and al, 0xf
shl eax, 0x10
mov ax, word [rdi]
add rdi, 2
or eax, eax
jne 0x14073b9a4
mov eax, dword [rdi]
add rdi, 4
jmp 0x14073b9a4
mov rbp, qword [sym.imp.KERNEL32.DLL_VirtualProtect]
lea rdi, [rsi - 0x1000]
mov ebx, 0x1000
push rax
mov r9, rsp
mov r8d, 4
mov rdx, rbx
mov rcx, rdi
sub rsp, 0x20
call rbp
lea rax, [rdi + 0x24f]
and byte [rax], 0x7f
and byte [rax + 0x28], 0x7f
lea r9, [rsp + 0x20]
mov r8, qword [r9]
mov rdx, rbx
mov rcx, rdi
call rbp
add rsp, 0x28
pop rbp
pop rdi
pop rsi
pop rbx
lea rax, [rsp - 0x80]
push 0
cmp rsp, rax
jne 0x14073ba21
sub rsp, 0xffffffffffffff80
jmp 0x1403b06f0
Function at 0x140001e38
Capabilities:
Parse pe header

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

Function at 0x140005828
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x140005624
Function at 0x14000a464
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 0x14000a4eb
mov rsi, rbx
cmp word [rax], bp
je 0x14000a4aa
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x14000a494
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x14000a490
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.140008418
mov rdi, rax
test rax, rax
je 0x14000a4d8
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.1400020b0
mov rbp, rdi
xor ecx, ecx
call fcn.1400077e4
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 0x180001058
Capabilities:
Get file version info

Disassembly:
mov qword [rsp + 0x18], rbx
push rsi
push rdi
push r13
mov eax, 0x1250
call fcn.1800d50b0
sub rsp, rax
mov rax, qword [0x18010e350]
xor rax, rsp
mov qword [rsp + 0x1240], rax
xor bl, bl
test rcx, rcx
mov rsi, rdx
mov rdi, rcx
mov r13d, 1
je 0x18000116b
cmp word [rcx], 0
je 0x18000116b
lea rcx, [rsp + 0x241]
xor edx, edx
mov r8d, 0xfff
mov byte [rsp + 0x240], bl
call fcn.180086e90
lea r9, [rsp + 0x240]
xor edx, edx
mov r8d, 0x1000
mov rcx, rdi
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x18000116b
and qword [rsp + 0x28], 0
and dword [rsp + 0x20], 0
lea r9, [rsp + 0x20]
lea r8, [rsp + 0x28]
lea rdx, str.StringFileInfo040904b0OriginalFilename
lea rcx, [rsp + 0x240]
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x18000116b
cmp qword [rsp + 0x28], 0
je 0x18000116b
mov edi, dword [rsp + 0x20]
test edi, edi
je 0x18000116b
and word [rsp + 0x30], 0
lea rcx, [rsp + 0x32]
xor edx, edx
mov r8d, 0x206
call fcn.180086e90
mov rdx, qword [rsp + 0x28]
mov eax, 0x103
cmp edi, eax
lea rcx, [rsp + 0x30]
cmova edi, eax
mov r8d, edi
add r8, r8
call fcn.180086b10
lea rdx, str.firefox.exe
lea rcx, [rsp + 0x30]
call fcn.180086a50
movzx ebx, bl
test eax, eax
cmove ebx, r13d
test rsi, rsi
je 0x180001192
cmp word [rsi], 0
je 0x180001192
test bl, bl
jne 0x180001192
lea rdx, str.firefox.exe
mov rcx, rsi
call fcn.180086a50
movzx ebx, bl
test eax, eax
cmove ebx, r13d
mov al, bl
mov rcx, qword [rsp + 0x1240]
xor rcx, rsp
call fcn.180086e60
mov rbx, qword [rsp + 0x1280]
add rsp, 0x1250
pop r13
pop rdi
pop rsi
ret

Function at 0x180002740
Capabilities:
Set registry value

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
sub rsp, 0x30
xor edi, edi
mov rbx, r8
mov rbp, rdx
cmp r8, rdi
mov r12, rcx
jne 0x180002774
mov ecx, 0x80004005
call fcn.1800012c4
int3
mov rsi, rbx
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
cmp eax, 1
lea rsi, [rsi + rax*2]
lea edi, [rdi + rax*2]
jne 0x180002777
mov rcx, qword [r12]
lea r9d, [rax + 6]
xor r8d, r8d
mov rdx, rbp
mov dword [rsp + 0x28], edi
mov qword [rsp + 0x20], rbx
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
mov rdi, qword [rsp + 0x58]
add rsp, 0x30
pop r12
ret
Function at 0x180003154
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x270
mov rax, qword [0x18010e350]
xor rax, rsp
mov qword [rsp + 0x260], rax
and qword [rsp + 0x40], 0
and qword [rsp + 0x50], 0
mov rdi, rcx
mov rcx, qword [rcx]
lea rax, [rsp + 0x50]
mov r9d, 0x2001f
xor r8d, r8d
mov rsi, rdx
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov rcx, qword [rsp + 0x40]
test eax, eax
mov ebx, eax
jne 0x18000324d
test rcx, rcx
je 0x1800031c2
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ebx, eax
mov rcx, qword [rsp + 0x50]
test ebx, ebx
mov qword [rsp + 0x40], rcx
jmp 0x1800031e8
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x40]
call fcn.180003154
mov rcx, qword [rsp + 0x40]
mov ebx, eax
test eax, eax
jne 0x18000324d
lea rax, [rsp + 0x58]
lea r9, [rsp + 0x48]
lea r8, [rsp + 0x60]
mov qword [rsp + 0x38], rax
and qword [rsp + 0x30], 0
and qword [rsp + 0x28], 0
and qword [rsp + 0x20], 0
xor edx, edx
mov dword [rsp + 0x48], 0x100
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
je 0x1800031d0
mov rcx, qword [rsp + 0x40]
test rcx, rcx
je 0x18000323a
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
and qword [rsp + 0x40], 0
mov rcx, qword [rdi]
mov rdx, rsi
call qword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov rcx, qword [rsp + 0x40]
mov ebx, eax
test rcx, rcx
je 0x180003258
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
mov rcx, qword [rsp + 0x260]
xor rcx, rsp
call fcn.180086e60
lea r11, [rsp + 0x270]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret
Function at 0x18000569c
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push rbx
push rsi
push rdi
push r12
push r13
sub rsp, 0x490
mov qword [rsp + 0x58], 0xfffffffffffffffe
mov rax, qword [0x18010e350]
xor rax, rsp
mov qword [rsp + 0x480], rax
mov r13, r9
mov r12, r8
mov rdi, rdx
mov rbx, rcx
call qword [0x18010e050]
and qword [rsp + 0x60], 0
mov qword [rsp + 0x50], rbx
and qword [rsp + 0x48], 0
and qword [rsp + 0x70], 0
xor edx, edx
lea r8d, [rdx + 2]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov rsi, rax
mov qword [rsp + 0x38], rax
test rax, rax
jne 0x180005717
call fcn.180002418
mov ebx, eax
jmp 0x18000585c
mov r8, r13
mov rdx, r12
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_FindResourceW]
mov rbx, rax
test rax, rax
jne 0x18000573a
call fcn.180002418
mov ebx, eax
jmp 0x180005852
mov rdx, rax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov r12, rax
mov qword [rsp + 0x40], rax
test rax, rax
jne 0x18000575f
call fcn.180002418
mov ebx, eax
jmp 0x180005852
mov rdx, rbx
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
mov dword [rsp + 0x30], eax
add eax, 1
cmp eax, edi
jae 0x180005799
lea rax, [rsp + 0x78]
cmp qword [rsp + 0x70], rax
je 0x18000578f
lea rcx, [rsp + 0x70]
call fcn.180003020
nop
mov eax, 0x8007000e
jmp 0x180005875
mov ecx, eax
test eax, eax
je 0x1800057d6
xor edx, edx
or rax, 0xffffffffffffffff
div rcx
cmp rax, 2
jb 0x1800057cc
lea rdx, [rcx + rcx]
cmp rdx, 0x400
jbe 0x1800057d6
lea rcx, [rsp + 0x70]
call fcn.180003038
mov rbx, qword [rsp + 0x70]
jmp 0x1800057e0
mov ecx, 0x80070057
call fcn.1800012c4
lea rbx, [rsp + 0x78]
mov qword [rsp + 0x70], rbx
jmp 0x1800057f5
test rbx, rbx
jne 0x180005801
mov ebx, 0x8007000e
jmp 0x180005852
call qword [0x18010e050]
mov dword [rsp + 0x28], edi
mov qword [rsp + 0x20], rbx
mov r9d, edi
mov r8, r12
xor edx, edx
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jne 0x18000582d
call fcn.180002418
mov ebx, eax
jmp 0x180005852
mov ecx, eax
mov rax, qword [rsp + 0x70]
and word [rax + rcx*2], 0
mov r8d, dword [rsp + 0x4e0]
mov rdx, qword [rsp + 0x70]
lea rcx, [rsp + 0x48]
call fcn.1800053dc
mov ebx, eax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
nop
lea rax, [rsp + 0x78]
cmp qword [rsp + 0x70], rax
je 0x180005873
lea rcx, [rsp + 0x70]
call fcn.180003020
nop
mov eax, ebx
mov rcx, qword [rsp + 0x480]
xor rcx, rsp
call fcn.180086e60
add rsp, 0x490
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret
Function at 0x180006380
Capabilities:
Terminate thread

Disassembly:
push rbx
sub rsp, 0x20
cmp qword [rcx + 0x48], 0
mov rbx, rcx
je 0x1800063d2
mov rcx, qword [rcx + 0x50]
test rcx, rcx
je 0x1800063ae
call qword [sym.imp.KERNEL32.dll_SetEvent]
mov rcx, qword [rbx + 0x48]
mov edx, 0x7d0
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [rbx + 0x50]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TerminateThread]
mov rcx, qword [rbx + 0x50]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
and qword [rbx + 0x50], 0
xor eax, eax
xchg qword [section..FFSHARE], rax
mov rcx, qword [rbx + 0x50]
test rcx, rcx
je 0x1800063e6
call qword [sym.imp.KERNEL32.dll_CloseHandle]
and qword [rbx + 0x50], 0
add rsp, 0x20
pop rbx
ret

Function at 0x1800069c0
Capabilities:
Query or enumerate registry value

Disassembly:
mov r11, rsp
mov qword [r11 + 8], rbx
push rdi
sub rsp, 0x40
mov eax, dword [r9]
and dword [r9], 0
mov rcx, qword [rcx]
add eax, eax
mov rbx, r8
mov rdi, r9
mov dword [rsp + 0x30], eax
lea rax, [r11 - 0x18]
lea r9, [r11 + 0x20]
mov qword [r11 - 0x20], rax
xor r8d, r8d
mov qword [r11 - 0x28], rbx
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x180006a40
cmp dword [rsp + 0x68], 1
je 0x180006a14
cmp dword [rsp + 0x68], 2
je 0x180006a14
mov eax, SafeArrayGetDim
jmp 0x180006a40
test rbx, rbx
mov ecx, dword [rsp + 0x30]
je 0x180006a3a
test ecx, ecx
je 0x180006a36
test cl, 1
jne 0x180006a0d
mov rax, rcx
shr rax, 1
cmp word [rbx + rax*2 - 2], 0
je 0x180006a3a
jmp 0x180006a0d
and word [rbx], 0
shr ecx, 1
xor eax, eax
mov dword [rdi], ecx
mov rbx, qword [rsp + 0x50]
add rsp, 0x40
pop rdi
ret