joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140016c80
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x20
cmp qword [rcx + 0x3260], 0
lea rbx, [rcx + 0x3268]
mov rsi, r8
mov rbp, rdx
mov rdi, rcx
je 0x140016d27
mov r9d, dword [rbx + 4]
mov qword [rsp + 0x30], r14
xor r14d, r14d
test r9d, r9d
jns 0x140016cda
mov eax, r9d
mov rcx, rbx
cdq
sub eax, edx
mov edx, r14d
sar eax, 1
add eax, r9d
test eax, eax
cmovg edx, eax
call fcn.1400234e0
mov r8, rsi
mov dword [rbx], r14d
mov rdx, rbp
mov rcx, rbx
call fcn.140003230
mov eax, dword [rbx]
mov edx, 1
mov r9, qword [rdi + 0x3260]
test eax, eax
lea ecx, [rax - 1]
mov rax, qword [rdi + 0x3270]
cmove ecx, r14d
test rax, rax
movsxd r8, ecx
lea rcx, [0x14009e968]
cmovne rcx, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
mov r14, qword [rsp + 0x30]
jmp 0x140016d2f
mov rcx, rbx
call fcn.140003230
mov rbx, qword [rsp + 0x38]
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
ret

Function at 0x140017170
Capabilities:
Hash data with crc32

Disassembly:
push rbx
movzx r9d, byte [rcx]
lea r8, [rcx + 1]
mov r10d, 0xffffffff
mov rbx, rcx
mov eax, r10d
test r9b, r9b
je 0x1400171c2
lea r11, [0x140059e50]
cmp r9b, 0x23
jne 0x1400171a5
cmp byte [r8], r9b
jne 0x1400171a5
cmp byte [r8 + 1], r9b
cmove eax, r10d
movzx edx, al
movzx ecx, r9b
movzx r9d, byte [r8]
xor rdx, rcx
shr eax, 8
inc r8
xor eax, dword [r11 + rdx*4]
test r9b, r9b
jne 0x140017192
mov r11, qword [0x14009e970]
mov r10, qword [r11 + 0x3228]
test r10, r10
je 0x140017209
lea r9, [r10 + 4]
test r9, r9
je 0x140017209
not eax
cmp dword [r9], eax
je 0x140017212
movsxd r8, dword [r9 - 4]
movsxd rdx, dword [r11 + 0x3220]
add r8, r9
add rdx, 4
xor r9d, r9d
add rdx, r10
cmp r8, rdx
cmovne r9, r8
test r9, r9
jne 0x1400171e0
mov rcx, rbx
pop rbx
jmp fcn.140017080
mov rax, r9
pop rbx
ret
Function at 0x14001a700
Capabilities:
Hash data with crc32

