joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140062a00
Capabilities:
Check http status code

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x30
xor ebx, ebx
lea eax, [rdx - 0xc8]
mov rdi, rcx
mov rcx, qword [rcx]
mov esi, r8d
cmp eax, 0x64
jb 0x140062a35
lea rdx, str.Couldnt_set_desired_mode
call fcn.140035330
lea eax, [rbx + 0x11]
add rsp, 0x30
pop rdi
pop rsi
pop rbx
ret
cmp edx, 0xc8
je 0x140062a4c
mov r8d, edx
lea rdx, str.Got_a__03d_response_code_instead_of_the_assumed_200_n
call fcn.1400354b0
mov qword [rsp + 0x58], rbp
mov qword [rsp + 0x60], r14
cmp esi, 0x13
jne 0x140062a68
mov rcx, rdi
call fcn.140062940
jmp 0x140062b9f
cmp esi, 0x14
jne 0x140062b81
mov rsi, qword [rdi]
mov rbp, rbx
cmp dword [rsi + 0xba0], 2
jne 0x140062ae9
mov rax, qword [rsi + 0x1e0]
mov rdx, qword [rax]
test rdx, rdx
je 0x140062ae9
mov byte [rsp + 0x28], 1
lea r9, [rsp + 0x50]
xor r8d, r8d
mov qword [rsp + 0x20], rbx
mov rcx, rsi
mov qword [rsp + 0x50], rbx
call fcn.14005a4e0
test eax, eax
jne 0x140062b9f
mov rcx, qword [rsp + 0x50]
lea edx, [rax + 0x2f]
call sub.VCRUNTIME140.dll_strrchr
test rax, rax
je 0x140062ade
mov rbp, qword [rsp + 0x50]
mov ecx, 1
sub rax, rbp
cmovne rcx, rax
mov byte [rcx + rbp], bl
jmp 0x140062ae9
mov rcx, qword [rsp + 0x50]
call qword [fcn.14007f364]
mov rdx, qword [rsi + 0xc08]
test rdx, rdx
jne 0x140062b0d
cmp byte [rsi + 0xf0d], bl
lea rax, str.NLST
lea rdx, str.LIST
cmovne rdx, rax
lea r8, [0x1400900e1]
test rbp, rbp
mov r9, r8
lea rax, [0x140091850]
cmovne r9, rbp
lea rcx, [0x1400843e8]
cmovne r8, rax
call fcn.1400362e0
mov rcx, rbp
mov r14, rax
call qword [fcn.14007f364]
test r14, r14
jne 0x140062b4c
lea ebx, [r14 + 0x1b]
jmp 0x140062ba1
lea rcx, [rdi + 0xa00]
mov r8, r14
lea rdx, [0x14008a580]
call fcn.140078bc0
mov rcx, r14
mov esi, eax
call qword [fcn.14007f364]
test esi, esi
je 0x140062b75
mov ebx, esi
jmp 0x140062ba1
mov dword [rdi + 0xab8], 0x1f
jmp 0x140062ba1
cmp esi, 0x15
jne 0x140062b8c
lea r8d, [rsi - 8]
jmp 0x140062b95
cmp esi, 0x16
jne 0x140062ba1
lea r8d, [rsi - 8]
mov dl, 1
mov rcx, rdi
call fcn.140062480
mov ebx, eax
mov r14, qword [rsp + 0x60]
mov eax, ebx
mov rbp, qword [rsp + 0x58]
add rsp, 0x30
pop rdi
pop rsi
pop rbx
ret
Function at 0x1400684a0
Capabilities:
Write file on windows

