joyce8/EMBER2024-capa huggingface dataset:
Function at 0x100021ffb
Capabilities:
Terminate process

Disassembly:
cmp rcx, qword [0x10002e230]
jne 0x10002190a
rol rcx, 0x10
test cx, 0xffff
jne 0x100021906
repz ret
ror rcx, 0x10
jmp 0x100021f54
mov qword [rsp + 8], rcx
sub rsp, 0x88
lea rcx, [0x10002ea20]
call qword [sym.imp.KERNEL32.dll_RtlCaptureContext]
mov rax, qword [0x10002eb18]
mov qword [rsp + 0x58], rax
xor r8d, r8d
lea rdx, [rsp + 0x60]
mov rcx, qword [rsp + 0x58]
call sub.KERNEL32.dll_RtlLookupFunctionEntry
mov qword [rsp + 0x50], rax
cmp qword [rsp + 0x50], 0
je 0x100021fd9
mov qword [rsp + 0x38], 0
lea rax, [rsp + 0x48]
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x28], rax
lea rax, [0x10002ea20]
mov qword [rsp + 0x20], rax
mov r9, qword [rsp + 0x50]
mov r8, qword [rsp + 0x58]
mov rdx, qword [rsp + 0x60]
xor ecx, ecx
call sub.KERNEL32.dll_RtlVirtualUnwind
jmp 0x100021ffb
mov rax, qword [rsp + 0x88]
mov qword [0x10002eb18], rax
lea rax, [rsp + 0x88]
add rax, 8
mov qword [0x10002eab8], rax
mov rax, qword [0x10002eb18]
mov qword [0x10002e990], rax
mov rax, qword [rsp + 0x90]
mov qword [0x10002eaa0], rax
mov dword [0x10002e980], 0xc0000409
mov dword [0x10002e984], 1
mov rax, qword [0x10002e230]
mov qword [rsp + 0x68], rax
mov rax, qword [0x10002e238]
mov qword [rsp + 0x70], rax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
lea rcx, [0x10000cb78]
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, 0x88
ret

Function at 0x100022088
Capabilities:
Print debug messages

Disassembly:
push rbx
sub rsp, 0x530
lea rcx, [rsp + 0x60]
call qword [sym.imp.KERNEL32.dll_RtlCaptureContext]
mov rbx, qword [rsp + 0x158]
lea rdx, [rsp + 0x40]
mov rcx, rbx
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_RtlLookupFunctionEntry]
test rax, rax
je 0x1000220f3
and qword [rsp + 0x38], 0
mov rdx, qword [rsp + 0x40]
lea rcx, [rsp + 0x48]
mov qword [rsp + 0x30], rcx
lea rcx, [rsp + 0x50]
mov r9, rax
mov qword [rsp + 0x28], rcx
lea rcx, [rsp + 0x60]
mov r8, rbx
mov qword [rsp + 0x20], rcx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_RtlVirtualUnwind]
jmp 0x100022113
mov rax, qword [rsp + 0x538]
mov qword [rsp + 0x158], rax
lea rax, [rsp + 0x538]
mov qword [rsp + 0xf8], rax
lea rcx, [0x10000cb88]
call qword [sym.imp.KERNEL32.dll_OutputDebugStringA]
add rsp, 0x530
pop rbx
ret
Function at 0x140001490
Capabilities:
Encrypt data using rc4 prga