Disassembly:
test r8d, r8d
jle 0x14001a93e
mov r11, rsp
push rbp
push rsi
sub rsp, 0x58
mov rax, qword [0x140084010]
xor rax, rsp
mov qword [rsp + 0x38], rax
mov qword [r11 - 0x18], rdi
mov rbp, rcx
mov qword [r11 - 0x20], r14
lea rdi, [rdx + 0x1a]
mov qword [r11 - 0x28], r15
mov r14d, 0xffffffff
lea r15, [0x140059e50]
mov qword [r11 + 0x18], rbx
movsxd rsi, r8d
nop dword [rax + rax]
mov edx, dword [rdi - 0x1a]
test edx, edx
je 0x14001a906
mov rcx, rbp
call fcn.140019d90
mov r9d, dword [rdi - 0x16]
mov rbx, rax
test r9d, r9d
je 0x14001a7d1
movsxd rdx, dword [rbp + 0x31c0]
mov r8, qword [rbp + 0x31c8]
mov r10, rdx
shl r10, 4
add r10, r8
test rdx, rdx
je 0x14001a7c1
nop dword [rax]
mov rcx, rdx
shr rcx, 1
mov rax, rcx
add rax, rax
cmp dword [r8 + rax*8], r9d
jae 0x14001a7b9
lea r8, [r8 + rax*8]
mov rax, 0xffffffffffffffff
sub rax, rcx
add r8, 0x10
add rdx, rax
jmp 0x14001a7bc
mov rdx, rcx
test rdx, rdx
jne 0x14001a790
cmp r8, r10
je 0x14001a7d1
cmp dword [r8], r9d
jne 0x14001a7d1
mov rcx, qword [r8 + 8]
jmp 0x14001a7d3
xor ecx, ecx
mov qword [rbx + 0x10], rcx
movsx eax, word [rdi - 2]
movd xmm1, eax
movsx eax, word [rdi]
cvtdq2ps xmm1, xmm1
movd xmm0, eax
movss dword [rbx + 0x40], xmm1
cvtdq2ps xmm0, xmm0
movss dword [rbx + 0x44], xmm0
movsx eax, word [rdi + 2]
movd xmm1, eax
movsx eax, word [rdi + 4]
cvtdq2ps xmm1, xmm1
movd xmm0, eax
movss dword [rbx + 0x48], xmm1
cvtdq2ps xmm0, xmm0
movss dword [rbx + 0x4c], xmm0
movsx eax, word [rdi + 6]
movd xmm1, eax
movsx eax, word [rdi + 8]
cvtdq2ps xmm1, xmm1
movd xmm0, eax
mov eax, dword [rbx + 0xb8]
and eax, 0xfffffe49
movss dword [rbx + 0x50], xmm1
or eax, 0x49
mov dword [rbx + 0xb8], eax
cvtdq2ps xmm0, xmm0
movss dword [rbx + 0x54], xmm0
test rcx, rcx
je 0x14001a867
cmp qword [rcx + 0x18], 0
jne 0x14001a85c
mov qword [rcx + 0x18], rbx
jmp 0x14001a867
cmp qword [rcx + 0x20], 0
jne 0x14001a867
mov qword [rcx + 0x20], rbx
mov eax, dword [rdi - 0xe]
mov r9, rbx
mov dword [rbx + 0xb0], eax
movsx eax, byte [rdi - 0xa]
mov dword [rbx + 0x58], eax
mov eax, dword [rdi - 6]
and eax, 0x61fc20
or dword [rbx + 8], eax
mov rax, qword [rbx + 0x10]
test rax, rax
je 0x14001a89c
nop
mov r9, rax
mov rax, qword [rax + 0x10]
test rax, rax
jne 0x14001a890
mov r9d, dword [r9]
lea r8, str.DockNode__02X
mov edx, 0x14
lea rcx, [rsp + 0x20]
call fcn.140002900
movzx r9d, byte [rsp + 0x20]
lea r8, [rsp + 0x21]
mov ecx, r14d
test r9b, r9b
je 0x14001a8f8
cmp r9b, 0x23
jne 0x14001a8db
cmp byte [r8], r9b
jne 0x14001a8db
cmp byte [r8 + 1], r9b
cmove ecx, r14d
movzx edx, cl
movzx eax, r9b
movzx r9d, byte [r8]
xor rdx, rax
shr ecx, 8
inc r8
xor ecx, dword [r15 + rdx*4]
test r9b, r9b
jne 0x14001a8c8
not ecx
call fcn.14000a9c0
mov qword [rbx + 0x80], rax
add rdi, 0x24
sub rsi, 1
jne 0x14001a750
mov r15, qword [rsp + 0x40]
mov r14, qword [rsp + 0x48]
mov rdi, qword [rsp + 0x50]
mov rbx, qword [rsp + 0x80]
mov rcx, qword [rsp + 0x38]
xor rcx, rsp
call fcn.140056b40
add rsp, 0x58
pop rsi
pop rbp
ret
Function at 0x140048530
Capabilities:
Encode data using xor
Generate random numbers using a mersenne twister

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
mov eax, 0x13d0
call fcn.140057c20
sub rsp, rax
mov rax, qword [0x140084010]
xor rax, rsp
mov qword [rsp + 0x13c0], rax
mov rbx, rcx
mov qword [rsp + 0x28], rcx
xor edi, edi
mov dword [rsp + 0x20], edi
call qword [sym.imp.MSVCP140.dll_unsigned_int___cdecl_std::_Random_device_void_]
mov edx, eax
mov dword [rsp + 0x13b4], 0xffffffff
mov dword [rsp + 0x34], eax
lea ecx, [rdi + 1]
nop dword [rax]
mov eax, edx
shr eax, 0x1e
xor eax, edx
imul edx, eax, 0x6c078965
add edx, ecx
mov dword [rsp + rcx*4 + 0x34], edx
inc rcx
cmp rcx, 0x270
jb 0x140048580
mov dword [rsp + 0x30], 0x270
xorps xmm0, xmm0
movups xmmword [rbx], xmm0
mov qword [rbx + 0x10], rdi
mov qword [rbx + 0x18], 0xf
mov byte [rbx], dil
mov dword [rsp + 0x20], 1
mov edi, 5
nop dword [rax]
lea rcx, [rsp + 0x30]
call fcn.1400566f0
mov ecx, eax
imul rax, rcx, 0x1a
cmp eax, 0x15
ja 0x1400485fa
lea rcx, [rsp + 0x30]
call fcn.1400566f0
mov ecx, eax
imul rax, rcx, 0x1a
cmp eax, 0x16
jb 0x1400485e5
shr rax, 0x20
lea r9d, [rax - 0x7fffff9f]
mov rcx, qword [rbx + 0x10]
mov rdx, qword [rbx + 0x18]
cmp rcx, rdx
jae 0x140048631
lea rax, [rcx + 1]
mov qword [rbx + 0x10], rax
mov rax, rbx
cmp rdx, 0x10
jb 0x140048626
mov rax, qword [rbx]
mov byte [rax + rcx], r9b
mov byte [rax + rcx + 1], 0
jmp 0x140048639
mov rcx, rbx
call fcn.140055c00
sub rdi, 1
jne 0x1400485d0
mov rax, rbx
mov rcx, qword [rsp + 0x13c0]
xor rcx, rsp
call fcn.140056b40
mov rbx, qword [rsp + 0x13e8]
add rsp, 0x13d0
pop rdi
ret
Function at 0x1400566f0
Capabilities:
Encode data using xor
Generate random numbers using a mersenne twister

