joyce8/EMBER2024-capa huggingface dataset:
Function at 0x180018540
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov word [rsp + 0x18], r8w
push rbx
sub rsp, 0x20
mov r8d, edx
mov rbx, rcx
mov rdx, rcx
mov rcx, qword [0x1800ae468]
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea rcx, [rsp + 0x40]
mov edx, 1
call qword [sym.imp.USER32.dll_CharLowerBuffW]
cmp word [rsp + 0x40], 0x6d
jne 0x1800185b4
call fcn.1800810b0
mov rcx, rbx
lea rdx, [0x18008b358]
test al, al
jne 0x1800185a5
lea rdx, [0x18008b360]
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
lea rdx, [0x18008b368]
jmp 0x1800185cb
lea rdx, [0x18008b388]
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
lea rdx, str.KuaiZip.exe
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
add rsp, 0x20
pop rbx
ret

Function at 0x180018670
Capabilities:
Check os version

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_GetVersion]
cmp al, 6
setae al
add rsp, 0x28
ret
Function at 0x18001af50
Capabilities:
Read file via mapping

Disassembly:
push rdi
sub rsp, 0x30
xor edx, edx
mov rdi, rcx
lea r8, [0x18008bd10]
lea ecx, [rdx + 6]
call qword [sym.imp.KERNEL32.dll_OpenFileMappingW]
mov qword [rdi + 8], rax
test rax, rax
jne 0x18001af7a
add rsp, 0x30
pop rdi
ret
mov qword [rsp + 0x40], rbx
xor ebx, ebx
xor r9d, r9d
lea edx, [rbx + 6]
xor r8d, r8d
mov rcx, rax
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
test rax, rax
mov qword [rdi + 0x10], rax
setne bl
mov eax, ebx
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
Function at 0x18001c320
Capabilities:
Get file attributes

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
sub rsp, 0x240
mov rax, qword [0x1800ac2b8]
xor rax, rsp
mov qword [rsp + 0x230], rax
mov rsi, rcx
mov rdi, rdx
lea rcx, [rsp + 0x22]
xor ebp, ebp
xor edx, edx
mov r8d, 0x206
mov rbx, r9
mov word [rsp + 0x20], bp
call fcn.18005f790
lea rcx, [rsp + 0x20]
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
cmp bp, word [rsp + 0x20]
jne 0x18001c38a
lea rdx, [0x18008c860]
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
cmp dword [rsi + 0x32c], ebp
je 0x18001c3cc
lea rcx, str.Archive
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov rbx, rax
test rax, rax
jne 0x18001c3b2
mov ecx, 0x8007000e
call fcn.180002fb0
int3
mov rdx, rax
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
mov rcx, rbx
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
jmp 0x18001c4fb
lea rbx, [rsi + 0x60]
movabs r8, 0x6666666666666667
mov rcx, qword [rbx + 0x20]
mov rax, r8
sub rcx, qword [rbx + 0x18]
imul rcx
sar rdx, 4
mov rax, rdx
shr rax, 0x3f
add rdx, rax
cmp rdx, 1
jbe 0x18001c4a1
cmp qword [rsi + 0x28], 8
jb 0x18001c40d
mov rcx, qword [rsi + 0x10]
jmp 0x18001c411
lea rcx, [rsi + 0x10]
call qword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
cmp qword [rsi + 0x28], 8
jb 0x18001c424
mov rsi, qword [rsi + 0x10]
jmp 0x18001c428
add rsi, 0x10
cmp rax, rsi
jne 0x18001c48a
xor edx, edx
mov rcx, rbx
call fcn.180022c00
cmp qword [rax + 0x20], 8
jb 0x18001c444
mov rdx, qword [rax + 8]
jmp 0x18001c448
lea rdx, [rax + 8]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
xor edx, edx
mov rcx, rbx
call fcn.180022c00
cmp qword [rax + 0x20], 8
jb 0x18001c468
mov rcx, qword [rax + 8]
jmp 0x18001c46c
lea rcx, [rax + 8]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 0x10
jne 0x18001c4fb
mov rcx, rdi
call qword [sym.imp.SHLWAPI.dll_PathFindExtensionW]
test rax, rax
je 0x18001c4fb
jmp 0x18001c4f8
mov rdx, rax
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
mov rcx, rdi
call qword [sym.imp.SHLWAPI.dll_PathRemoveBackslashW]
jmp 0x18001c4fb
mov rcx, qword [rbx + 0x20]
mov rax, r8
sub rcx, qword [rbx + 0x18]
imul rcx
sar rdx, 4
mov rax, rdx
shr rax, 0x3f
add rdx, rax
jne 0x18001c4c4
call fcn.1800610c8
mov rax, qword [rbx + 0x18]
cmp qword [rax + 0x20], 8
jb 0x18001c4d5
mov rdx, qword [rax + 8]
jmp 0x18001c4d9
lea rdx, [rax + 8]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 0x10
jne 0x18001c4fb
mov rcx, rdi
call qword [sym.imp.SHLWAPI.dll_PathFindExtensionW]
mov word [rax], bp
lea rdx, [rsp + 0x20]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_lstrcatW]
mov eax, 1
mov rcx, qword [rsp + 0x230]
xor rcx, rsp
call fcn.18005f4d0
mov rbx, qword [rsp + 0x270]
add rsp, 0x240
pop rdi
pop rsi
pop rbp
ret
Function at 0x180024940
Capabilities:
Query or enumerate registry value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov dword [rsp + 0x20], r9d
push rdi
sub rsp, 0x40
mov rsi, r8
mov rbx, rdx
mov rdi, rcx
mov r8d, r9d
xor edx, edx
mov rcx, rsi
call fcn.18005f790
mov rcx, qword [rdi]
lea r11, [rsp + 0x68]
mov qword [rsp + 0x28], r11
lea r9, [rsp + 0x30]
xor r8d, r8d
mov rdx, rbx
mov qword [rsp + 0x20], rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movsxd rbx, eax
test eax, eax
je 0x1800249b1
mov edx, dword [rsp + 0x78]
mov ecx, dword [rsp + 0x68]
cmp ecx, edx
cmovb edx, ecx
mov rcx, rsi
mov r8d, edx
mov rdx, qword [rsp + 0x70]
call fcn.180061260
mov rsi, qword [rsp + 0x58]
mov rax, rbx
mov rbx, qword [rsp + 0x50]
add rsp, 0x40
pop rdi
ret

