joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140001390
Capabilities:
Create process on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
lea rbp, [rsp - 0x800]
sub rsp, 0x900
mov rdx, qword [str.WD2_SplashProcess]
and qword [rbp + 0x820], 0
lea rcx, [rbp + 0x820]
call fcn.140001050
test al, al
jne 0x14000153f
mov r8, qword [str.WD2_SplashCreate]
mov edx, 1
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateMutexW]
xor edx, edx
lea rcx, [rsp + 0x70]
lea r8d, [rdx + 0x68]
mov qword [0x140005020], rax
call sub.MSVCR110.dll_memset
xor edx, edx
lea rcx, [rsp + 0x50]
lea r8d, [rdx + 0x18]
call sub.MSVCR110.dll_memset
mov ebx, 0x208
lea rcx, [rbp + 0x3e0]
mov r8d, ebx
xor edx, edx
call sub.MSVCR110.dll_memset
lea rcx, [rbp - 0x20]
xor edx, edx
mov r8d, 0x400
call sub.MSVCR110.dll_memset
xor eax, eax
lea rcx, [rbp + 0x5f0]
mov r8d, ebx
xor edx, edx
mov dword [rbp + 0x818], eax
mov word [rbp + 0x81c], ax
call sub.MSVCR110.dll_memset
mov ebx, 0x104
lea rdx, [rbp + 0x3e0]
mov r8d, ebx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
and qword [rsp + 0x40], 0
and qword [rsp + 0x38], 0
and qword [rsp + 0x30], 0
and qword [rsp + 0x28], 0
lea r9, [rbp + 0x5f0]
lea rdx, [rbp + 0x818]
lea rcx, [rbp + 0x3e0]
mov r8d, 3
mov qword [rsp + 0x20], rbx
call qword [sym.imp.MSVCR110.dll__wsplitpath_s]
mov ebx, 0x200
lea r8, [0x140003438]
lea rcx, [rbp - 0x20]
mov edx, ebx
call qword [sym.imp.MSVCR110.dll_wcscpy_s]
lea r8, [rbp + 0x818]
lea rcx, [rbp - 0x20]
mov edx, ebx
call qword [sym.imp.MSVCR110.dll_wcscat_s]
lea r8, [rbp + 0x5f0]
lea rcx, [rbp - 0x20]
mov edx, ebx
call qword [sym.imp.MSVCR110.dll_wcscat_s]
lea r8, [0x140003440]
lea rcx, [rbp - 0x20]
mov edx, ebx
call qword [sym.imp.MSVCR110.dll_wcscat_s]
lea r8, [0x140003438]
lea rcx, [rbp - 0x20]
mov edx, ebx
call qword [sym.imp.MSVCR110.dll_wcscat_s]
lea rax, [rsp + 0x50]
lea rdx, [rbp - 0x20]
mov qword [rsp + 0x48], rax
lea rax, [rsp + 0x70]
xor r9d, r9d
mov qword [rsp + 0x40], rax
and qword [rsp + 0x38], 0
and qword [rsp + 0x30], 0
and dword [rsp + 0x28], 0
and dword [rsp + 0x20], 0
xor r8d, r8d
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateProcessW]
mov rbx, qword [rsp + 0x910]
add rsp, 0x900
pop rbp
ret

Function at 0x140001550
Capabilities:
Terminate process

