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

Disassembly:
sub rsp, 0x38
cmp byte [rcx + 0xf1e], 0
movsxd r10, r9d
je 0x18012a0e4
cmp r8d, 0xff
jne 0x18012a021
lea eax, [r10 - 0xec]
cmp eax, 0x13
ja 0x18012a00b
lea r8, [0x180000000]
mov r9, qword [r8 + r10*8 + 0x175190]
mov r8, rdx
lea rdx, str._s_IAC__s_n
add rsp, 0x38
jmp fcn.1801069f0
mov r8, rdx
mov r9d, r10d
lea rdx, str._s_IAC__d_n
add rsp, 0x38
jmp fcn.1801069f0
cmp r8d, 0xfb
jne 0x18012a033
lea r9, str.WILL
jmp 0x18012a071
cmp r8d, 0xfc
jne 0x18012a045
lea r9, str.WONT
jmp 0x18012a071
cmp r8d, 0xfd
jne 0x18012a057
lea r9, [0x180175bb4]
jmp 0x18012a071
xor r9d, r9d
lea rax, str.DONT
cmp r8d, 0xfe
cmove r9, rax
test r9, r9
je 0x18012a0cd
cmp r10d, 0x27
jg 0x18012a0a4
lea r8, [0x180000000]
mov r8, qword [r8 + r10*8 + 0x1757b0]
test r8, r8
jne 0x18012a0b4
mov r8, rdx
mov dword [rsp + 0x20], r10d
lea rdx, str._s__s__d_n
call fcn.1801069f0
add rsp, 0x38
ret
cmp r10d, 0xff
jne 0x18012a08b
lea r8, str.EXOPL
mov qword [rsp + 0x20], r8
mov r8, rdx
lea rdx, str._s__s__s_n
call fcn.1801069f0
add rsp, 0x38
ret
mov r9d, r8d
mov dword [rsp + 0x20], r10d
mov r8, rdx
lea rdx, str._s__d__d_n
call fcn.1801069f0
add rsp, 0x38
ret

Function at 0x18012a430
Capabilities:
Send data
Send data on socket

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 0x20], rsi
push rdi
sub rsp, 0x20
mov rbp, qword [rcx]
mov edi, r8d
mov esi, edx
mov byte [rax + 0x10], 0xff
xor r9d, r9d
mov byte [rax + 0x11], sil
mov rbx, rcx
mov byte [rax + 0x12], dil
mov rcx, qword [rcx + 0x4c0]
lea rdx, [rax + 0x10]
lea r8d, [r9 + 3]
call qword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x18012a48f
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Sending_data_failed___d_
mov rcx, rbp
mov r8d, eax
call fcn.180106870
mov rcx, qword [rbx]
lea rdx, str.SENT
mov r9d, edi
mov r8d, esi
call fcn.180129fc0
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
ret
Function at 0x18012a640
Capabilities:
Send data
Send data on socket