Function at 0x1800249d0
Capabilities:
Query or enumerate registry value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov dword [rsp + 0x20], r9d
push rdi
sub rsp, 0x40
mov rbx, r8
mov rdi, rdx
mov rsi, rcx
mov r8d, r9d
xor edx, edx
mov rcx, rbx
call fcn.18005f790
mov rcx, qword [rsi]
lea r11, [rsp + 0x68]
mov qword [rsp + 0x28], r11
lea r9, [rsp + 0x30]
xor r8d, r8d
mov rdx, rdi
mov qword [rsp + 0x20], rbx
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov rbx, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
cdqe
add rsp, 0x40
pop rdi
ret

Function at 0x180024a40
Capabilities:
Query or enumerate registry value

Disassembly:
mov r11, rsp
mov qword [r11 + 8], rbx
mov qword [r11 + 0x10], rsi
mov dword [r11 + 0x20], r9d
push rdi
sub rsp, 0x40
xor eax, eax
mov rsi, r8
lea r9, [r11 - 0x10]
mov dword [r8], eax
mov rcx, qword [rcx]
lea rax, [r11 - 0x18]
mov qword [r11 - 0x20], rax
mov qword [r11 - 0x28], r8
mov edi, 4
xor r8d, r8d
mov dword [rsp + 0x30], edi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movsxd rbx, eax
test eax, eax
je 0x180024aa1
mov ecx, dword [rsp + 0x30]
lea rdx, [rsp + 0x68]
cmp ecx, edi
cmovb edi, ecx
mov rcx, rsi
mov r8d, edi
call fcn.180061260
mov rsi, qword [rsp + 0x58]
mov rax, rbx
mov rbx, qword [rsp + 0x50]
add rsp, 0x40
pop rdi
ret

Function at 0x180024ac0
Capabilities:
Query or enumerate registry value

Disassembly:
sub rsp, 0x48
mov rcx, qword [rcx]
lea rax, [rsp + 0x68]
lea r9, [rsp + 0x30]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r8
xor r8d, r8d
mov dword [rsp + 0x68], 4
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cdqe
add rsp, 0x48
ret
Function at 0x180025df0
Capabilities:
Query or enumerate registry value