Disassembly:
sub rsp, 0x28
call fcn.1400010fc
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
xor edx, edx
mov rcx, rax
add rsp, 0x28
jmp qword [sym.imp.KERNEL32.dll_TerminateProcess]
Function at 0x1400027b8
Capabilities:
Parse pe header

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

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x70
mov qword [rbp - 0x10], 0
mov dword [rbp - 0x1c], 0x30
mov eax, dword [rbp - 0x1c]
mov rax, qword gs:[rax]
mov qword [rbp - 0x28], rax
mov rax, qword [rbp - 0x28]
mov rax, qword [rax + 8]
mov qword [rbp - 0x18], rax
mov dword [rbp - 4], 0
jmp 0x1400011ac
mov rax, qword [rbp - 0x10]
cmp rax, qword [rbp - 0x18]
jne 0x14000119e
mov dword [rbp - 4], 1
jmp 0x1400011e3
mov ecx, 0x3e8
mov rax, qword [sym.imp.KERNEL32.dll_Sleep]
call rax
mov rax, qword [0x1400054b0]
mov qword [rbp - 0x30], rax
mov rax, qword [rbp - 0x18]
mov qword [rbp - 0x38], rax
mov qword [rbp - 0x40], 0
mov rcx, qword [rbp - 0x38]
mov rax, qword [rbp - 0x40]
mov rdx, qword [rbp - 0x30]
lock cmpxchg qword [rdx], rcx
mov qword [rbp - 0x10], rax
cmp qword [rbp - 0x10], 0
jne 0x14000118b
mov rax, qword [0x1400054c0]
mov eax, dword [rax]
cmp eax, 1
jne 0x1400011fd
mov ecx, 0x1f
call sym._amsg_exit
jmp 0x14000123c
mov rax, qword [0x1400054c0]
mov eax, dword [rax]
test eax, eax
jne 0x140001232
mov rax, qword [0x1400054c0]
mov dword [rax], 1
mov rax, qword [0x140005500]
mov rdx, rax
mov rax, qword [0x1400054f0]
mov rcx, rax
call sym._initterm
jmp 0x14000123c
mov dword [0x140009024], 1
mov rax, qword [0x1400054c0]
mov eax, dword [rax]
cmp eax, 1
jne 0x140001270
mov rax, qword [0x1400054e0]
mov rdx, rax
mov rax, qword [0x1400054d0]
mov rcx, rax
call sym._initterm
mov rax, qword [0x1400054c0]
mov dword [rax], 2
cmp dword [rbp - 4], 0
jne 0x140001294
mov rax, qword [0x1400054b0]
mov qword [rbp - 0x48], rax
mov qword [rbp - 0x50], 0
mov rdx, qword [rbp - 0x50]
mov rax, qword [rbp - 0x48]
xchg qword [rax], rdx
mov rax, qword [0x140005400]
mov rax, qword [rax]
test rax, rax
je 0x1400012bf
mov rax, qword [0x140005400]
mov rax, qword [rax]
mov r8d, 0
mov edx, 2
mov ecx, 0
call rax
call sym._pei386_runtime_relocator
mov rax, qword [sym._gnu_exception_handler]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
call rax
mov rdx, qword [0x1400054a0]
mov qword [rdx], rax
lea rax, [sym.__mingw_invalidParameterHandler]
mov rcx, rax
call sym._set_invalid_parameter_handler
call sym._fpreset
mov eax, dword [0x140009004]
lea rdx, [0x140009008]
mov ecx, eax
call sym.duplicate_ppstrings
call sym.__main
mov rax, qword [0x140005430]
mov rax, qword [rax]
mov rdx, qword [0x140009010]
mov qword [rax], rdx
mov rcx, qword [0x140009010]
mov rdx, qword [0x140009008]
mov eax, dword [0x140009004]
mov r8, rcx
mov ecx, eax
call sym.main
mov dword [0x14000901c], eax
mov eax, dword [0x140009020]
test eax, eax
jne 0x14000135d
mov eax, dword [0x14000901c]
mov ecx, eax
call sym.exit
mov eax, dword [0x140009024]
test eax, eax
jne 0x14000136c
call sym._cexit
mov eax, dword [0x14000901c]
add rsp, 0x70
pop rbp
ret
Function at 0x140001378
Capabilities:
Parse pe header

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov rax, qword [0x140005460]
mov dword [rax], 1
mov rax, qword [0x140005470]
mov dword [rax], 1
mov rax, qword [0x140005480]
mov dword [rax], 1
mov rax, qword [0x140005420]
mov qword [rbp - 8], rax
mov rax, qword [rbp - 8]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x1400013c9
mov eax, 0
jmp 0x140001476
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp - 8]
add rax, rdx
mov qword [rbp - 0x10], rax
mov rax, qword [rbp - 0x10]
mov eax, dword [rax]
cmp eax, 0x4550
je 0x1400013f5
mov eax, 0
jmp 0x140001476
mov rax, qword [rbp - 0x10]
add rax, 0x18
mov qword [rbp - 0x18], rax
mov rax, qword [rbp - 0x18]
movzx eax, word [rax]
movzx eax, ax
cmp eax, 0x10b
je 0x14000141b
cmp eax, 0x20b
je 0x140001442
jmp 0x140001471
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0x5c]
cmp eax, 0xe
ja 0x14000142e
mov eax, 0
jmp 0x140001476
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0xd0]
test eax, eax
setne al
movzx eax, al
jmp 0x140001476
mov rax, qword [rbp - 0x18]
mov qword [rbp - 0x20], rax
mov rax, qword [rbp - 0x20]
mov eax, dword [rax + 0x6c]
cmp eax, 0xe
ja 0x14000145d
mov eax, 0
jmp 0x140001476
mov rax, qword [rbp - 0x20]
mov eax, dword [rax + 0xe0]
test eax, eax
setne al
movzx eax, al
jmp 0x140001476
mov eax, 0
add rsp, 0x20
pop rbp
ret