Disassembly:
sub rsp, 8
mov r9, rcx
mov r10d, 0x270
mov ecx, dword [rcx]
cmp ecx, r10d
jne 0x140056751
lea r8, [r9 + 8]
nop dword [rax + rax]
mov edx, dword [r8 - 4]
xor edx, dword [r8]
lea r8, [r8 + 4]
btr edx, 0x1f
xor edx, dword [r8 - 8]
mov eax, edx
and al, 1
neg al
sbb ecx, ecx
shr edx, 1
and ecx, 0x9908b0df
xor ecx, dword [r8 + 0x62c]
xor ecx, edx
mov dword [r8 + 0x9b8], ecx
sub r10, 1
jne 0x140056710
mov ecx, dword [r9]
jmp 0x140056838
cmp ecx, 0x4e0
jb 0x140056838
lea r10, [r9 + 0x9c4]
mov qword [rsp], rbx
mov r11d, dword [r10]
mov ebx, 0xe3
mov eax, r11d
mov r11d, dword [r10 + 4]
mov edx, r11d
lea r10, [r10 + 4]
xor edx, eax
btr edx, 0x1f
xor edx, eax
mov eax, edx
and al, 1
neg al
sbb ecx, ecx
shr edx, 1
and ecx, 0x9908b0df
xor ecx, dword [r10 + 0x630]
xor ecx, edx
mov dword [r10 - 0x9c4], ecx
sub rbx, 1
jne 0x140056770
lea r10, [r9 + 0xd50]
mov ebx, 0x18c
mov r11d, dword [r10]
nop dword [rax + rax]
mov eax, r11d
mov r11d, dword [r10 + 4]
mov edx, r11d
lea r10, [r10 + 4]
xor edx, eax
btr edx, 0x1f
xor edx, eax
mov eax, edx
and al, 1
neg al
sbb ecx, ecx
shr edx, 1
and ecx, 0x9908b0df
xor ecx, dword [r10 - 0xd50]
xor ecx, edx
mov dword [r10 - 0x9c4], ecx
sub rbx, 1
jne 0x1400567c0
mov eax, dword [r9 + 0x1380]
mov edx, eax
xor edx, dword [r9 + 4]
mov rbx, qword [rsp]
btr edx, 0x1f
xor edx, eax
mov eax, edx
and al, 1
neg al
sbb ecx, ecx
shr edx, 1
and ecx, 0x9908b0df
xor ecx, dword [r9 + 0x634]
xor ecx, edx
mov dword [r9 + 0x9c0], ecx
xor ecx, ecx
mov dword [r9], ecx
mov eax, ecx
mov edx, dword [r9 + rax*4 + 4]
lea eax, [rcx + 1]
mov dword [r9], eax
mov ecx, edx
mov eax, dword [r9 + 0x1384]
shr ecx, 0xb
and eax, ecx
xor edx, eax
mov eax, edx
and eax, 0xff3a58ad
shl eax, 7
xor edx, eax
mov eax, edx
and eax, 0xffffdf8c
shl eax, 0xf
xor edx, eax
mov eax, edx
shr eax, 0x12
xor eax, edx
add rsp, 8
ret