Disassembly:
cmp edx, 0x1f
jne 0x18012a7e8
push rbp
push rdi
push r14
sub rsp, 0x20
mov rbp, qword [rcx]
mov r14, rcx
mov qword [rsp + 0x40], rbx
mov qword [rsp + 0x50], rsi
mov qword [rsp + 0x58], r15
mov rdi, qword [rbp + 0x1e0]
lea rsi, [rdi + 0x1cb8]
lea rbx, [rdi + 0x1eb8]
mov qword [rbx], rsi
cmp rsi, rbx
jae 0x18012a6a5
lea rax, [rsi + 1]
mov byte [rsi], 0xff
mov qword [rbx], rax
cmp rax, rbx
jae 0x18012a6a5
mov byte [rax], 0xfa
inc qword [rbx]
mov rax, qword [rbx]
cmp rax, rbx
jae 0x18012a6a5
mov byte [rax], dl
inc qword [rbx]
movzx ecx, word [rdi + 0x1ca8]
call qword [sym.imp.WS2_32.dll_htons]
movzx ecx, word [rdi + 0x1caa]
movzx r15d, ax
mov word [rsp + 0x48], ax
call qword [sym.imp.WS2_32.dll_htons]
mov r9, qword [rbx]
movzx ecx, ax
cmp r9, rbx
jae 0x18012a6dc
mov byte [r9], r15b
inc qword [rbx]
mov r9, qword [rbx]
mov r15, qword [rsp + 0x58]
cmp r9, rbx
jae 0x18012a732
movzx eax, byte [rsp + 0x49]
mov byte [r9], al
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x18012a732
mov byte [r9], cl
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x18012a732
shr cx, 8
mov byte [r9], cl
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x18012a732
mov byte [r9], 0xff
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x18012a732
mov byte [r9], 0xf0
mov r9, qword [rbx]
inc r9
mov qword [rdi + 0x1ec0], r9
lea r8, [rdi + 0x1cba]
sub r9, rsi
mov qword [rbx], rsi
sub r9, 2
mov edx, 0x3e
mov rcx, rbp
call fcn.18012a0f0
mov rcx, qword [r14 + 0x4c0]
xor r9d, r9d
mov rdx, rsi
lea r8d, [r9 + 3]
call qword [sym.imp.WS2_32.dll_send]
mov rsi, qword [rsp + 0x50]
mov rbx, qword [rsp + 0x40]
test eax, eax
jns 0x18012a794
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Sending_data_failed___d_
mov rcx, rbp
mov r8d, eax
call fcn.180106870
lea rdx, [rdi + 0x1cbb]
mov r8d, 4
mov rcx, r14
call fcn.18012a4c0
mov rcx, qword [r14 + 0x4c0]
lea rdx, [rdi + 0x1cbf]
xor r9d, r9d
lea r8d, [r9 + 2]
call qword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x18012a7e0
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Sending_data_failed___d_
mov rcx, rbp
mov r8d, eax
call fcn.180106870
add rsp, 0x20
pop r14
pop rdi
pop rbp
ret
Function at 0x18012bf50
Capabilities:
Receive data
Receive data on socket