Disassembly:
sub rsp, 0x38
cmp byte [rcx + 0xf1e], 0
movsxd r10, r9d
je 0x1400685c4
cmp r8d, 0xff
jne 0x140068501
lea eax, [r10 - 0xec]
cmp eax, 0x13
ja 0x1400684eb
lea r8, [0x140000000]
mov r9, qword [r8 + r10*8 + 0x8c100]
mov r8, rdx
lea rdx, str._s_IAC__s_n
add rsp, 0x38
jmp fcn.1400354b0
mov r8, rdx
mov r9d, r10d
lea rdx, str._s_IAC__d_n
add rsp, 0x38
jmp fcn.1400354b0
cmp r8d, 0xfb
jne 0x140068513
lea r9, str.WILL
jmp 0x140068551
cmp r8d, 0xfc
jne 0x140068525
lea r9, str.WONT
jmp 0x140068551
cmp r8d, 0xfd
jne 0x140068537
lea r9, [0x14008cb24]
jmp 0x140068551
xor r9d, r9d
lea rax, str.DONT
cmp r8d, 0xfe
cmove r9, rax
test r9, r9
je 0x1400685ad
cmp r10d, 0x27
jg 0x140068584
lea r8, [0x140000000]
mov r8, qword [r8 + r10*8 + 0x8c720]
test r8, r8
jne 0x140068594
mov r8, rdx
mov dword [rsp + 0x20], r10d
lea rdx, str._s__s__d_n
call fcn.1400354b0
add rsp, 0x38
ret
cmp r10d, 0xff
jne 0x14006856b
lea r8, str.EXOPL
mov qword [rsp + 0x20], r8
mov r8, rdx
lea rdx, str._s__s__s_n
call fcn.1400354b0
add rsp, 0x38
ret
mov r9d, r8d
mov dword [rsp + 0x20], r10d
mov r8, rdx
lea rdx, str._s__d__d_n
call fcn.1400354b0
add rsp, 0x38
ret

Function at 0x140068910
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 0x14006896f
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Sending_data_failed___d_
mov rcx, rbp
mov r8d, eax
call fcn.140035330
mov rcx, qword [rbx]
lea rdx, str.SENT
mov r9d, edi
mov r8d, esi
call fcn.1400684a0
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
ret
Function at 0x140068b20
Capabilities:
Send data
Send data on socket

Disassembly:
cmp edx, 0x1f
jne 0x140068cc8
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 0x140068b85
lea rax, [rsi + 1]
mov byte [rsi], 0xff
mov qword [rbx], rax
cmp rax, rbx
jae 0x140068b85
mov byte [rax], 0xfa
inc qword [rbx]
mov rax, qword [rbx]
cmp rax, rbx
jae 0x140068b85
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 0x140068bbc
mov byte [r9], r15b
inc qword [rbx]
mov r9, qword [rbx]
mov r15, qword [rsp + 0x58]
cmp r9, rbx
jae 0x140068c12
movzx eax, byte [rsp + 0x49]
mov byte [r9], al
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x140068c12
mov byte [r9], cl
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x140068c12
shr cx, 8
mov byte [r9], cl
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x140068c12
mov byte [r9], 0xff
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x140068c12
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.1400685d0
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 0x140068c74
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Sending_data_failed___d_
mov rcx, rbp
mov r8d, eax
call fcn.140035330
lea rdx, [rdi + 0x1cbb]
mov r8d, 4
mov rcx, r14
call fcn.1400689a0
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 0x140068cc0
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Sending_data_failed___d_
mov rcx, rbp
mov r8d, eax
call fcn.140035330
add rsp, 0x20
pop r14
pop rdi
pop rbp
ret
Function at 0x14006a490
Capabilities:
Receive data
Receive data on socket