Function at 0x1400577cc
Capabilities:
Parse pe header

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

Disassembly:
jmp 0x1400131c0
mov qword [rsp + 8], rcx
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov rcx, qword [rsp + 0x30]
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]
add rsp, 0x28
ret

Function at 0x14001128a
Capabilities:
Execute command

Disassembly:
jmp 0x1400119f0
push rbp
push rdi
sub rsp, 0x108
lea rbp, [rsp + 0x20]
lea rcx, [0x1400220a4]
call fcn.140011389
xor ecx, ecx
call fcn.140011d70
mov ecx, eax
call qword [sym.imp.ucrtbased.dll_srand]
call qword [sym.imp.ucrtbased.dll_rand]
cdq
mov ecx, 0x1e
idiv ecx
mov eax, edx
inc eax
mov dword [rbp + 4], eax
xor eax, eax
cmp eax, 1
je 0x140011adc
call fcn.1400113c0
call fcn.14001114a
mov eax, dword [rbp + 4]
cmp dword [0x14001d170], eax
jge 0x140011a75
lea rcx, [0x14001acf8]
call fcn.14001119f
mov ecx, 0x9c4
call qword [sym.imp.KERNEL32.dll_Sleep]
lea rcx, [0x14001acfc]
call qword [sym.imp.ucrtbased.dll_system]
jmp 0x140011ad7
mov eax, dword [rbp + 4]
cmp dword [0x14001d170], eax
jle 0x140011aa6
lea rcx, str.DOWN_n
call fcn.14001119f
mov ecx, 0x9c4
call qword [sym.imp.KERNEL32.dll_Sleep]
lea rcx, [0x14001acfc]
call qword [sym.imp.ucrtbased.dll_system]
jmp 0x140011ad7
mov eax, dword [rbp + 4]
cmp dword [0x14001d170], eax
jne 0x140011ad7
lea rcx, str.END_n
call fcn.14001119f
mov ecx, 0x9c4
call qword [sym.imp.KERNEL32.dll_Sleep]
lea rcx, [0x14001acfc]
call qword [sym.imp.ucrtbased.dll_system]
jmp 0x140011adc
jmp 0x140011a2f
xor eax, eax
lea rsp, [rbp + 0xe8]
pop rdi
pop rbp
ret

Function at 0x140011294
Capabilities:
Parse pe header