Disassembly:
push rbx
push rdi
push r14
sub rsp, 0xd0
mov rax, qword [0x1801f7e40]
xor rax, rsp
mov qword [rsp + 0xc0], rax
mov rbx, qword [rcx + 0xa00]
lea rax, [rsp + 0x30]
mov rdi, qword [rcx]
mov r14, rcx
mov dword [rsp + 0x30], 0x80
xor r9d, r9d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
mov r8d, dword [rbx + 0x15c]
mov rdx, qword [rbx + 0x168]
add r8d, 4
mov rcx, qword [rbx + 0x18]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_recvfrom]
cmp dword [rbx + 0x150], 0
mov dword [rbx + 0x154], eax
jne 0x18012bfe5
movsxd r8, dword [rsp + 0x30]
lea rcx, [rbx + 0xd0]
lea rdx, [rsp + 0x40]
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [rsp + 0x30]
mov dword [rbx + 0x150], eax
mov r8d, dword [rbx + 0x154]
mov qword [rsp + 0xf8], rbp
mov qword [rsp + 0x100], rsi
cmp r8d, 4
jge 0x18012c046
lea rdx, str.Received_too_short_packet
mov rcx, rdi
call fcn.180106870
mov dword [rbx + 0xc], 7
xor eax, eax
mov rsi, qword [rsp + 0x100]
mov rbp, qword [rsp + 0xf8]
mov rcx, qword [rsp + 0xc0]
xor rcx, rsp
call fcn.18013fb90
add rsp, 0xd0
pop r14
pop rdi
pop rbx
ret
mov rdx, qword [rbx + 0x168]
movzx eax, byte [rdx]
movzx ecx, byte [rdx + 1]
shl eax, 8
or ecx, eax
mov dword [rbx + 0xc], ecx
sub ecx, 3
je 0x18012c101
sub ecx, 1
je 0x18012c174
sub ecx, 1
je 0x18012c0b0
cmp ecx, 1
je 0x18012c093
lea r8, str.Internal_error:_Unexpected_packet
mov rcx, rdi
lea rdx, [0x1801d5c88]
call fcn.180106870
jmp 0x18012c174
add r8d, 0xfffffffe
add rdx, 2
mov rcx, rbx
call fcn.18012bc80
test eax, eax
je 0x18012c174
jmp 0x18012c01a
movzx ecx, byte [rdx + 2]
lea eax, [r8 - 4]
movsxd rbp, eax
lea rsi, [rdx + 4]
movzx eax, byte [rdx + 3]
mov r8, rbp
shl ecx, 8
xor edx, edx
or ecx, eax
mov dword [rbx + 8], ecx
mov rcx, rsi
call sub.VCRUNTIME140.dll_memchr
test rax, rax
je 0x18012c174
sub rax, rsi
cmp rax, rbp
jae 0x18012c174
mov r8, rsi
lea rdx, str.TFTP_error:__s_n
mov rcx, rdi
call fcn.1801069f0
jmp 0x18012c174
cmp r8d, 4
jle 0x18012c174
movzx eax, byte [rdx + 3]
movzx ecx, byte [rdx + 2]
shl ecx, 8
or ecx, eax
movzx eax, word [rbx + 0x48]
inc eax
movzx eax, ax
cmp eax, ecx
jne 0x18012c174
lea eax, [r8 - 4]
mov rcx, r14
lea r8, [rdx + 4]
movsxd r9, eax
mov edx, 1
call fcn.180106790
mov esi, eax
test eax, eax
je 0x18012c153
mov edx, 5
mov rcx, rbx
call fcn.18012cc40
mov eax, esi
jmp 0x18012c01a
mov eax, dword [rbx + 0x154]
mov rcx, rdi
sub eax, 4
cdqe
add qword [rdi + 0xf8], rax
mov rdx, qword [rdi + 0xf8]
call fcn.180115070
mov rcx, r14
call fcn.180115350
test eax, eax
je 0x18012c018
mov edx, 5
mov rcx, rbx
call fcn.18012cc40
mov eax, Ordinal_46
jmp 0x18012c01a
Function at 0x18013ef10
Capabilities:
Authenticate hmac
Encode data using xor

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rdi
push r14
sub rsp, 0x20
mov eax, dword [rcx + 0x18]
mov rbx, rcx
mov ebp, r8d
mov r14, rdx
lea ecx, [rax + rax]
mov eax, dword [rbx + 0x20]
add rax, 0x18
add rcx, rax
call qword [fcn.1801410d2]
mov rdi, rax
test rax, rax
jne 0x18013ef52
mov rbx, qword [rsp + 0x50]
add rsp, 0x20
pop r14
pop rdi
pop rbp
ret
lea rcx, [rax + 0x18]
mov qword [rax], rbx
mov qword [rax + 8], rcx
mov eax, dword [rbx + 0x18]
add rax, rcx
mov qword [rsp + 0x48], rsi
mov qword [rdi + 0x10], rax
cmp ebp, dword [rbx + 0x1c]
jbe 0x18013ef99
call qword [rbx]
mov rcx, qword [rdi + 8]
mov r8d, ebp
mov rdx, r14
call qword [rbx + reloc.WS2_32.dll_htonl]
mov r14d, dword [rbx + 0x18]
add r14, qword [rdi + 0x10]
mov rdx, qword [rdi + 8]
mov rcx, r14
call qword [rbx + reloc.WS2_32.dll_recv]
mov rcx, qword [rdi + 8]
mov ebp, dword [rbx + 0x20]
call qword [rbx]
mov rcx, qword [rdi + 0x10]
call qword [rbx]
xor esi, esi
test rbp, rbp
je 0x18013eff2
mov rsi, rbp
nop dword [rax + rax]
movzx eax, byte [r14]
lea rdx, [rsp + 0x40]
xor al, 0x36
mov r8d, 1
mov byte [rsp + 0x40], al
mov rcx, qword [rdi + 8]
call qword [rbx + reloc.WS2_32.dll_htonl]
movzx eax, byte [r14]
lea rdx, [rsp + 0x40]
xor al, 0x5c
lea r14, [r14 + 1]
mov byte [rsp + 0x40], al
mov r8d, 1
mov rcx, qword [rdi + 0x10]
call qword [rbx + reloc.WS2_32.dll_htonl]
sub rbp, 1
jne 0x18013efb0
mov eax, dword [rbx + 0x1c]
cmp rsi, rax
jae 0x18013f033
nop word [rax + rax]
mov rcx, qword [rdi + 8]
lea rdx, [0x180178d42]
mov r8d, 1
call qword [rbx + reloc.WS2_32.dll_htonl]
mov rcx, qword [rdi + 0x10]
lea rdx, [0x180178d43]
mov r8d, 1
call qword [rbx + reloc.WS2_32.dll_htonl]
mov eax, dword [rbx + 0x1c]
inc rsi
cmp rsi, rax
jb 0x18013f000
mov rsi, qword [rsp + 0x48]
mov rax, rdi
mov rbx, qword [rsp + 0x50]
add rsp, 0x20
pop r14
pop rdi
pop rbp
ret