Disassembly:
push rsi
push rdi
push r14
sub rsp, 0xd0
mov rax, qword [0x1400a0060]
xor rax, rsp
mov qword [rsp + 0xc0], rax
mov rdi, qword [rcx + 0xa00]
lea rax, [rsp + 0x30]
mov rsi, 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 [rdi + 0x15c]
mov rdx, qword [rdi + 0x168]
add r8d, 4
mov rcx, qword [rdi + 0x18]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_recvfrom]
cmp dword [rdi + 0x150], 0
mov dword [rdi + 0x154], eax
jne 0x14006a525
movsxd r8, dword [rsp + 0x30]
lea rcx, [rdi + 0xd0]
lea rdx, [rsp + 0x40]
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [rsp + 0x30]
mov dword [rdi + 0x150], eax
mov r8d, dword [rdi + 0x154]
mov qword [rsp + 0xf8], rbx
mov qword [rsp + 0x100], rbp
cmp r8d, 4
jge 0x14006a586
lea rdx, str.Received_too_short_packet
mov rcx, rsi
call fcn.140035330
mov dword [rdi + 0xc], 7
xor eax, eax
mov rbp, qword [rsp + 0x100]
mov rbx, qword [rsp + 0xf8]
mov rcx, qword [rsp + 0xc0]
xor rcx, rsp
call fcn.14007dcb0
add rsp, 0xd0
pop r14
pop rdi
pop rsi
ret
mov rdx, qword [rdi + 0x168]
movzx eax, byte [rdx]
movzx ecx, byte [rdx + 1]
shl eax, 8
or ecx, eax
mov dword [rdi + 0xc], ecx
dec ecx
cmp ecx, 5
ja case.0x14006a5bc.1
movsxd rax, ecx
lea r9, [0x140000000]
mov ecx, dword [r9 + rax*4 + 0x6a6d0]
add rcx, r9
jmp rcx
cmp r8d, 4
jle case.0x14006a5bc.4
movzx eax, byte [rdx + 3]
movzx ecx, byte [rdx + 2]
shl ecx, 8
or ecx, eax
movzx eax, word [rdi + 0x48]
inc eax
movzx eax, ax
cmp eax, ecx
jne case.0x14006a5bc.4
lea eax, [r8 - 4]
mov rcx, r14
lea r8, [rdx + 4]
movsxd r9, eax
mov edx, 1
call fcn.140035240
mov ebx, eax
test eax, eax
je 0x14006a618
mov edx, 5
mov rcx, rdi
call fcn.14006b190
mov eax, ebx
jmp 0x14006a55a
mov eax, dword [rdi + 0x154]
mov rcx, rsi
sub eax, 4
cdqe
add qword [rsi + 0xf8], rax
mov rdx, qword [rsi + 0xf8]
call fcn.140053d20
jmp case.0x14006a5bc.4
movzx ecx, byte [rdx + 2]
lea eax, [r8 - 4]
movsxd rbx, eax
lea rbp, [rdx + 4]
movzx eax, byte [rdx + 3]
mov rdx, rbx
shl ecx, 8
or ecx, eax
mov dword [rdi + 8], ecx
mov rcx, rbp
call fcn.14006a0e0
cmp rax, rbx
jae case.0x14006a5bc.4
mov r8, rbp
lea rdx, str.TFTP_error:__s_n
mov rcx, rsi
call fcn.1400354b0
jmp case.0x14006a5bc.4
add r8d, 0xfffffffe
add rdx, 2
mov rcx, rdi
call fcn.14006a1c0
test eax, eax
je case.0x14006a5bc.4
jmp 0x14006a55a
lea r8, str.Internal_error:_Unexpected_packet
mov rcx, rsi
lea rdx, [0x14008a580]
call fcn.140035330
mov rcx, r14
call fcn.140054000
test eax, eax
je 0x14006a558
mov edx, 5
mov rcx, rdi
call fcn.14006b190
mov eax, Ordinal_45
jmp 0x14006a55a
Function at 0x14007d440
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 [section..data]
mov rdi, rax
test rax, rax
jne 0x14007d482
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 0x14007d4c9
call qword [rbx]
mov rcx, qword [rdi + 8]
mov r8d, ebp
mov rdx, r14
call qword [rbx + reloc.OLEAUT32.dll_VariantClear]
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 0x14007d522
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.OLEAUT32.dll_VariantClear]
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.OLEAUT32.dll_VariantClear]
sub rbp, 1
jne 0x14007d4e0
mov eax, dword [rbx + 0x1c]
cmp rsi, rax
jae 0x14007d563
nop word [rax + rax]
mov rcx, qword [rdi + 8]
lea rdx, [0x14008fd0a]
mov r8d, 1
call qword [rbx + reloc.OLEAUT32.dll_VariantClear]
mov rcx, qword [rdi + 0x10]
lea rdx, [0x14008fd0b]
mov r8d, 1
call qword [rbx + reloc.OLEAUT32.dll_VariantClear]
mov eax, dword [rbx + 0x1c]
inc rsi
cmp rsi, rax
jb 0x14007d530
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 0x140002390
Capabilities:
Write file on windows

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rdi, qword [fcn.140026a20]
xor ebx, ebx
mov rbp, rcx
mov rsi, rdx
test rdx, rdx
jle 0x1400023d3
nop
mov r12, qword [rbp + rbx*8]
mov ecx, 1
add rbx, 1
call rdi
xor r8d, r8d
mov rcx, rax
mov rdx, r12
call fcn.140002260
cmp rsi, rbx
jne 0x1400023b0
mov ecx, 1
call rdi
mov r8d, 1
mov edx, 1
lea rcx, [0x14002813c]
mov r9, rax
call sub.msvcrt.dll_fwrite
mov ecx, 1
call rdi
mov rcx, rax
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp sub.msvcrt.dll_fflush