Disassembly:
jmp 0x140014500
sub rsp, 0x38
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov qword [rsp + 0x20], rax
cmp qword [rsp + 0x20], 0
jne 0x140014520
xor al, al
jmp 0x1400145a1
mov rax, qword [rsp + 0x20]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x140014533
xor al, al
jmp 0x1400145a1
mov rax, qword [rsp + 0x20]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x20]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
cmp dword [rax], 0x4550
je 0x14001455d
xor al, al
jmp 0x1400145a1
mov rax, qword [rsp + 0x28]
movzx eax, word [rax + 0x18]
cmp eax, 0x20b
je 0x140014571
xor al, al
jmp 0x1400145a1
mov rax, qword [rsp + 0x28]
cmp dword [rax + 0x84], 0xe
ja 0x140014583
xor al, al
jmp 0x1400145a1
mov eax, 8
imul rax, rax, 0xe
mov rcx, qword [rsp + 0x28]
cmp dword [rcx + rax + 0x88], 0
jne 0x14001459f
xor al, al
jmp 0x1400145a1
mov al, 1
add rsp, 0x38
ret
Function at 0x14011f100
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
mov eax, 0x10090
call fcn.140123c90
sub rsp, rax
mov rax, qword [0x1401669c0]
xor rax, rsp
mov qword [rsp + 0x10080], rax
movzx edx, byte [rcx]
lea rbx, [rsp + 0x30]
xor eax, eax
mov rsi, rcx
mov word [rsp + 0x80], ax
mov edi, 0x28
mov word [rsp + 0x30], ax
test dl, dl
je 0x14011f1c2
nop dword [rax]
cmp word [rbx], 0
mov rcx, rdi
mov rax, rbx
je 0x14011f16d
nop dword [rax]
add rax, 2
dec rcx
cmp word [rax], 0
jne 0x14011f160
cmp rcx, 1
jb 0x14011f21a
mov byte [rsp + 0x20], dl
mov rcx, 0xffffffffffffffff
mov byte [rsp + 0x21], 0
nop word [rax + rax]
cmp word [rax + rcx*2 + 2], 0
lea rcx, [rcx + 1]
jne 0x14011f190
lea rcx, [rax + rcx*2]
mov r8d, 2
lea rdx, [rsp + 0x20]
call fcn.140132304
movzx edx, byte [rsi + 1]
inc rsi
add rbx, 2
dec rdi
test dl, dl
jne 0x14011f150
mov r8d, 0x10000
lea rdx, [rsp + 0x80]
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
dec eax
cmp eax, 0xffff
ja 0x14011f1f3
lea rcx, [rsp + 0x80]
call fcn.1401351c8
jmp 0x14011f1f5
xor eax, eax
mov rcx, qword [rsp + 0x10080]
xor rcx, rsp
call fcn.1401239c0
lea r11, [rsp + 0x10090]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
call fcn.140127150
int3
Function at 0x140123500
Capabilities:
Set environment variable

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
sub rsp, 0x90
mov rax, qword [0x1401669c0]
xor rax, rsp
mov qword [rsp + 0x80], rax
xor eax, eax
lea rbx, [rsp + 0x30]
mov rbp, rdx
mov word [rsp + 0x30], ax
movzx edx, byte [rcx]
mov rsi, rcx
mov edi, 0x28
test dl, dl
je 0x1401235a5
nop
cmp word [rbx], 0
mov rcx, rdi
mov rax, rbx
je 0x14012355d
nop dword [rax]
add rax, 2
dec rcx
cmp word [rax], 0
jne 0x140123550
cmp rcx, 1
jb 0x1401235d6
mov byte [rsp + 0x20], dl
mov rcx, 0xffffffffffffffff
mov byte [rsp + 0x21], 0
cmp word [rax + rcx*2 + 2], 0
lea rcx, [rcx + 1]
jne 0x140123573
lea rcx, [rax + rcx*2]
mov r8d, 2
lea rdx, [rsp + 0x20]
call fcn.140132304
movzx edx, byte [rsi + 1]
inc rsi
add rbx, 2
dec rdi
test dl, dl
jne 0x140123540
mov rdx, rbp
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.1401239c0
mov rbx, qword [rsp + 0xc0]
add rsp, 0x90
pop rdi
pop rsi
pop rbp
ret
call fcn.140127150
int3