Function at 0x18013f04c
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 0x18013f086
xor r9d, r9d
mov dword [rsp + 0x60], r9d
jmp 0x18013f08b
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 0x18013f0d4
mov r8, qword [rbx]
dec r8
add r8, rdx
movzx ecx, byte [r8]
lea rax, reloc.WS2_32.dll_accept
cmp byte [rcx + rax], 0
je 0x18013f0d4
dec r8
sub rdx, 1
jne 0x18013f0ba
mov rbx, qword [rsp + 0x50]
mov rax, rdx
add rsp, 0x40
pop rdi
ret
Function at 0x140022f34
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x140022d30
Function at 0x140029868
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x14002987e
mov al, 1
jmp 0x1400298de
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x14002988f
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x1400298dc
mov ecx, dword [rcx + 0x18]
nop
call fcn.14001ec70
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x1400298dc
mov r9d, 1
lea r8, [rsp + 0x38]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x1400298dc
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x1400298dc
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x1400298de
xor al, al
add rsp, 0x20
pop rbx
ret
Function at 0x14002d09c
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 0x14002d0cc
xor eax, eax
jmp 0x14002d18f
mov rbp, rbx
cmp word [rax], si
je 0x14002d0f1
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x14002d0d8
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x14002d0d4
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.14002b7ac
movsxd r14, eax
test eax, eax
jne 0x14002d12f
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x14002d0c5
mov rcx, r14
call fcn.1400275a0
mov rdi, rax
test rax, rax
jne 0x14002d148
xor ecx, ecx
call fcn.1400267ac
jmp 0x14002d124
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.14002b7ac
test eax, eax
jne 0x14002d179
mov rcx, rdi
call fcn.1400267ac
jmp 0x14002d183
xor ecx, ecx
call fcn.1400267ac
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 0x14002fde0
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.1400263d4
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 0x14002fe81
cmp ebx, dword [rsp + 0x30]
je 0x14002fe7a
test esi, esi
je 0x14002fe7a
mov r10, qword [rdi + 0x98]
mov r9d, edx
movzx r8d, word [r10]
lea rcx, [r10 + 2]
lea eax, [r8 - 0x41]
cmp ax, 0x19
jbe 0x14002fe55
sub r8w, 0x61
cmp r8w, 0x19
ja 0x14002fe62
movzx r8d, word [rcx]
inc r9d
add rcx, 2
jmp 0x14002fe3f
or rax, 0xffffffffffffffff
inc rax
cmp word [r10 + rax*2], dx
jne 0x14002fe66
cmp r9d, eax
setne dl
mov eax, edx
jmp 0x14002fe83
mov eax, 1
jmp 0x14002fe83
xor eax, eax
mov rbx, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x140033384
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.14001f8bc
mov rax, qword [rbp - 0x31]
mov ebx, 0xfde9
cmp dword [rax + 0xc], ebx
jne 0x14003340e
cmp byte [rbp - 0x21], r15b
je 0x140033409
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, ebx
jmp 0x140033444
call fcn.140026ab0
test eax, eax
jne 0x140033430
cmp byte [rbp - 0x21], r15b
je 0x140033428
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, 1
jmp 0x140033444
cmp byte [rbp - 0x21], r15b
je 0x140033441
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.140022450
test eax, eax
jne 0x1400334e4
xor edx, edx
lea rcx, [rbp - 0x39]
call fcn.14001f8bc
mov rax, qword [rbp - 0x31]
cmp dword [rax + 0xc], ebx
jne 0x140033483
cmp byte [rbp - 0x21], r15b
je 0x1400334b8
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
jmp 0x1400334b8
call fcn.140026ab0
test eax, eax
jne 0x1400334a4
cmp byte [rbp - 0x21], r15b
je 0x14003349d
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov ebx, 1
jmp 0x1400334b8
cmp byte [rbp - 0x21], r15b
je 0x1400334b5
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.140022450
mov rdi, qword [rbp - 9]
test eax, eax
jne 0x1400334e4
mov rcx, qword [rbp + 0x27]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov ebx, eax
jmp 0x1400334e7
mov ebx, r15d
cmp byte [rbp + 0xf], r15b
je 0x1400334f5
mov rcx, rdi
call fcn.1400267ac
cmp byte [rbp + 0x3f], r15b
je 0x140033504
mov rcx, qword [rbp + 0x27]
call fcn.1400267ac
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 0x14001f920
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 0x14001f98f
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14001f98f
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14001f98f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14001f98f
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14001f98f
cmp dword [rcx + 0x84], 0xe
jbe 0x14001f98f
cmp dword [rcx + 0xf8], 0
je 0x14001f98f
mov ecx, ebx
call fcn.14001fa40
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.14001f81c
nop
cmp dword [rbp + 0x20], 0
je 0x14001f9dd
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.14001f9e8
int3
xor r8d, r8d
lea edx, [r8 + 2]
jmp 0x14001f920
Function at 0x1400305e4
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.14001e1c4
mov rax, qword [rbp - 0x31]
mov ebx, 0xfde9
cmp dword [rax + 0xc], ebx
jne 0x14003066e
cmp byte [rbp - 0x21], r15b
je 0x140030669
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, ebx
jmp 0x1400306a4
call fcn.140022e10
test eax, eax
jne 0x140030690
cmp byte [rbp - 0x21], r15b
je 0x140030688
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov r9d, 1
jmp 0x1400306a4
cmp byte [rbp - 0x21], r15b
je 0x1400306a1
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.14001e79c
test eax, eax
jne 0x140030744
xor edx, edx
lea rcx, [rbp - 0x39]
call fcn.14001e1c4
mov rax, qword [rbp - 0x31]
cmp dword [rax + 0xc], ebx
jne 0x1400306e3
cmp byte [rbp - 0x21], r15b
je 0x140030718
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
jmp 0x140030718
call fcn.140022e10
test eax, eax
jne 0x140030704
cmp byte [rbp - 0x21], r15b
je 0x1400306fd
mov rax, qword [rbp - 0x39]
and dword [rax + 0x3a8], 0xfffffffd
mov ebx, 1
jmp 0x140030718
cmp byte [rbp - 0x21], r15b
je 0x140030715
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.14001e79c
mov rdi, qword [rbp - 9]
test eax, eax
jne 0x140030744
mov rcx, qword [rbp + 0x27]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov ebx, eax
jmp 0x140030747
mov ebx, r15d
cmp byte [rbp + 0xf], r15b
je 0x140030755
mov rcx, rdi
call fcn.140022a94
cmp byte [rbp + 0x3f], r15b
je 0x140030764
mov rcx, qword [rbp + 0x27]
call fcn.140022a94
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 0x1400323f0
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x140032418
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x140032418
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret
Function at 0x140008178
Capabilities:
Write file on windows