Function at 0x140002490
Capabilities:
Write file on windows

Disassembly:
push r13
push r12
sub rsp, 0x28
xor r8d, r8d
mov r13, rcx
mov r12, rdx
test rdx, rdx
je 0x1400024b1
mov rcx, rdx
call sub.msvcrt.dll_strlen
mov r8, rax
mov rcx, r12
mov r9, r13
mov edx, 1
call sub.msvcrt.dll_fwrite
mov rcx, r13
add rsp, 0x28
pop r12
pop r13
jmp sub.msvcrt.dll_fflush

Function at 0x140002530
Capabilities:
Write file on windows

Disassembly:
push r12
sub rsp, 0x20
mov ecx, 2
call qword [fcn.140026a20]
mov r8d, 0x4b
mov edx, 1
lea rcx, str._GC__cannot_register_thread_local_variable__too_many_thread_local_variables
mov r12, rax
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rcx, r12
call sub.msvcrt.dll_fflush
mov ecx, 1
call sub.msvcrt.dll_exit
nop
nop word cs:[rax + rax]
nop dword [rax]
ret
Function at 0x14001a9d0
Capabilities:
Access peb ldr_data

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x40
lea rsi, [0x14002bfe0]
mov r12, rcx
mov ebp, edx
lea rcx, [0x14002c020]
mov edx, 0x3dc7f5ca
call fcn.140019520
mov edx, 0x2fdd56ae
mov rcx, rax
call fcn.140019d70
mov rax, qword gs:[0x60]
mov rax, qword [rax + 0x18]
mov r13, qword [rax + 0x20]
lea rdi, [rax + 0x20]
nop dword [rax]
movzx eax, word [r12]
mov rdx, r12
test ax, ax
je 0x14001aa50
nop dword [rax]
lea ecx, [rax - 0x41]
cmp cx, 0x19
ja 0x14001abb8
add eax, 0x20
add rdx, 2
mov word [rdx - 2], ax
movzx eax, word [rdx]
test ax, ax
jne 0x14001aa30
mov r10, qword [r13 + 0x50]
movzx ebx, word [r10]
test bx, bx
je 0x14001abda
mov rax, r10
nop dword [rax]
lea edx, [rbx - 0x41]
cmp dx, 0x19
ja 0x14001abe8
add ebx, 0x20
add rax, 2
mov word [rax - 2], bx
movzx ebx, word [rax]
test bx, bx
jne 0x14001aa68
movzx r14d, word [r12]
movzx ebx, word [r10]
test r14w, r14w
je 0x14001aae3
mov eax, r14d
xor ecx, ecx
nop dword [rax]
movzx edx, word [r10 + rcx]
test dx, dx
je 0x14001aae3
lea r9d, [rax - 0x41]
lea r8d, [rax + 0x20]
cmp r9w, 0x1a
lea r9d, [rdx - 0x41]
cmovb eax, r8d
lea r8d, [rdx + 0x20]
cmp r9w, 0x1a
cmovb edx, r8d
cmp ax, dx
jne 0x14001ac00
add rcx, 2
movzx eax, word [r12 + rcx]
test ax, ax
jne 0x14001aaa0
mov edx, 0x510b4a
mov rcx, rsi
call fcn.140019520
mov edx, 0x3455a72e
mov rcx, rax
call fcn.140019d70
cmp bx, r14w
je 0x14001ac1f
mov r13, qword [r13]
cmp rdi, r13
jne 0x14001aa20
test ebp, ebp
je 0x14001ac32
mov edx, 0x4332cc2a
lea rcx, [0x14002bee0]
lea rbx, [rsp + 0x30]
call fcn.140019520
mov edx, 0x6b297dce
mov rcx, rax
call fcn.140019d70
mov rdx, r12
mov rcx, rbx
mov qword [rsp + 0x30], 0
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x28], 0
call qword [0x140071e48]
mov r8, rbx
lea r9, [rsp + 0x28]
xor edx, edx
xor ecx, ecx
call qword [0x140071e20]
mov edx, 0x72f7660e
lea rcx, [0x14002bea0]
mov ebx, eax
call fcn.140019520
mov edx, 0x510b4a
mov rcx, rax
call fcn.140019d70
test ebx, ebx
mov eax, 0
cmove rax, qword [rsp + 0x28]
add rsp, 0x40
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
movzx eax, word [rdx + 2]
add rdx, 2
test ax, ax
jne 0x14001aa30
mov r10, qword [r13 + 0x50]
movzx ebx, word [r10]
test bx, bx
jne 0x14001aa61
movzx r14d, word [r12]
jmp 0x14001aae3
movzx ebx, word [rax + 2]
add rax, 2
test bx, bx
jne 0x14001aa68
jmp 0x14001aa88
mov rcx, rsi
mov edx, 0x510b4a
call fcn.140019520
mov edx, 0x3455a72e
mov rcx, rax
call fcn.140019d70
jmp 0x14001ab07
mov rax, qword [r13 + 0x20]
add rsp, 0x40
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
mov edx, 0x4994c56e
lea rcx, [0x14002bfa0]
call fcn.140019520
mov edx, 0x10d62d6a
mov rcx, rax
call fcn.140019d70
xor eax, eax
add rsp, 0x40
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
Function at 0x140020a50
Capabilities:
Write file on windows