Disassembly:
push rbx
sub rsp, 0x880
mov qword [rsp + 0x68], 0xfffffffffffffffe
mov rax, qword [0x1800ac2b8]
xor rax, rsp
mov qword [rsp + 0x870], rax
xor ebx, ebx
mov word [rsp + 0x70], bx
xor edx, edx
mov r8d, 0x7fe
lea rcx, [rsp + 0x72]
call fcn.18005f790
lea r11, str.Update
mov qword [rsp + 0x20], r11
lea r9, [0x18008d2f8]
lea r8, str.KuaiZip
lea rdx, str.software_s_s_s
lea rcx, [rsp + 0x70]
call qword [sym.imp.USER32.dll_wsprintfW]
lea rcx, [rsp + 0x30]
call fcn.180002030
nop
lea rcx, [rsp + 0x30]
call fcn.18005df08
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, [rsp + 0x70]
mov rcx, 0xffffffff80000001
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x180025ea4
lea rcx, [rsp + 0x30]
call fcn.180002038
lea eax, [rbx + 1]
jmp 0x180025f48
mov dword [rsp + 0x38], ebx
xor eax, eax
mov dword [rsp + 0x3c], eax
mov dword [rsp + 0x40], 8
lea rcx, [rsp + 0x30]
call fcn.18000205c
mov rcx, rax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x38]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x44]
xor r8d, r8d
lea rdx, str.kernel
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea rdx, [rsp + 0x58]
lea rcx, [rsp + 0x38]
call qword [sym.imp.KERNEL32.dll_FileTimeToSystemTime]
lea rcx, [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_GetLocalTime]
movzx r11d, word [rsp + 0x58]
cmp word [rsp + 0x48], r11w
jbe 0x180025f1c
mov ebx, 1
jmp 0x180025f3c
movzx eax, word [rsp + 0x5a]
cmp word [rsp + 0x4a], ax
jbe 0x180025f2f
mov ebx, 1
jmp 0x180025f3c
movzx ecx, word [rsp + 0x5e]
cmp word [rsp + 0x4e], cx
seta bl
lea rcx, [rsp + 0x30]
call fcn.180002038
mov eax, ebx
mov rcx, qword [rsp + 0x870]
xor rcx, rsp
call fcn.18005f4d0
add rsp, 0x880
pop rbx
ret
Function at 0x180026e80
Capabilities:
Get geographical location
Identify system language via api

Disassembly:
mov r11, rsp
sub rsp, 0x78
mov rax, qword [0x1800ac2b8]
xor rax, rsp
mov qword [rsp + 0x60], rax
xor eax, eax
mov word [rsp + 0x20], ax
mov qword [r11 - 0x56], rax
mov qword [r11 - 0x4e], rax
mov qword [r11 - 0x46], rax
mov qword [r11 - 0x3e], rax
mov qword [r11 - 0x36], rax
mov qword [r11 - 0x2e], rax
mov qword [r11 - 0x26], rax
mov dword [rsp + 0x5a], eax
mov word [rsp + 0x5e], ax
call qword [sym.imp.KERNEL32.dll_GetSystemDefaultUILanguage]
lea r8, [rsp + 0x20]
mov r9d, reloc.WLDAP32.dll_Ordinal_32
mov edx, 0x1004
movzx ecx, ax
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
jne 0x180026efd
call qword [sym.imp.KERNEL32.dll_GetACP]
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.18005f4d0
add rsp, 0x78
ret
lea rcx, [rsp + 0x20]
call fcn.180062608
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.18005f4d0
add rsp, 0x78
ret

Function at 0x180028e00
Capabilities:
Initialize winsock library

Disassembly:
sub rsp, 0x1d8
mov rax, qword [0x1800ac2b8]
xor rax, rsp
mov qword [rsp + 0x1c0], rax
lea rdx, [rsp + 0x20]
mov ecx, 0x202
call qword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x180028e5e
movzx eax, word [rsp + 0x20]
cmp al, 2
jne 0x180028e58
shr ax, 8
cmp al, 2
jne 0x180028e58
xor eax, eax
mov rcx, qword [rsp + 0x1c0]
xor rcx, rsp
call fcn.18005f4d0
add rsp, 0x1d8
ret
call qword [sym.imp.WS2_32.dll_WSACleanup]
mov eax, 2
mov rcx, qword [rsp + 0x1c0]
xor rcx, rsp
call fcn.18005f4d0
add rsp, 0x1d8
ret
Function at 0x18002a250
Capabilities:
Encrypt data using rc4 prga