Function at 0x140123850
Capabilities:
Set environment variable

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x90
mov rax, qword [0x1401669c0]
xor rax, rsp
mov qword [rsp + 0x80], rax
movzx edx, byte [rcx]
lea rbx, [rsp + 0x30]
xor eax, eax
mov rsi, rcx
mov word [rsp + 0x30], ax
mov edi, 0x28
test dl, dl
je 0x1401238f5
nop
cmp word [rbx], 0
mov rcx, rdi
mov rax, rbx
je 0x1401238ad
nop dword [rax]
add rax, 2
dec rcx
cmp word [rax], 0
jne 0x1401238a0
cmp rcx, 1
jb 0x140123927
mov byte [rsp + 0x20], dl
mov rcx, 0xffffffffffffffff
mov byte [rsp + 0x21], 0
cmp word [rax + rcx*2 + 2], 0
lea rcx, [rcx + 1]
jne 0x1401238c3
lea rcx, [rax + rcx*2]
mov r8d, 2
lea rdx, [rsp + 0x20]
call fcn.140132304
movzx edx, byte [rsi + 1]
inc rsi
add rbx, 2
dec rdi
test dl, dl
jne 0x140123890
xor edx, edx
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rcx, qword [rsp + 0x80]
xor rcx, rsp
call fcn.1401239c0
lea r11, [rsp + 0x90]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
call fcn.140127150
int3

Function at 0x1401243f4
Capabilities:
Parse pe header

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

Disassembly:
mov dword [rsp + 0x18], r8d
mov dword [rsp + 0x10], edx
push rbp
mov rbp, rsp
sub rsp, 0x50
mov qword [rbp - 0x20], 0xfffffffffffffffe
mov qword [rsp + 0x60], rbx
mov ebx, ecx
test r8d, r8d
jne 0x140128833
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140128833
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x140128833
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140128833
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x140128833
cmp dword [rcx + 0x84], 0xe
jbe 0x140128833
cmp dword [rcx + 0xf8], 0
je 0x140128833
mov ecx, ebx
call fcn.1401288e4
mov byte [rbp + 0x28], 0
lea rax, [rbp + 0x18]
mov qword [rbp - 0x18], rax
lea rax, [rbp + 0x20]
mov qword [rbp - 0x10], rax
lea rax, [rbp + 0x28]
mov qword [rbp - 8], rax
mov eax, 2
mov dword [rbp - 0x2c], eax
mov dword [rbp - 0x28], eax
lea r9, [rbp - 0x2c]
lea r8, [rbp - 0x18]
lea rdx, [rbp - 0x28]
lea rcx, [rbp - 0x30]
call fcn.1401286c0
nop
cmp dword [rbp + 0x20], 0
je 0x140128881
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.14012888c
int3
xor r8d, r8d
xor edx, edx
jmp 0x1401287c4

Function at 0x1401289c8
Capabilities:
Parse pe header

Disassembly:
mov dword [rsp + 0x18], r8d
mov dword [rsp + 0x10], edx
push rbp
mov rbp, rsp
sub rsp, 0x50
mov qword [rbp - 0x20], 0xfffffffffffffffe
mov qword [rsp + 0x60], rbx
mov ebx, ecx
test r8d, r8d
jne 0x140128833
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140128833
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x140128833
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140128833
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x140128833
cmp dword [rcx + 0x84], 0xe
jbe 0x140128833
cmp dword [rcx + 0xf8], 0
je 0x140128833
mov ecx, ebx
call fcn.1401288e4
mov byte [rbp + 0x28], 0
lea rax, [rbp + 0x18]
mov qword [rbp - 0x18], rax
lea rax, [rbp + 0x20]
mov qword [rbp - 0x10], rax
lea rax, [rbp + 0x28]
mov qword [rbp - 8], rax
mov eax, 2
mov dword [rbp - 0x2c], eax
mov dword [rbp - 0x28], eax
lea r9, [rbp - 0x2c]
lea r8, [rbp - 0x18]
lea rdx, [rbp - 0x28]
lea rcx, [rbp - 0x30]
call fcn.1401286c0
nop
cmp dword [rbp + 0x20], 0
je 0x140128881
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.14012888c
int3
xor r8d, r8d
xor edx, edx
jmp 0x1401287c4
Function at 0x14013a440
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 0x14013a4c7
mov rsi, rbx
cmp word [rax], bp
je 0x14013a486
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x14013a470
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x14013a46c
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.1401359b4
mov rdi, rax
test rax, rax
je 0x14013a4b4
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.1401407c0
mov rbp, rdi
xor ecx, ecx
call fcn.1401364fc
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 0x14013e03c
Capabilities:
Get file size

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