Disassembly:
push r12
push rbx
sub rsp, 0x38
mov r12, 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.140026a20
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call fcn.140026a20
mov rdx, r12
mov rcx, rax
mov r8, rbx
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop word [rax + rax]
Function at 0x140020ac0
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rdi, dword [0x1400722d4]
mov r12, rcx
mov rsi, rdx
mov rbx, r8
test edi, edi
jle 0x140020c70
mov rax, qword [0x1400722d8]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp r12, rdx
jb 0x140020b0c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x140020b97
add ecx, 1
add rax, 0x28
cmp ecx, edi
jne 0x140020af0
mov rcx, r12
call fcn.140021570
mov rbp, rax
test rax, rax
je 0x140020ccd
mov rax, qword [0x1400722d8]
lea rdi, [rdi + rdi*4]
shl rdi, 3
add rax, rdi
mov qword [rax + 0x20], rbp
mov dword [rax], 0
call fcn.1400216a0
mov ecx, dword [rbp + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x1400722d8]
mov qword [rax + rdi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140020cb2
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140020b90
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140020c20
add dword [0x1400722d4], 1
cmp ebx, 8
jae 0x140020bc8
test bl, 4
jne 0x140020c80
test ebx, ebx
je 0x140020bb9
movzx eax, byte [rsi]
mov byte [r12], al
test bl, 2
jne 0x140020ca0
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rax, qword [rsi]
lea rcx, [r12 + 8]
and rcx, 0xfffffffffffffff8
mov qword [r12], rax
mov eax, ebx
mov rdx, qword [rsi + rax - 8]
mov qword [r12 + rax - 8], rdx
sub r12, rcx
add ebx, r12d
sub rsi, r12
and ebx, 0xfffffff8
cmp ebx, 8
jb 0x140020bb9
and ebx, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov r8, qword [rsi + rdx]
mov qword [rcx + rdx], r8
cmp eax, ebx
jb 0x140020bfa
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 4
mov eax, 0x40
cmovne r8d, eax
add rdi, qword [0x1400722d8]
mov qword [rdi + 8], rcx
mov r9, rdi
mov qword [rdi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140020b90
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140020a50
xor edi, edi
jmp 0x140020b17
mov eax, dword [rsi]
mov ebx, ebx
mov dword [r12], eax
mov eax, dword [rsi + rbx - 4]
mov dword [r12 + rbx - 4], eax
jmp 0x140020bb9
mov ebx, ebx
movzx eax, word [rsi + rbx - 2]
mov word [r12 + rbx - 2], ax
jmp 0x140020bb9
mov rax, qword [0x1400722d8]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rdi + 0x18]
call fcn.140020a50
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call fcn.140020a50
nop
nop dword [rax]
Function at 0x1400211e0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x140072340]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140072320]
test rbx, rbx
je 0x140021234
mov rdi, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x14002122b
test r12, r12
je 0x14002122b
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140021210
lea rcx, [0x140072340]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x140021570
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x140057f10]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x1400215e9
mov rcx, r10
call fcn.140021440
test eax, eax
je 0x1400215e9
movsxd rax, dword [r10 + 0x3c]
mov rcx, r9
sub rcx, r10
add r10, rax
movzx eax, word [r10 + 0x14]
lea r8, [r10 + rax + 0x18]
movzx eax, word [r10 + 6]
test eax, eax
je 0x1400215e6
sub eax, 1
lea rax, [rax + rax*4]
lea r9, [r8 + rax*8 + 0x28]
nop dword [rax]
mov edx, dword [r8 + 0xc]
mov rax, rdx
cmp rcx, rdx
jb 0x1400215dd
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x1400215e9
add r8, 0x28
cmp r8, r9
jne 0x1400215c8
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret
Function at 0x140006628
Capabilities:
Get geographical location

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x40
mov rdi, rdx
lea r8, [rsp + 0x60]
mov ebx, ecx
mov edx, 0x20000001
lea rcx, str._x_sys_default_locale
mov r9d, 2
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoEx]
mov r8d, ebx
mov ecx, 0x1300
neg eax
sbb r9d, r9d
and qword [rsp + 0x30], 0
and r9d, dword [rsp + 0x60]
xor edx, edx
and dword [rsp + 0x28], 0
mov dword [rsp + 0x60], r9d
mov qword [rsp + 0x20], rdi
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
mov edx, eax
test eax, eax
je 0x1400066ac
mov r8, qword [rdi]
dec r8
add r8, rdx
movzx ecx, byte [r8]
lea rax, [0x140008530]
cmp byte [rcx + rax], 0
je 0x1400066ac
dec r8
sub rdx, 1
jne 0x140006692
mov rbx, qword [rsp + 0x50]
mov rax, rdx
add rsp, 0x40
pop rdi
ret