Function at 0x140001a30
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 sym.__acrt_iob_func
mov r9, rax
mov r8d, 0x1b
mov edx, 1
lea rax, str.Mingw_w64_runtime_failure:_n
mov rcx, rax
call sym.fwrite
mov rbx, qword [rbp - 8]
mov ecx, 2
call sym.__acrt_iob_func
mov rcx, rax
mov rax, qword [rbp + 0x20]
mov r8, rbx
mov rdx, rax
call sym.vfprintf
call sym.abort
nop

Function at 0x140002702
Capabilities:
Get thread local storage value

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov eax, dword [0x140009168]
test eax, eax
je 0x14000279a
lea rax, [0x140009140]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call rax
mov rax, qword [0x140009170]
mov qword [rbp - 8], rax
jmp 0x14000277e
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 0x140002772
cmp qword [rbp - 0x10], 0
je 0x140002772
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 0x140002738
lea rax, [0x140009140]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call rax
jmp 0x14000279b
nop
add rsp, 0x30
pop rbp
ret
Function at 0x1400119f0
Capabilities:
Check if file exists
Delete file
Get file attributes
Move file
Terminate process

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x70
movaps xmmword [rsp + 0x60], xmm6
mov rbx, qword [0x140020c10]
mov rdi, qword [0x140020c30]
lea rsi, [0x1400202e0]
movq xmm0, rsi
mov rcx, qword [rbx]
movq xmm6, rdi
punpcklqdq xmm6, xmm0
test rcx, rcx
je 0x140011a46
mov edx, 0x1388
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
jne 0x140011a70
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, qword [0x140020c20]
cmp byte [rax], 0
jne 0x140011a80
movaps xmm6, xmmword [rsp + 0x60]
add rsp, 0x70
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
mov rcx, qword [rbx]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
jmp 0x140011a3d
mov edx, 0x414
lea r12, [rsp + 0x20]
mov qword [rsp + 0x20], 0
mov rbp, qword [sym.imp.SHELL32.dll_SHFileOperationW]
mov dword [rsp + 0x28], 3
mov rcx, r12
mov ebx, 0x14
mov word [rsp + 0x40], dx
mov dword [rsp + 0x44], 0
mov qword [rsp + 0x48], 0
mov qword [rsp + 0x50], rsi
movaps xmmword [rsp + 0x30], xmm6
call rbp
mov r13, qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov r14, qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x140011b34
test al, 0x10
je 0x140011a52
mov ecx, 0x64
call r14
mov eax, 0x414
mov qword [rsp + 0x50], rsi
mov rcx, r12
mov qword [rsp + 0x20], 0
mov dword [rsp + 0x28], 3
mov word [rsp + 0x40], ax
mov dword [rsp + 0x44], 0
mov qword [rsp + 0x48], 0
movaps xmmword [rsp + 0x30], xmm6
call rbp
sub ebx, 1
je 0x140011a52
mov rcx, rdi
call r13
cmp eax, 0xffffffff
jne 0x140011ae0
jmp 0x140011a52