Function at 0x1401405a0
Capabilities:
Parse pe header

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

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
mov rax, qword [rbp + 0x10]
mov qword [rbp - 8], rax
mov rax, qword [rbp - 8]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x3782c1fcb
mov ecx, 1
call sub.msvcrt.dll_exit
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp + 0x10]
add rax, rdx
mov qword [rbp - 0x10], rax
mov rax, qword [rbp - 0x10]
mov eax, dword [rax]
cmp eax, 0x4550
je 0x3782c1ff7
mov ecx, 1
call sub.msvcrt.dll_exit
mov rax, qword [rbp + 0x18]
mov rdx, qword [rbp + 0x10]
mov qword [rax], rdx
mov rax, qword [rbp + 0x18]
mov rdx, qword [rbp - 8]
mov qword [rax + 0x10], rdx
mov rax, qword [rbp + 0x18]
mov rdx, qword [rbp - 0x10]
mov qword [rax + 8], rdx
mov rax, qword [rbp - 0x10]
lea rdx, [rax + 4]
mov rax, qword [rbp + 0x18]
mov qword [rax + 0x18], rdx
mov rax, qword [rbp - 0x10]
lea rdx, [rax + 0x18]
mov rax, qword [rbp + 0x18]
mov qword [rax + 0x20], rdx
mov rax, qword [rbp + 0x18]
mov rax, qword [rax + 0x20]
mov rdx, qword [rax + 0x18]
mov rax, qword [rbp + 0x18]
mov qword [rax + 0x28], rdx
mov rax, qword [rbp + 0x18]
mov rax, qword [rax + 0x20]
mov eax, dword [rax + 0x38]
mov edx, eax
mov rax, qword [rbp + 0x18]
mov qword [rax + 0x30], rdx
mov rax, qword [rbp + 0x18]
mov rax, qword [rax + 0x20]
mov eax, dword [rax + 0x10]
mov edx, eax
mov rax, qword [rbp + 0x18]
mov qword [rax + 0x38], rdx
nop
add rsp, 0x30
pop rbp
ret

Function at 0x3782cbb80
Capabilities:
Write file on windows

Disassembly:
push rbp
push rbx
sub rsp, 0x38
lea rbp, [rsp + 0x30]
mov qword [rbp + 0x20], rcx
mov qword [rbp + 0x28], rdx
mov qword [rbp + 0x30], r8
mov qword [rbp + 0x38], r9
lea rax, [rbp + 0x28]
mov qword [rbp - 8], rax
mov ecx, 2
call fcn.3782d3600
mov r9, rax
mov r8d, 0x1b
mov edx, 1
lea rax, str.Mingw_w64_runtime_failure:_n
mov rcx, rax
call sub.msvcrt.dll_fwrite
mov rbx, qword [rbp - 8]
mov ecx, 2
call fcn.3782d3600
mov r8, rbx
mov rdx, qword [rbp + 0x20]
mov rcx, rax
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop

Function at 0x3782cc4f2
Capabilities:
Get thread local storage value

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov eax, dword [0x3782ed108]
test eax, eax
je 0x3782cc58a
lea rax, [0x3782ed0e0]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call rax
mov rax, qword [0x3782ed110]
mov qword [rbp - 8], rax
jmp 0x3782cc56e
mov rax, qword [rbp - 8]
mov eax, dword [rax]
mov ecx, eax
mov rax, qword [sym.imp.KERNEL32.dll_TlsGetValue]
call rax
mov qword [rbp - 0x10], rax
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
test eax, eax
jne 0x3782cc562
cmp qword [rbp - 0x10], 0
je 0x3782cc562
mov rax, qword [rbp - 8]
mov rdx, qword [rax + 8]
mov rax, qword [rbp - 0x10]
mov rcx, rax
call rdx
mov rax, qword [rbp - 8]
mov rax, qword [rax + 0x10]
mov qword [rbp - 8], rax
cmp qword [rbp - 8], 0
jne 0x3782cc528
lea rax, [0x3782ed0e0]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call rax
jmp 0x3782cc58b
nop
add rsp, 0x30
pop rbp
ret