Disassembly:
cmp dword [rcx + 4], 2
mov rax, rdx
je 0x18002a25c
xor eax, eax
ret
mov rdx, qword [rcx + 0x20]
mov r9, r8
mov r8, rax
add rdx, 4
mov ecx, 2
jmp fcn.18003a290

Function at 0x1800336e0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, r9
xor r9d, r9d
call qword [sym.imp.WS2_32.dll_recv]
movsxd rcx, eax
cmp rcx, 0xffffffffffffffff
jne 0x18003371b
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, gethostname
mov edx, 0x51
cmp eax, 0x2733
cmove ecx, edx
mov eax, ecx
add rsp, 0x20
pop rbx
ret
mov qword [rbx], rcx
xor eax, eax
add rsp, 0x20
pop rbx
ret

Function at 0x180033890
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x30
mov r10, qword [rcx + 0x268]
mov rdi, r9
mov rsi, r8
mov rbx, rcx
test r10, r10
je 0x1800338d3
mov rax, qword [rcx + 0x1b8]
mov qword [rsp + 0x20], rax
call r10
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
test edx, edx
js 0x18003391a
cmp edx, 2
jg 0x18003391a
mov r9, qword [rbx + 0x1b0]
movsxd rax, edx
mov edx, 2
lea rcx, [rax + rax*2]
lea rax, [0x18008e9b8]
lea r8d, [rdx - 1]
add rcx, rax
call fcn.1800620f8
mov r9, qword [rbx + 0x1b0]
mov r8d, 1
mov rdx, rdi
mov rcx, rsi
call fcn.1800620f8
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
xor eax, eax
add rsp, 0x30
pop rdi
ret

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