Disassembly:
mov rax, rsp
push rbp
push rdi
push r12
push r14
push r15
mov rbp, rsp
sub rsp, 0x70
mov qword [rbp - 0x28], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
movzx r14d, dx
mov rdi, rcx
mov ebx, 0xffff
xor esi, esi
cmp bx, dx
jne 0x1400081b5
movzx eax, si
jmp 0x1400083af
mov rax, qword [rcx + 0x40]
mov rdx, qword [rax]
test rdx, rdx
je 0x1400081f6
mov r8, qword [rcx + 0x58]
movsxd r9, dword [r8]
mov rax, r9
lea rcx, [rdx + r9*2]
cmp rdx, rcx
jae 0x1400081f6
lea eax, [r9 - 1]
mov dword [r8], eax
mov rcx, qword [rdi + 0x40]
mov rdx, qword [rcx]
lea rax, [rdx + 2]
mov qword [rcx], rax
mov word [rdx], r14w
movzx eax, r14w
jmp 0x1400083af
cmp qword [rdi + 0x90], rsi
je 0x1400083ac
mov rdx, qword [rdi + 0x18]
lea rax, [rdi + 0x80]
cmp qword [rdx], rax
jne 0x140008231
mov rcx, qword [rdi + 0x70]
mov rax, qword [rdi + 0x68]
mov qword [rdx], rax
mov rax, qword [rdi + 0x38]
mov qword [rax], rcx
sub rcx, rcx
sar rcx, 1
mov rax, qword [rdi + 0x50]
mov dword [rax], ecx
cmp qword [rdi + 0x78], rsi
jne 0x140008259
mov rdx, qword [rdi + 0x90]
movzx ecx, r14w
call fcn.140043b1c
cmp ax, bx
je 0x1400083ac
movzx ebx, r14w
jmp 0x1400083ac
mov word [rbp - 0x30], r14w
mov qword [rbp - 0x10], rsi
mov qword [rbp - 8], rsi
mov qword [rbp - 8], 0xf
mov qword [rbp - 0x10], rsi
mov byte [rbp - 0x20], sil
xor r8d, r8d
lea edx, [r8 + 8]
lea rcx, [rbp - 0x20]
call fcn.14000a514
nop
mov r10, qword [rbp - 0x20]
mov r9, qword [rbp - 8]
lea rdx, [rbp - 0x20]
cmp r9, 0x10
cmovae rdx, r10
lea r8, [rbp - 0x20]
cmovae r8, r10
mov rcx, qword [rdi + 0x78]
mov r10, qword [rcx]
add rdx, qword [rbp - 0x10]
lea rax, [rbp + 0x40]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], rdx
mov qword [rsp + 0x28], r8
lea rax, [rbp + 0x48]
mov qword [rsp + 0x20], rax
lea r9, [rbp - 0x2e]
lea r8, [rbp - 0x30]
lea rdx, [rdi + 0x84]
call qword [r10 + 0x38]
test eax, eax
js 0x14000838c
cmp eax, 1
jg 0x14000836e
lea rax, [rbp - 0x20]
mov r10, qword [rbp - 0x20]
mov r9, qword [rbp - 8]
cmp r9, 0x10
cmovae rax, r10
mov r15, qword [rbp + 0x40]
sub r15, rax
je 0x140008338
lea rcx, [rbp - 0x20]
cmp r9, 0x10
cmovae rcx, r10
mov r9, qword [rdi + 0x90]
mov r8, r15
mov edx, 1
call fcn.14004511c
cmp r15, rax
jne 0x14000838c
mov r9, qword [rbp - 8]
mov r10, qword [rbp - 0x20]
mov byte [rdi + 0x82], 1
lea rax, [rbp - 0x30]
cmp qword [rbp + 0x48], rax
jne 0x140008388
test r15, r15
jne 0x14000828f
cmp qword [rbp - 0x10], 0x20
jae 0x14000838c
xor r8d, r8d
lea edx, [r15 + 8]
lea rcx, [rbp - 0x20]
call fcn.140004508
jmp 0x140008287
cmp eax, 3
jne 0x14000838c
mov rdx, qword [rdi + 0x90]
movzx ecx, word [rbp - 0x30]
call fcn.140043b1c
cmp ax, bx
je 0x14000838c
movzx ebx, r14w
cmp qword [rbp - 8], 0x10
jb 0x14000839c
mov rcx, qword [rbp - 0x20]
call fcn.1400431dc
mov qword [rbp - 8], 0xf
mov qword [rbp - 0x10], rsi
mov byte [rbp - 0x20], sil
movzx eax, bx
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rbp
ret