Disassembly:
add rcx, 4
jmp fcn.14000ba80
Function at 0x140002090
Capabilities:
Send data
Send data on socket

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
xor r9d, r9d
mov r11d, edx
mov rdi, rcx
mov r10d, r9d
mov ebx, r9d
cmp edx, 2
jb 0x1400015c1
lea eax, [rdx - 2]
mov qword [rsp + 0x10], rsi
shr eax, 1
mov r8, rcx
inc eax
mov edx, eax
lea esi, [rax + rax]
lea rcx, [rax + rax]
mov eax, dword [r8]
lea r8, [r8 + 0x20]
add r9, rax
mov eax, dword [r8 - 0x10]
add r10, rax
sub rdx, 1
jne 0x140001592
cmp esi, r11d
mov rsi, qword [rsp + 0x10]
jb 0x1400015d0
lea rax, [r10 + r9]
add rax, rbx
mov rbx, qword [rsp + 0x18]
pop rdi
ret
test r11d, r11d
je 0x1400015d6
mov rcx, r9
nop dword [rax]
add rcx, rcx
mov ebx, dword [rdi + rcx*8]
lea rax, [r10 + r9]
add rax, rbx
mov rbx, qword [rsp + 0x18]
pop rdi
ret
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0x40
mov eax, dword [rcx + 0x58]
mov ebx, r8d
mov rdi, rdx
test al, 1
je 0x1400020b7
mov eax, 0xfffff00d
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret
bt eax, 0xf
jb 0x1400020cd
mov eax, 0xfffff031
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret
mov eax, dword [rcx + 0x10]
cmp eax, 7
je 0x14000218b
cmp eax, 0xc
je 0x140002135
cmp eax, 0xe
je 0x1400020f3
mov eax, 0xfffff02a
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret
cmp dword [rcx + 0x100], 0
ja 0x14000218b
lea r9, [rsp + 0x50]
call fcn.1400046f0
test eax, eax
je 0x140002121
mov ecx, dword [rsp + 0x50]
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
jmp fcn.14000e890
mov edx, ebx
mov rcx, rdi
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
jmp 0x140001560
cmp dword [rcx + 0x100], 0
ja 0x14000218b
mov rcx, qword [rcx + 0x110]
lea r9, [rsp + 0x50]
xor eax, eax
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], eax
call qword [sym.imp.WS2_32.dll_WSASend]
cmp eax, 0xffffffff
jne 0x14000217c
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
jmp fcn.14000e890
mov eax, dword [rsp + 0x50]
mov rbx, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret
mov rbx, qword [rsp + 0x58]
mov eax, 0xfffff008
add rsp, 0x40
pop rdi
ret
Function at 0x140003b00
Capabilities:
Log keystrokes
Manipulate console buffer