Disassembly:
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
movsxd rax, edx
mov r10, r9
mov r11, r8
mov rsi, rcx
mov rcx, qword [rcx + rax*8 + 0x1a8]
xor r9d, r9d
mov r8d, r10d
mov rdx, r11
call qword [sym.imp.WS2_32.dll_send]
mov rbp, qword [rsp + 0x50]
movsxd rdi, eax
mov dword [rbp], 0
cmp rdi, 0xffffffffffffffff
jne 0x180033d9b
mov qword [rsp + 0x30], rbx
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, eax
cmp eax, 0x2733
jne 0x180033d69
mov dword [rbp], 0x51
xor eax, eax
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
mov edx, eax
mov rcx, rsi
call fcn.180039920
mov rcx, qword [rsi]
lea rdx, str.Send_failure:__s
mov r8, rax
call fcn.180033b00
mov r11, qword [rsi]
mov rax, rdi
mov dword [r11 + 0x889c], ebx
mov dword [rbp], gethostname
jmp 0x180033d54
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
mov rax, rdi
add rsp, 0x20
pop rdi
ret
Function at 0x180035f80
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x60
xor esi, esi
mov rdi, rdx
mov rbx, rcx
mov eax, esi
lea r9, [rsp + 0x70]
lea r8d, [rsi + 8]
cmp dword [rcx + 0x6a4], eax
mov edx, 0xffff
mov rcx, rdi
setne al
mov dword [rsp + 0x20], 4
mov dword [rsp + 0x70], eax
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x180035fee
lea rdx, str.Failed_to_set_SO_KEEPALIVE_on_fd__d_n
mov r8, rdi
mov rcx, rbx
call fcn.180033a50
mov rbx, qword [rsp + 0x78]
mov rsi, qword [rsp + 0x88]
add rsp, 0x60
pop rdi
ret
mov ecx, dword [rbx + 0x6a8]
mov dword [rsp + 0x50], 1
call fcn.18004f9e0
mov ecx, dword [rbx + 0x6ac]
imul eax, eax, 0x3e8
mov dword [rsp + 0x70], eax
mov dword [rsp + 0x54], eax
call fcn.18004f9e0
mov qword [rsp + 0x40], rsi
mov qword [rsp + 0x38], rsi
lea r8, [rsp + 0x50]
mov r9d, ntohs
mov edx, 0x98000004
imul eax, eax, 0x3e8
mov dword [rsp + 0x70], eax
mov dword [rsp + 0x58], eax
lea rax, [rsp + 0x80]
mov qword [rsp + 0x30], rax
mov rcx, rdi
mov dword [rsp + 0x28], esi
mov qword [rsp + 0x20], rsi
call qword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x180036080
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Failed_to_set_SIO_KEEPALIVE_VALS_on_fd__d:__d_n
mov r8d, edi
mov r9d, eax
mov rcx, rbx
call fcn.180033a50
mov rbx, qword [rsp + 0x78]
mov rsi, qword [rsp + 0x88]
add rsp, 0x60
pop rdi
ret
Function at 0x1800367f0
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x140
mov rax, qword [0x1800ac2b8]
xor rax, rsp
mov qword [rsp + 0x130], rax
cmp dword [rcx + 0xa4], 2
mov rsi, qword [rcx]
mov rbx, rdx
mov rdi, rcx
je 0x1800369d4
cmp dword [rcx + 0x27c], 0
jne 0x1800369cc
lea r8, [rsp + 0x20]
lea rdx, [rsp + 0xb0]
mov rcx, rbx
mov dword [rsp + 0x20], 0x80
call qword [sym.imp.WS2_32.dll_getpeername]
test eax, eax
je 0x180036885
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, rdi
mov edx, eax
mov ebx, eax
call fcn.180039920
lea rdx, str.getpeername___failed_with_errno__d:__s
mov r8d, ebx
mov r9, rax
mov rcx, rsi
call fcn.180033b00
jmp 0x1800369d4
lea rcx, [rsp + 0x30]
xor edx, edx
mov r8d, 0x80
mov dword [rsp + 0x20], 0x80
call fcn.18005f790
lea r8, [rsp + 0x20]
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x1800368e2
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, rdi
mov edx, eax
mov ebx, eax
call fcn.180039920
lea rdx, str.getsockname___failed_with_errno__d:__s
mov r8d, ebx
mov r9, rax
mov rcx, rsi
call fcn.180033b00
jmp 0x1800369d4
lea r8, [rdi + 0x120]
lea rdx, [rdi + 0xf0]
lea rcx, [rsp + 0xb0]
call fcn.180036770
test eax, eax
jne 0x18003692d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, rdi
mov edx, eax
mov ebx, eax
call fcn.180039920
lea rdx, str.ssrem_inet_ntop___failed_with_errno__d:__s
mov r8d, ebx
mov r9, rax
mov rcx, rsi
call fcn.180033b00
jmp 0x1800369d4
mov rax, qword [rdi + 0xf0]
lea r8, [rdi + 0x154]
lea rdx, [rdi + 0x124]
mov qword [rdi + 0x70], rax
mov rax, qword [rdi + 0xf8]
lea rcx, [rsp + 0x30]
mov qword [rdi + 0x78], rax
mov rax, qword [rdi + 0x100]
mov qword [rdi + 0x80], rax
mov rax, qword [rdi + 0x108]
mov qword [rdi + 0x88], rax
mov rax, qword [rdi + 0x110]
mov qword [rdi + 0x90], rax
mov eax, dword [rdi + 0x118]
mov dword [rdi + 0x98], eax
movzx eax, word [rdi + 0x11c]
mov word [rdi + 0x9c], ax
call fcn.180036770
test eax, eax
jne 0x1800369cc
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, rdi
mov edx, eax
mov ebx, eax
call fcn.180039920
lea rdx, str.ssloc_inet_ntop___failed_with_errno__d:__s
mov r8d, ebx
mov r9, rax
mov rcx, rsi
call fcn.180033b00
jmp 0x1800369d4
mov rcx, rdi
call fcn.180036680
mov rcx, qword [rsp + 0x130]
xor rcx, rsp
call fcn.18005f4d0
lea r11, [rsp + 0x140]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret
Function at 0x180036a00
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0x30
mov rbx, qword [rcx]
mov r10, rdx
mov edx, 6
mov eax, dword [rbx + 0x4d4]
mov rdi, rcx
lea r9, [rsp + 0x40]
lea r8d, [rdx - 5]
mov rcx, r10
mov dword [rsp + 0x20], 4
mov dword [rsp + 0x40], eax
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x180036a6d
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, rdi
mov edx, eax
call fcn.180039920
lea rdx, str.Could_not_set_TCP_NODELAY:__s_n
mov rcx, rbx
mov r8, rax
call fcn.180033a50
mov rbx, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
lea rdx, str.TCP_NODELAY_set_n
mov rcx, rbx
call fcn.180033a50
mov rbx, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret

Function at 0x180036a90
Capabilities:
Set socket configuration

Disassembly:
push rbx
sub rsp, 0xf0
mov rax, qword [0x1800ac2b8]
xor rax, rsp
mov qword [rsp + 0xe0], rax
mov eax, dword [0x1800ae560]
mov rbx, rcx
mov dword [rsp + 0x30], 0x4020
mov dword [rsp + 0x34], 0
mov dword [rsp + 0x38], 4
test eax, eax
jne 0x180036b68
lea rcx, [rsp + 0x40]
xor edx, edx
mov r8d, LoadRegTypeLib
call fcn.18005f790
mov r8b, 3
mov edx, 2
xor ecx, ecx
mov dword [rsp + 0x40], QueryPathOfRegTypeLib
mov dword [rsp + 0x44], 6
call qword [sym.imp.KERNEL32.dll_VerSetConditionMask]
mov r8b, 3
mov edx, 1
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_VerSetConditionMask]
mov r8b, 3
mov edx, reloc.WLDAP32.dll_Ordinal_32
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_VerSetConditionMask]
mov r8b, 3
mov edx, reloc.WS2_32.dll_recv
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_VerSetConditionMask]
lea rcx, [rsp + 0x40]
mov edx, 0x33
mov r8, rax
call qword [sym.imp.KERNEL32.dll_VerifyVersionInfoA]
test eax, eax
je 0x180036b5c
mov dword [0x1800ae560], 2
jmp 0x180036bbf
mov dword [0x1800ae560], 1
jmp 0x180036b6d
cmp eax, 2
je 0x180036bbf
lea rax, [rsp + 0x38]
lea r9, [rsp + 0x34]
mov edx, 0xffff
mov r8d, 0x1001
mov rcx, rbx
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x180036b9e
mov eax, dword [rsp + 0x30]
cmp dword [rsp + 0x34], eax
jg 0x180036bbf
lea r9, [rsp + 0x30]
mov edx, 0xffff
mov r8d, 0x1001
mov rcx, rbx
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
mov rcx, qword [rsp + 0xe0]
xor rcx, rsp
call fcn.18005f4d0
add rsp, 0xf0
pop rbx
ret
Function at 0x180036c00
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
mov rbx, qword [rcx + 0x830]
mov rsi, rdx
mov rdi, rcx
test rbx, rbx
je 0x180036c73
mov rcx, qword [rcx + 0x80]
test rcx, rcx
jne 0x180036c33
cmp qword [rdi + 0x78], rcx
je 0x180036c73
mov qword [rsp + 0x20], rbx
mov dword [rsp + 0x28], 0
test rcx, rcx
jne 0x180036c49
mov rcx, qword [rdi + 0x78]
lea r8, [0x180036be0]
lea rdx, [rsp + 0x20]
add rcx, 0xc0
call fcn.180055820
cmp dword [rsp + 0x28], 0
jne 0x180036c87
mov qword [rdi + 0x830], 0
or rax, 0xffffffffffffffff
mov rbx, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret
test rsi, rsi
je 0x180036c8f
mov qword [rsi], rbx
cmp dword [rbx + 0x1f0], 0
mov rdi, qword [rbx + 0x1a8]
jne 0x180036c73
mov r9d, 2
lea rdx, [rsp + 0x40]
mov rcx, rdi
lea r8d, [r9 - 1]
call qword [sym.imp.WS2_32.dll_recv]
mov rbx, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
or rcx, 0xffffffffffffffff
test eax, eax
cmove rdi, rcx
mov rax, rdi
add rsp, 0x30
pop rdi
ret
Function at 0x180036e20
Capabilities:
Connect socket