Function at 0x140015aa0
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.14001c9a0
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.14001c9a0
mov r8, rbx
mov rdx, qword [rbp + 0x20]
mov rcx, rax
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
Function at 0x140016752
Capabilities:
Get thread local storage value

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov eax, dword [0x140036228]
test eax, eax
je 0x1400167ea
lea rax, [0x140036200]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call rax
mov rax, qword [0x140036230]
mov qword [rbp - 8], rax
jmp 0x1400167ce
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 0x1400167c2
cmp qword [rbp - 0x10], 0
je 0x1400167c2
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 0x140016788
lea rax, [0x140036200]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call rax
jmp 0x1400167eb
nop
add rsp, 0x30
pop rbp
ret

Function at 0x1400168f0
Capabilities:
Parse pe header

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov qword [rbp + 0x10], rcx
mov rax, qword [rbp + 0x10]
mov qword [rbp - 8], rax
mov rax, qword [rbp - 8]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x140016918
mov eax, 0
jmp 0x140016966
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp - 8]
add rax, rdx
mov qword [rbp - 0x10], rax
mov rax, qword [rbp - 0x10]
mov eax, dword [rax]
cmp eax, 0x4550
je 0x140016941
mov eax, 0
jmp 0x140016966
mov rax, qword [rbp - 0x10]
add rax, 0x18
mov qword [rbp - 0x18], rax
mov rax, qword [rbp - 0x18]
movzx eax, word [rax]
cmp ax, 0x20b
je 0x140016961
mov eax, 0
jmp 0x140016966
mov eax, 1
add rsp, 0x20
pop rbp
ret

Function at 0x14001696c
Capabilities:
Enumerate pe sections

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
mov rax, qword [rbp + 0x10]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp + 0x10]
add rax, rdx
mov qword [rbp - 0x18], rax
mov dword [rbp - 0xc], 0
mov rax, qword [rbp - 0x18]
movzx eax, word [rax + 0x14]
movzx edx, ax
mov rax, qword [rbp - 0x18]
add rax, rdx
add rax, 0x18
mov qword [rbp - 8], rax
jmp 0x1400169ea
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0xc]
mov eax, eax
cmp qword [rbp + 0x18], rax
jb 0x1400169e1
mov rax, qword [rbp - 8]
mov edx, dword [rax + 0xc]
mov rax, qword [rbp - 8]
mov eax, dword [rax + 8]
add eax, edx
mov eax, eax
cmp qword [rbp + 0x18], rax
jae 0x1400169e1
mov rax, qword [rbp - 8]
jmp 0x1400169ff
add dword [rbp - 0xc], 1
add qword [rbp - 8], 0x28
mov rax, qword [rbp - 0x18]
movzx eax, word [rax + 6]
movzx eax, ax
cmp dword [rbp - 0xc], eax
jb 0x1400169b4
mov eax, 0
add rsp, 0x20
pop rbp
ret
Function at 0x1400128d0
Capabilities:
Hash data using crc32b