Disassembly:
push rbx
sub rsp, 0x90
mov rax, qword [0x1400b5528]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov rbx, rcx
mov ecx, dword [rcx + 0x58]
btr ecx, 0xc
mov eax, ecx
sub dword [rbx + 0x7c], 1
mov dword [rbx + 0x58], ecx
jne 0x140003b4b
test cl, 1
jne 0x140003b4b
test cl, 4
je 0x140003b4b
and eax, 0xfffffffb
mov dword [rbx + 0x58], eax
test al, 8
je 0x140003b4b
mov rax, qword [rbx + 8]
dec dword [rax + 8]
mov eax, dword [rbx + 0x58]
mov qword [rsp + 0xb0], rsi
mov qword [rsp + 0x88], rdi
bt eax, 0x10
jae 0x140003cf2
bt eax, 0x19
jae 0x140003bb1
mov rcx, qword [rbx + 0x110]
lea r9, [rsp + 0x40]
xor eax, eax
lea rdx, [rsp + 0x60]
mov dword [rsp + 0x70], eax
xorps xmm0, xmm0
mov eax, select
movups xmmword [rsp + 0x60], xmm0
mov word [rsp + 0x60], ax
lea r8d, [rax - 0xf]
call qword [sym.imp.KERNEL32.DLL_WriteConsoleInputW]
test eax, eax
jne 0x140003cf2
call qword [sym.imp.KERNEL32.DLL_GetLastError]
jmp 0x140003cf4
bt eax, 0x15
jb 0x140003cf2
mov rcx, qword [0x1400b8010]
mov edx, 0xffffffff
xor edi, edi
call qword [sym.imp.KERNEL32.DLL_WaitForSingleObject]
test eax, eax
jne 0x140003bfe
mov eax, 2
xchg dword [0x1400b7ff0], eax
cmp eax, 1
je 0x140003c05
mov rcx, qword [0x1400b8010]
lea edx, [rdi + 1]
xor r8d, r8d
call qword [sym.imp.KERNEL32.DLL_ReleaseSemaphore]
test eax, eax
jne 0x140003ceb
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_abort]
int3
xor r9d, r9d
mov qword [rsp + 0x30], rdi
mov qword [rsp + 0xa8], rbp
lea rcx, str.conout_
mov dword [rsp + 0x28], 0x80
mov edx, 0xc0000000
mov qword [rsp + 0x80], r14
lea r8d, [r9 + 3]
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.DLL_CreateFileA]
mov rbp, rax
cmp rax, 0xffffffffffffffff
je 0x140003c68
lea rdx, [0x1400b7ff8]
mov rcx, rax
call qword [sym.imp.KERNEL32.DLL_GetConsoleScreenBufferInfo]
test eax, eax
je 0x140003c68
lock or dword [0x1400b7ff4], 1
mov esi, 1
mov dword [rsp + 0x50], 0xd0001
mov r14d, select
mov word [rsp + 0x48], si
mov ecx, r14d
mov dword [rsp + 0x4c], esi
xor edx, edx
call qword [sym.imp.USER32.dll_MapVirtualKeyW]
mov rcx, qword [rbx + 0x110]
lea r9, [rsp + 0x44]
mov r8d, esi
mov word [rsp + 0x54], ax
lea rdx, [rsp + 0x48]
mov word [rsp + 0x56], r14w
mov dword [rsp + 0x58], edi
call qword [sym.imp.KERNEL32.DLL_WriteConsoleInputW]
mov r14, qword [rsp + 0x80]
test eax, eax
jne 0x140003ccc
call qword [sym.imp.KERNEL32.DLL_GetLastError]
mov edi, eax
cmp rbp, 0xffffffffffffffff
je 0x140003cdb
mov rcx, rbp
call qword [sym.imp.KERNEL32.DLL_CloseHandle]
mov rbp, qword [rsp + 0xa8]
test edi, edi
je 0x140003ceb
mov eax, edi
jmp 0x140003cf4
or dword [rbx + 0x58], 0x200000
xor eax, eax
mov rdi, qword [rsp + 0x88]
mov rsi, qword [rsp + 0xb0]
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.140099bf0
add rsp, 0x90
pop rbx
ret
Function at 0x140003d20
Capabilities:
Manipulate console buffer

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r14
sub rsp, 0x60
mov rax, qword [0x1400b5528]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov r14, qword [rsp + 0xb8]
mov esi, r9d
movzx ebp, r8b
mov edi, edx
mov rbx, rcx
cmp dword [r14], 0
je 0x140003d5e
mov eax, 0xffffffff
jmp 0x140003e87
mov qword [rsp + 0x58], r12
xor r12d, r12d
mov qword [rsp + 0x50], r15
movzx r15d, byte [rsp + 0xb0]
mov rcx, qword [rbx + 0x110]
lea rdx, [rsp + 0x28]
call qword [sym.imp.KERNEL32.DLL_GetConsoleScreenBufferInfo]
test eax, eax
jne 0x140003d93
call qword [sym.imp.KERNEL32.DLL_GetLastError]
mov dword [r14], eax
movsx eax, word [rsp + 0x34]
mov edx, edi
movsx r8d, word [rsp + 0x38]
movsx r11d, word [rsp + 0x28]
sub r8d, eax
mov eax, dword [0x1400b559c]
inc r8d
movsx r9d, word [rsp + 0x2e]
mov dword [0x1400b55b0], r11d
mov dword [0x1400b55a0], r8d
cmp eax, 0xffffffff
jne 0x140003dd0
mov eax, r9d
jmp 0x140003ddd
mov ecx, r9d
sub ecx, r8d
inc ecx
cmp eax, ecx
cmovl eax, ecx
movsx r10d, word [rsp + 0x2a]
lea ecx, [r8 + rax]
cmp ecx, r10d
jle 0x140003df2
mov eax, r10d
sub eax, r8d
test eax, eax
lea ecx, [r9 + rsi]
cmovs eax, r12d
mov dword [0x1400b559c], eax
test r15b, r15b
jne 0x140003e0a
lea ecx, [rax + rsi]
cmp ecx, eax
jge 0x140003e12
mov ecx, eax
jmp 0x140003e1f
lea r9d, [r8 + rax]
cmp ecx, r9d
jl 0x140003e1f
lea ecx, [r9 - 1]
test bpl, bpl
je 0x140003e2b
movsx edx, word [rsp + 0x2c]
add edx, edi
test edx, edx
jns 0x140003e34
mov edx, r12d
jmp 0x140003e3d
cmp edx, r11d
jl 0x140003e3d
lea edx, [r11 - 1]
mov word [rsp + 0x22], cx
mov rcx, qword [rbx + 0x110]
mov word [rsp + 0x20], dx
mov edx, dword [rsp + 0x20]
call qword [sym.imp.KERNEL32.DLL_SetConsoleCursorPosition]
test eax, eax
jne 0x140003e7b
call qword [sym.imp.KERNEL32.DLL_GetLastError]
cmp eax, 0x57
je 0x140003d74
call qword [sym.imp.KERNEL32.DLL_GetLastError]
mov dword [r14], eax
mov eax, 0xffffffff
jmp 0x140003e7d
xor eax, eax
mov r12, qword [rsp + 0x58]
mov r15, qword [rsp + 0x50]
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.140099bf0
add rsp, 0x60
pop r14
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x140006a90
Capabilities:
Get common file path

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x260
mov rax, qword [0x1400b5528]
xor rax, rsp
mov qword [rsp + 0x250], rax
mov rbx, rdx
mov rdi, rcx
test rcx, rcx
je 0x140006c0c
test rdx, rdx
je 0x140006c0c
lea rdx, [rsp + 0x40]
mov ecx, 0x104
call qword [sym.imp.KERNEL32.DLL_GetCurrentDirectoryW]
mov edx, eax
test eax, eax
jne 0x140006aef
call qword [sym.imp.KERNEL32.DLL_GetLastError]
mov ecx, eax
call fcn.14000e890
jmp 0x140006b96
cmp edx, 0x104
jbe 0x140006b01
mov eax, 0xfffff01a
jmp 0x140006b96
mov rax, rdx
mov qword [rsp + 0x280], rsi
add rax, rax
cmp rax, 0x208
jae 0x140006c13
xor esi, esi
lea ecx, [rdx - 1]
add rcx, rcx
mov word [rsp + rax + 0x40], si
cmp word [rsp + rcx + 0x40], 0x5c
jne 0x140006b4f
cmp edx, 3
jne 0x140006b3d
cmp word [rsp + 0x42], 0x3a
je 0x140006b4f
cmp rcx, 0x208
jae 0x140006c13
mov word [rsp + rcx + 0x40], si
mov qword [rsp + 0x38], rsi
lea r8, [rsp + 0x40]
mov qword [rsp + 0x30], rsi
mov r9d, 0xffffffff
mov dword [rsp + 0x28], esi
xor edx, edx
mov ecx, 0xfde9
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.DLL_WideCharToMultiByte]
test eax, eax
je 0x140006bf1
mov ecx, dword [rbx]
cmp eax, ecx
jle 0x140006bb7
cdqe
mov qword [rbx], rax
mov eax, 0xfffff024
mov rsi, qword [rsp + 0x280]
mov rcx, qword [rsp + 0x250]
xor rcx, rsp
call fcn.140099bf0
mov rbx, qword [rsp + 0x288]
add rsp, 0x260
pop rdi
ret
mov eax, 0x7fffffff
mov qword [rsp + 0x38], rsi
cmp qword [rbx], rax
lea r8, [rsp + 0x40]
mov qword [rsp + 0x30], rsi
mov r9d, 0xffffffff
cmova ecx, eax
xor edx, edx
mov dword [rsp + 0x28], ecx
mov ecx, 0xfde9
mov qword [rsp + 0x20], rdi
call qword [sym.imp.KERNEL32.DLL_WideCharToMultiByte]
test eax, eax
jne 0x140006c00
call qword [sym.imp.KERNEL32.DLL_GetLastError]
mov ecx, eax
call fcn.14000e890
jmp 0x140006b8e
dec eax
movsxd rcx, eax
xor eax, eax
mov qword [rbx], rcx
jmp 0x140006b8e
mov eax, 0xfffff019
jmp 0x140006b96
call fcn.14009a454
int3
Function at 0x1400078e0
Capabilities:
Resolve dns

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rdx, qword [rcx + 0x40]
lea r9, [rcx + 0x48]
mov r8, qword [r9]
mov rdi, rcx
mov rcx, qword [rcx + 0x38]
xor ebx, ebx
mov qword [r9], rbx
call qword [sym.imp.WS2_32.dll_GetAddrInfoW]
cmp eax, 0x273f
jg 0x140007978
je 0x140007965
mov ecx, eax
test eax, eax
je 0x1400079e9
sub ecx, 8
je 0x140007952
sub ecx, 0x271e
je 0x14000793f
cmp ecx, 0x16
jne 0x140007994
mov ebx, 0xfffff43d
mov dword [rdi + 0x58], ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov ebx, 0xfffff446
mov dword [rdi + 0x58], ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov ebx, 0xfffff442
mov dword [rdi + 0x58], ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov ebx, 0xfffff443
mov dword [rdi + 0x58], ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov ecx, eax
sub ecx, 0x277d
je 0x1400079e4
sub ecx, 0x37c
je 0x1400079d1
sub ecx, 1
je 0x1400079be
cmp ecx, 1
je 0x1400079ab
mov ecx, eax
call fcn.14000e890
mov ebx, eax
mov dword [rdi + 0x58], eax
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov ebx, 0xfffff444
mov dword [rdi + 0x58], ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov ebx, 0xfffff447
mov dword [rdi + 0x58], ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov ebx, 0xfffff440
mov dword [rdi + 0x58], ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov ebx, 0xfffff43e
mov dword [rdi + 0x58], ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x1400080a0
Capabilities:
Set socket configuration