Disassembly:
push rbp
push rsi
push rdi
push r13
push r14
sub rsp, 0x110
mov rax, qword [0x1800ac2b8]
xor rax, rsp
mov qword [rsp + 0xf0], rax
mov rbp, qword [rcx]
mov r13, r8
mov qword [r8], 0xffffffffffffffff
lea r8, [rsp + 0x30]
lea r9, [rsp + 0x20]
mov rsi, rcx
xor r14d, r14d
call fcn.180036d50
mov edi, eax
test eax, eax
je 0x180036e70
xor eax, eax
jmp 0x1800370a5
lea r8, [rsp + 0x28]
lea rdx, [rsp + 0xc0]
lea rcx, [rsp + 0x40]
mov qword [rsp + 0x108], rbx
call fcn.180036770
test eax, eax
jne 0x180036ecc
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, rsi
mov edx, eax
mov ebx, eax
call fcn.180039920
lea rdx, str.sa_addr_inet_ntop___failed_with_errno__d:__s
mov r8d, ebx
mov r9, rax
mov rcx, rbp
call fcn.180033b00
mov rdx, qword [rsp + 0x20]
mov rcx, rsi
call fcn.180036ce0
jmp 0x18003709b
lea r8, [rsp + 0xc0]
lea rdx, str.__Trying__s..._n
mov rcx, rbp
mov qword [rsp + 0x100], r12
call fcn.180033a50
cmp dword [rsp + 0x30], 2
mov rbx, qword [rsp + 0x20]
jne 0x180036f1a
cmp dword [rsp + 0x34], 1
jne 0x180036f1a
mov r12d, 1
cmp dword [rbp + 0x4d4], r14d
je 0x180036f1d
mov rdx, rbx
mov rcx, rsi
call fcn.180036a00
jmp 0x180036f1d
xor r12d, r12d
mov rcx, rbx
call fcn.180036a90
test r12d, r12d
mov r12, qword [rsp + 0x100]
je 0x180036f46
cmp dword [rbp + 0x6a4], r14d
je 0x180036f46
mov rdx, rbx
mov rcx, rbp
call fcn.180035f80
mov rax, qword [rbp + 0x278]
test rax, rax
je 0x180036f6a
mov rcx, qword [rbp + 0x280]
xor r8d, r8d
mov rdx, rbx
call rax
cmp eax, 2
jne 0x180036fb1
lea r14d, [rax - 1]
cmp dword [rsp + 0x30], 2
jne 0x180036fca
lea rcx, [rsp + 0x40]
call fcn.180016b80
mov r8d, dword [rsp + 0x30]
mov rdx, rbx
mov r9d, eax
mov rcx, rsi
call fcn.180036180
mov edi, eax
test eax, eax
je 0x180036fca
mov rdx, rbx
mov rcx, rsi
call fcn.180036ce0
mov eax, 7
cmp edi, 1
cmove edi, eax
mov eax, edi
jmp 0x18003709d
test eax, eax
je 0x180036f6a
mov rdx, rbx
mov rcx, rsi
call fcn.180036ce0
mov eax, Ordinal_46
jmp 0x18003709d
mov edx, 1
mov rcx, rbx
call fcn.180056d50
call fcn.180033510
cmp dword [rsi + 0x2e4], 1
mov qword [rsi + 0x2dc], rax
jle 0x180036ffa
mov edx, dword [rsi + 0x2e8]
mov rcx, rbp
call fcn.180031ce0
test r14d, r14d
jne 0x180037097
cmp dword [rsi + 0xa4], 1
jne 0x180037097
mov r8d, dword [rsp + 0x3c]
lea rdx, [rsp + 0x40]
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x18003708b
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
cmp eax, 0xb
je 0x180037081
cmp eax, 0x2732
jle 0x180037043
cmp eax, 0x2734
jle 0x180037081
mov edx, eax
mov rcx, rsi
call fcn.180039920
lea r8, [rsp + 0xc0]
lea rdx, str.Immediate_connect_fail_for__s:__s_n
mov r9, rax
mov rcx, rbp
call fcn.180033a50
mov rdx, rbx
mov rcx, rsi
mov dword [rbp + 0x889c], edi
call fcn.180036ce0
mov edi, 7
mov eax, edi
jmp 0x18003709d
xor edi, edi
mov qword [r13], rbx
mov eax, edi
jmp 0x18003709d
test edi, edi
jne 0x180037093
mov qword [r13], rbx
mov eax, edi
jmp 0x18003709d
mov qword [r13], rbx
xor eax, eax
mov rbx, qword [rsp + 0x108]
mov rcx, qword [rsp + 0xf0]
xor rcx, rsp
call fcn.18005f4d0
add rsp, 0x110
pop r14
pop r13
pop rdi
pop rsi
pop rbp
ret