Function at 0x140007128
Capabilities:
Parse pe header

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

Function at 0x140001d40
Capabilities:
Write file on windows

Disassembly:
push rsi
sub rsp, 0x30
mov rsi, rcx
mov qword [rsp + 0x48], rdx
mov qword [rsp + 0x50], r8
mov qword [rsp + 0x58], r9
lea rax, [rsp + 0x48]
mov qword [rsp + 0x28], rax
mov ecx, 2
call fcn.140002290
lea rcx, str.Mingw_w64_runtime_failure:_n
mov edx, 0x1b
mov r8d, 1
mov r9, rax
call sub.msvcrt.dll_fwrite
mov ecx, 2
call fcn.140002290
mov r8, qword [rsp + 0x28]
mov rcx, rax
mov rdx, rsi
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
int3

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

Disassembly:
mov rax, qword [0x14000a008]
movzx edx, word [rax]
cmp edx, 0x5a4d
jne 0x14000241c
movsxd rdx, dword [rax + 0x3c]
cmp dword [rax + rdx], 0x4550
jne 0x14000241c
add rax, rdx
movzx edx, word [rax + 0x18]
cmp edx, 0x20b
jne 0x14000241c
movzx edx, word [rax + 6]
test edx, edx
je 0x14000241c
sub rcx, qword [0x14000a008]
movzx r8d, word [rax + 0x14]
add rax, r8
add rax, 0x18
jmp 0x140002408
add rax, 0x28
dec edx
je 0x14000241c
mov r8d, dword [rax + 0xc]
cmp rcx, r8
jb 0x140002400
add r8d, dword [rax + 8]
cmp rcx, r8
jae 0x140002400
jmp 0x14000241e
xor eax, eax
ret

Function at 0x140002420
Capabilities:
Parse pe header

Disassembly:
mov rcx, qword [0x14000a008]
movzx edx, word [rcx]
xor eax, eax
cmp edx, 0x5a4d
jne 0x140002455
movsxd rdx, dword [rcx + 0x3c]
cmp dword [rcx + rdx], 0x4550
jne 0x140002455
movzx r8d, word [rcx + rdx + 0x18]
cmp r8d, 0x20b
jne 0x140002455
movzx eax, word [rcx + rdx + 6]
ret

Function at 0x1400024d0
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x14000a008]
movzx ecx, word [rax]
cmp ecx, 0x5a4d
jne 0x1400024fc
movsxd rcx, dword [rax + 0x3c]
cmp dword [rax + rcx], 0x4550
jne 0x1400024fc
movzx ecx, word [rax + rcx + 0x18]
cmp ecx, 0x20b
je 0x1400024fe
xor eax, eax
ret