Disassembly:
xor r9d, r9d
lea r10, [0x140235ab0]
nop word [rax + rax]
xor eax, eax
test r9b, 1
je 0x1400128ec
bts eax, 7
mov ecx, r9d
shr ecx, 1
test cl, 1
je 0x1400128fa
bts eax, 6
shr ecx, 1
test cl, 1
je 0x140012905
bts eax, 5
shr ecx, 1
test cl, 1
je 0x140012910
bts eax, 4
shr ecx, 1
test cl, 1
je 0x14001291b
bts eax, 3
shr ecx, 1
test cl, 1
je 0x140012926
bts eax, 2
shr ecx, 1
test cl, 1
je 0x140012931
bts eax, 1
test cl, 2
je 0x14001293a
bts eax, 0
shl eax, 0x18
lea ecx, [rax + rax]
mov edx, ecx
xor edx, 0x4c11db7
test eax, eax
cmovns edx, ecx
lea eax, [rdx + rdx]
mov ecx, eax
xor ecx, 0x4c11db7
test edx, edx
cmovns ecx, eax
lea eax, [rcx + rcx]
mov edx, eax
xor edx, 0x4c11db7
test ecx, ecx
cmovns edx, eax
lea eax, [rdx + rdx]
mov ecx, eax
xor ecx, 0x4c11db7
test edx, edx
cmovns ecx, eax
lea eax, [rcx + rcx]
mov edx, eax
xor edx, 0x4c11db7
test ecx, ecx
cmovns edx, eax
lea eax, [rdx + rdx]
mov ecx, eax
xor ecx, 0x4c11db7
test edx, edx
cmovns ecx, eax
lea eax, [rcx + rcx]
mov edx, eax
xor edx, 0x4c11db7
test ecx, ecx
cmovns edx, eax
lea eax, [rdx + rdx]
mov r8d, eax
xor r8d, 0x4c11db7
test edx, edx
cmovns r8d, eax
xor ecx, ecx
lea edx, [rcx + 0x1e]
test r8b, 1
je 0x1400129d1
lea eax, [rdx + 1]
bts ecx, eax
sar r8d, 1
test r8b, 1
je 0x1400129dd
bts ecx, edx
sar r8d, 1
sub edx, 2
cmp edx, 0xfffffffe
jg 0x1400129c5
mov dword [r10], ecx
inc r9d
add r10, 4
cmp r9d, 0x100
jl 0x1400128e0
mov dword [0x140235aa0], 1
ret
Function at 0x140015830
Capabilities:
Enumerate pe sections

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rdi
push r14
sub rsp, 0x20
cmp dword [r8 + 0x38], 1
mov rdi, r9
mov rbx, r8
mov r14, rdx
mov rbp, rcx
je 0x14001585f
xor eax, eax
jmp 0x140015a17
mov ecx, dword [r9 + 0x10]
mov qword [rsp + 0x30], rsi
call qword [sym.imp.WS2_32.dll_ntohl]
mov esi, eax
lea rax, [rsi - 1]
cmp rax, 0xfe
ja 0x1400159d8
mov ecx, dword [rdi + 0x1c]
call qword [sym.imp.WS2_32.dll_ntohl]
cmp eax, dword [rbx + 0xa4]
jne 0x1400159d8
mov ecx, dword [rdi + 0x20]
call qword [sym.imp.WS2_32.dll_ntohl]
cmp eax, dword [rbx + 0x9c]
jne 0x1400159d8
mov ecx, dword [rdi + 0x24]
call qword [sym.imp.WS2_32.dll_ntohl]
cmp eax, dword [rbx + 0xa0]
jne 0x1400159d8
mov eax, dword [rbx + 0x1c]
cmp dword [rdi + 0x28], eax
jne 0x1400159d8
mov edx, 1
mov r8b, 0xff
mov rcx, rbx
call fcn.140015a30
cmp rsi, qword [rbx + 0x48]
jae 0x1400158e5
mov qword [rbx + 0x48], rsi
movzx ecx, word [rdi + 4]
call qword [sym.imp.WS2_32.dll_ntohs]
mov word [rbx + 0x18], ax
movzx eax, byte [rdi + 6]
mov byte [rbx + 0x21], al
movzx eax, byte [rdi + 7]
mov byte [rbx + 0x20], al
mov ecx, dword [rdi + 8]
call qword [sym.imp.WS2_32.dll_ntohl]
mov ecx, 0x240
mov esi, 0x1000
cmp eax, ecx
jb 0x14001591f
cmp eax, esi
mov ecx, eax
cmova ecx, esi
cmp ecx, dword [rbx + 0xd0]
jae 0x14001592d
mov dword [rbx + 0xd0], ecx
mov ecx, dword [rdi + 0xc]
call qword [sym.imp.WS2_32.dll_ntohl]
cmp eax, esi
jb 0x140015946
mov ecx, 0x10000
mov esi, eax
cmp eax, ecx
cmova esi, ecx
cmp esi, dword [rbx + 0xd4]
jae 0x140015954
mov dword [rbx + 0xd4], esi
mov ecx, dword [rdi + 0x14]
call qword [sym.imp.WS2_32.dll_ntohl]
mov dword [rbx + 0x50], eax
mov ecx, dword [rdi + 0x18]
call qword [sym.imp.WS2_32.dll_ntohl]
mov dword [rbx + 0x54], eax
mov rcx, rbx
mov dword [rbp + 0x24], 1
test r14, r14
je 0x1400159a0
call fcn.140012f40
mov dword [rbx + 0x38], 5
mov dword [r14], 1
mov qword [r14 + 8], rbx
mov eax, dword [rbx + 0x1cc]
mov dword [r14 + 0x14], eax
xor eax, eax
jmp 0x140015a12
xor edi, edi
cmp dword [rbx + 0x38], 1
sete dil
add edi, 3
call fcn.140012f70
cmp dword [rbx + 0x140], 0
mov dword [rbx + 0x38], edi
jne 0x1400159d4
lea rcx, [rbp + 0x48]
mov rdx, rbx
call fcn.1400126f0
mov dword [rbx + 0x140], 1
xor eax, eax
jmp 0x140015a12
xor edi, edi
mov rcx, rbx
mov dword [rbx + 0x1cc], edi
call fcn.140012f70
mov dword [rbx + 0x38], 9
cmp dword [rbx + 0x140], edi
jne 0x140015a0d
lea rcx, [rbp + 0x48]
mov rdx, rbx
call fcn.1400126f0
mov dword [rbx + 0x140], 1
mov eax, 0xffffffff
mov rsi, qword [rsp + 0x30]
mov rbx, qword [rsp + 0x38]
mov rbp, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x48]
add rsp, 0x20
pop r14
ret
Function at 0x1400168f0
Capabilities:
Resolve dns

Disassembly:
push rbx
push r14
sub rsp, 0x58
mov rax, qword [0x14022d988]
xor rax, rsp
mov qword [rsp + 0x30], rax
mov r14, rcx
mov rbx, rdx
mov rcx, rdx
call qword [sym.imp.WS2_32.dll_gethostbyname]
test rax, rax
je 0x140016935
cmp word [rax + 0x10], 2
jne 0x140016935
mov rax, qword [rax + 0x18]
mov rcx, qword [rax]
mov eax, dword [rcx]
mov dword [r14], eax
xor eax, eax
jmp 0x1400169e9
mov qword [rsp + 0x80], rbp
mov qword [rsp + 0x50], rsi
xor esi, esi
mov qword [rsp + 0x48], rdi
mov ebp, esi
mov qword [rsp + 0x40], r15
mov edi, esi
mov dword [rsp + 0x28], 0
lea r15d, [rsi + 0x2e]
nop
lea rdx, [rbx + 1]
mov qword [rsp + 0x20], rdx
cmp byte [rbx], 0x30
je 0x1400169a3
mov r8d, 0xa
lea rdx, [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_strtol]
cmp eax, 0xff
ja 0x1400169cb
mov rdx, qword [rsp + 0x20]
cmp rdx, rbx
je 0x1400169cb
mov rcx, rdx
sub rcx, rbx
cmp rcx, 3
jg 0x1400169cb
mov byte [rsp + rdi + 0x28], al
movsx eax, byte [rdx]
cmp ebp, 3
mov ecx, esi
cmovl ecx, r15d
cmp eax, ecx
jne 0x1400169cb
inc ebp
lea rbx, [rdx + 1]
inc rdi
cmp rdi, 4
jl 0x140016960
mov eax, dword [rsp + 0x28]
mov dword [r14], eax
jmp 0x1400169d0
mov esi, 0xffffffff
mov r15, qword [rsp + 0x40]
mov eax, esi
mov rsi, qword [rsp + 0x50]
mov rdi, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x80]
mov rcx, qword [rsp + 0x30]
xor rcx, rsp
call fcn.140195e90
add rsp, 0x58
pop r14
pop rbx
ret

Function at 0x140016a10
Capabilities:
Initialize winsock library

Disassembly:
sub rsp, 0x1d8
mov rax, qword [0x14022d988]
xor rax, rsp
mov qword [rsp + 0x1c0], rax
mov ecx, 0x101
lea rdx, [rsp + 0x20]
call qword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x140016a79
movzx eax, word [rsp + 0x20]
cmp al, 1
jne 0x140016a73
shr ax, 8
cmp al, 1
jne 0x140016a73
mov ecx, 1
call qword [sym.imp.WINMM.dll_timeBeginPeriod]
xor eax, eax
mov rcx, qword [rsp + 0x1c0]
xor rcx, rsp
call fcn.140195e90
add rsp, 0x1d8
ret
call qword [sym.imp.WS2_32.dll_WSACleanup]
mov eax, 0xffffffff
mov rcx, qword [rsp + 0x1c0]
xor rcx, rsp
call fcn.140195e90
add rsp, 0x1d8
ret

Function at 0x140016b70
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push rbx
sub rsp, 0x40
mov rax, qword [0x14022d988]
xor rax, rsp
mov qword [rsp + 0x38], rax
mov rbx, rdx
mov dword [rsp + 0x20], reloc.WS2_32.dll_recv
lea rdx, [rsp + 0x28]
lea r8, [rsp + 0x20]
call qword [sym.imp.WS2_32.dll_getsockname]
cmp eax, 0xffffffff
jne 0x140016bb8
mov rcx, qword [rsp + 0x38]
xor rcx, rsp
call fcn.140195e90
add rsp, 0x40
pop rbx
ret
mov eax, dword [rsp + 0x2c]
movzx ecx, word [rsp + 0x2a]
mov dword [rbx], eax
call qword [sym.imp.WS2_32.dll_ntohs]
mov word [rbx + 4], ax
xor eax, eax
mov rcx, qword [rsp + 0x38]
xor rcx, rsp
call fcn.140195e90
add rsp, 0x40
pop rbx
ret
Function at 0x140016bf0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push rbx
sub rsp, 0x80
mov rax, qword [0x14022d988]
xor rax, rsp
mov qword [rsp + 0x70], rax
mov r11, r9
mov dword [rsp + 0x54], reloc.WS2_32.dll_recv
mov rbx, rdx
lea r9, [rsp + 0x54]
xor edx, edx
lea rax, [rsp + 0x60]
mov qword [rsp + 0x40], rdx
mov r10, r8
mov qword [rsp + 0x38], rdx
test rbx, rbx
mov dword [rsp + 0x50], edx
mov r8d, r11d
cmove r9, rdx
cmove rax, rdx
mov qword [rsp + 0x30], r9
mov rdx, r10
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x58]
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_WSARecvFrom]
cmp eax, 0xffffffff
jne 0x140016c7e
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
sub eax, 0x2733
je 0x140016c7a
cmp eax, 0x13
jne 0x140016c88
xor eax, eax
jmp 0x140016cad
test dword [rsp + 0x50], 0x8000
je 0x140016c8f
mov eax, 0xffffffff
jmp 0x140016cad
test rbx, rbx
je 0x140016ca9
mov eax, dword [rsp + 0x64]
movzx ecx, word [rsp + 0x62]
mov dword [rbx], eax
call qword [sym.imp.WS2_32.dll_ntohs]
mov word [rbx + 4], ax
mov eax, dword [rsp + 0x58]
mov rcx, qword [rsp + 0x70]
xor rcx, rsp
call fcn.140195e90
add rsp, 0x80
pop rbx
ret

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

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r14
sub rsp, 0x70
mov rax, qword [0x14022d988]
xor rax, rsp
mov qword [rsp + 0x68], rax
xor r14d, r14d
mov rbp, r9
mov rsi, r8
mov rbx, rdx
mov rdi, rcx
test rdx, rdx
je 0x140016d22
movzx ecx, word [rdx + 4]
mov eax, 2
mov word [rsp + 0x58], ax
mov qword [rsp + 0x60], r14
call qword [sym.imp.WS2_32.dll_htons]
mov word [rsp + 0x5a], ax
mov eax, dword [rbx]
mov dword [rsp + 0x5c], eax
mov qword [rsp + 0x40], r14
mov rax, rbx
neg rax
mov qword [rsp + 0x38], r14
lea rax, [rsp + 0x58]
mov r8d, ebp
sbb r9d, r9d
mov rdx, rsi
and r9d, 0x10
mov rcx, rdi
mov dword [rsp + 0x30], r9d
test rbx, rbx
lea r9, [rsp + 0x50]
cmove rax, r14
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], r14d
call qword [sym.imp.WS2_32.dll_WSASendTo]
cmp eax, 0xffffffff
jne 0x140016d7e
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
sub eax, 0x2733
neg eax
sbb eax, eax
jmp 0x140016d82
mov eax, dword [rsp + 0x50]
mov rcx, qword [rsp + 0x68]
xor rcx, rsp
call fcn.140195e90
add rsp, 0x70
pop r14
pop rdi
pop rsi
pop rbp
pop rbx
ret