Disassembly:
push rbx
sub rsp, 0x40
mov rbx, rdx
mov dword [rsp + 0x38], 0x3c
mov rcx, rbx
mov dword [rsp + 0x30], 1
lea r9, [rsp + 0x30]
mov dword [rsp + 0x20], 4
mov edx, 0xffff
mov r8d, 8
call qword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
jne 0x1400080eb
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
add rsp, 0x40
pop rbx
ret
cmp dword [rsp + 0x30], 0
je 0x140008116
mov edx, 6
mov dword [rsp + 0x20], 4
lea r9, [rsp + 0x38]
mov rcx, rbx
lea r8d, [rdx - 3]
call qword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
je 0x1400080df
xor eax, eax
add rsp, 0x40
pop rbx
ret
Function at 0x140008120
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x30
cmp qword [rdx + 0x110], 0xffffffffffffffff
mov esi, r9d
mov rdi, r8
mov dword [rsp + 0x60], 1
mov rbx, rdx
mov rbp, rcx
je 0x14000815c
mov eax, 0xfffff00e
jmp 0x140008252
lea r8, [rsp + 0x60]
mov edx, 0x8004667e
mov rcx, rdi
call qword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
jne 0x14000817f
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x140008252
xor r8d, r8d
mov rcx, rdi
lea edx, [r8 + 1]
call qword [sym.imp.KERNEL32.DLL_SetHandleInformation]
test eax, eax
jne 0x14000819e
call qword [sym.imp.KERNEL32.DLL_GetLastError]
jmp 0x140008252
mov rdx, qword [rbp + 0x38]
xor r9d, r9d
mov r8, rdi
mov rcx, rdi
call qword [sym.imp.KERNEL32.DLL_CreateIoCompletionPort]
test rax, rax
je 0x140008193
mov ecx, dword [0x140341340]
cmp esi, 0x17
mov eax, dword [rbx + 0x58]
cmove ecx, dword [0x14034133c]
bt eax, 0x13
jb 0x1400081ec
test ecx, ecx
jne 0x1400081ec
mov dl, 3
mov rcx, rdi
call qword [sym.imp.KERNEL32.DLL_SetFileCompletionNotificationModes]
test eax, eax
je 0x140008193
or dword [rbx + 0x58], 0x20000
mov eax, dword [rbx + 0x58]
bt eax, 0x18
jae 0x140008228
mov edx, 6
mov dword [rsp + 0x48], 1
lea r9, [rsp + 0x48]
mov dword [rsp + 0x20], 4
mov rcx, rdi
lea r8d, [rdx - 5]
call qword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
jne 0x140008228
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
jne 0x140008252
test dword [rbx + 0x58], 0x2000000
je 0x14000823d
mov rdx, rdi
call fcn.1400080a0
test eax, eax
jne 0x140008252
mov qword [rbx + 0x110], rdi
cmp esi, 0x17
jne 0x140008250
or dword [rbx + 0x58], 0x400000
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x30
pop rdi
ret

Function at 0x140008590
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov dword [rsp + 0x20], r9d
push rsi
push rdi
push r14
sub rsp, 0x30
cmp qword [rcx + 0x110], 0xffffffffffffffff
mov r14d, r8d
mov rdi, rdx
mov rbx, rcx
jne 0x140008604
movzx ecx, word [rdx]
xor r8d, r8d
lea edx, [r8 + 1]
call qword [sym.imp.WS2_32.dll_socket]
mov rsi, rax
cmp rax, 0xffffffffffffffff
jne 0x1400085de
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x140008669
movzx r9d, word [rdi]
mov r8, rsi
mov rcx, qword [rbx + 8]
mov rdx, rbx
call fcn.140008120
mov ebp, eax
test eax, eax
je 0x140008604
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
mov eax, ebp
jmp 0x140008669
cmp word [rdi], 0x17
jne 0x140008635
mov rcx, qword [rbx + 0x110]
lea r9, [rsp + 0x68]
mov edx, 0x29
mov dword [rsp + 0x68], 0
mov dword [rsp + 0x20], 4
lea r8d, [rdx - 0xe]
call qword [sym.imp.WS2_32.dll_setsockopt]
mov rcx, qword [rbx + 0x110]
mov r8d, r14d
mov rdx, rdi
call qword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
jne 0x140008660
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2740
jne 0x140008669
mov dword [rbx + 0x118], eax
or dword [rbx + 0x58], 0x2000
xor eax, eax
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
add rsp, 0x30
pop r14
pop rdi
pop rsi
ret
Function at 0x1400089a0
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r14
sub rsp, 0x50
xorps xmm0, xmm0
lea rbx, [rdx + 0x80]
movups xmmword [rbx + 0x40], xmm0
lea r14, [rbx + 0x40]
xor ebp, ebp
movups xmmword [r14 + 0x10], xmm0
or dword [rdx + 0x58], 0x40000
lea rax, [0x1400b800e]
movups xmmword [r14], xmm0
mov rdi, rdx
mov rsi, rcx
movups xmmword [r14 + 0x10], xmm0
test dword [rdx + 0x58], 0x80000
mov qword [rsp + 0x48], rax
mov dword [rsp + 0x40], ebp
je 0x140008a06
mov rax, qword [rbx + 0x70]
or rax, 1
mov qword [rbx + 0x58], rax
mov rcx, qword [rdi + 0x110]
lea rax, [rsp + 0x70]
mov qword [rsp + 0x30], rbp
lea r9, [rsp + 0x78]
mov qword [rsp + 0x28], r14
lea rdx, [rsp + 0x40]
mov r8d, 1
mov qword [rsp + 0x20], rax
mov dword [rsp + 0x70], ebp
call qword [sym.imp.WS2_32.dll_WSARecv]
test eax, eax
jne 0x140008a91
mov eax, dword [rdi + 0x58]
bt eax, 0x11
jae 0x140008af9
bts eax, 0x10
mov dword [rdi + 0x58], eax
mov eax, dword [rsp + 0x78]
mov qword [rbx + 0x48], rax
inc dword [rdi + 0x78]
mov qword [rbx + 0x68], rbp
mov rax, qword [rsi + 0x48]
test rax, rax
je 0x140008a84
mov rax, qword [rax + 0x68]
mov qword [rbx + 0x68], rax
mov rax, qword [rsi + 0x48]
mov qword [rax + 0x68], rbx
mov qword [rsi + 0x48], rbx
jmp 0x140008b6f
mov qword [rbx + 0x68], rbx
mov qword [rsi + 0x48], rbx
jmp 0x140008b6f
call qword [sym.imp.KERNEL32.DLL_GetLastError]
cmp eax, 0x3e5
je 0x140008af9
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
jg 0x140008ab0
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x140008abe
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
movzx eax, ax
or eax, 0x80070000
cdqe
mov qword [r14], rax
mov qword [rbx + 0x68], rbp
mov rax, qword [rsi + 0x48]
test rax, rax
je 0x140008aec
mov rax, qword [rax + 0x68]
mov qword [rbx + 0x68], rax
mov rax, qword [rsi + 0x48]
mov qword [rax + 0x68], rbx
mov qword [rsi + 0x48], rbx
inc dword [rdi + 0x78]
jmp 0x140008b6f
mov qword [rbx + 0x68], rbx
mov qword [rsi + 0x48], rbx
inc dword [rdi + 0x78]
jmp 0x140008b6f
or dword [rdi + 0x58], 0x10000
inc dword [rdi + 0x78]
test dword [rdi + 0x58], 0x80000
je 0x140008b6f
cmp qword [rbx + 0x78], 0xffffffffffffffff
lea rcx, [rbx + 0x78]
jne 0x140008b6f
mov rdx, qword [rbx + 0x70]
lea r8, [0x140008680]
mov dword [rsp + 0x28], 4
mov r9, rbx
mov dword [rsp + 0x20], 0xffffffff
call qword [sym.imp.KERNEL32.DLL_RegisterWaitForSingleObject]
test eax, eax
jne 0x140008b6f
call qword [sym.imp.KERNEL32.DLL_GetLastError]
test eax, eax
jg 0x140008b51
call qword [sym.imp.KERNEL32.DLL_GetLastError]
jmp 0x140008b5f
call qword [sym.imp.KERNEL32.DLL_GetLastError]
movzx eax, ax
or eax, 0x80070000
cdqe
mov rdx, rbx
mov rcx, rsi
mov qword [r14], rax
call fcn.140008070
lea r11, [rsp + 0x50]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
Function at 0x1400092a0
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x30
mov rsi, rcx
mov rdi, r8
mov rcx, qword [r8 + 0x70]
mov rbx, rdx
cmp rcx, 0xffffffffffffffff
jne 0x14000931f
mov eax, dword [rdx + 0x58]
test al, 0x40
je 0x140009397
mov edx, eax
and edx, 0xffffffbf
sub dword [rbx + 0x7c], 1
mov dword [rbx + 0x58], edx
jne 0x1400092f5
test dl, 1
jne 0x1400092f5
test al, 4
je 0x1400092f5
and eax, 0xffffffbb
mov dword [rbx + 0x58], eax
test al, 8
je 0x1400092f5
mov rax, qword [rbx + 8]
dec dword [rax + 8]
mov r9, qword [rbx + 0x100]
test r9, r9
je 0x140009397
mov ecx, dword [r8 + 0x40]
call fcn.14000fee0
mov ecx, eax
call fcn.14000e890
mov edx, eax
mov rcx, rbx
call r9
jmp 0x140009397
cmp dword [r8 + 0x40], 0
jl 0x140009374
lea r9, [rdx + 0x110]
mov dword [rsp + 0x20], 8
mov edx, 0xffff
mov r8d, 0x700b
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jne 0x140009374
mov rax, qword [rbx + 0x130]
mov qword [rdi + 0x1a8], rax
mov rax, qword [rbx + 0x100]
mov qword [rbx + 0x130], rdi
test rax, rax
je 0x140009397
xor edx, edx
mov rcx, rbx
call rax
jmp 0x140009397
mov rcx, qword [rdi + 0x70]
call qword [sym.imp.WS2_32.dll_closesocket]
mov qword [rdi + 0x70], 0xffffffffffffffff
test byte [rbx + 0x58], 0x40
je 0x140009397
mov rdx, rdi
mov rcx, rbx
call fcn.1400086c0
mov ecx, dword [rbx + 0x78]
mov eax, dword [rbx + 0x58]
dec ecx
mov dword [rbx + 0x78], ecx
test al, 1
je 0x1400093c0
test ecx, ecx
jne 0x1400093c0
test al, 0x20
jne 0x1400093c0
or eax, 0x20
mov dword [rbx + 0x58], eax
mov rax, qword [rsi + 0x50]
mov qword [rbx + 0x50], rax
mov qword [rsi + 0x50], rbx
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret

Function at 0x1400093d0
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0x30
mov rbx, rcx
mov edi, edx
mov rcx, qword [rcx + 0x110]
cmp rcx, 0xffffffffffffffff
je 0x14000941b
mov dword [rsp + 0x40], edx
lea r9, [rsp + 0x40]
mov edx, 6
mov dword [rsp + 0x20], 4
lea r8d, [rdx - 5]
call qword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
jne 0x14000941b
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
jne 0x140009432
mov ecx, dword [rbx + 0x58]
mov eax, ecx
btr eax, 0x18
bts ecx, 0x18
test edi, edi
cmove ecx, eax
xor eax, eax
mov dword [rbx + 0x58], ecx
mov rbx, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret