joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140027f80
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 0x140027fc7
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
xor ecx, ecx
mov edx, 0x51
cmp eax, 0x2733
mov eax, gethostname
mov qword [rbx], 0
sete cl
test ecx, ecx
cmovne eax, edx
add rsp, 0x20
pop rbx
ret
mov qword [rbx], rcx
xor eax, eax
add rsp, 0x20
pop rbx
ret

Function at 0x140028070
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
cmp qword [rcx + 0x730], 0
mov rsi, r9
mov rbp, r8
movsxd rbx, edx
mov rdi, rcx
je 0x1400280d1
mov edx, 1
call fcn.140025e10
mov r11, qword [rdi + 0x688]
mov r9, rsi
mov r8, rbp
mov edx, ebx
mov rcx, rdi
mov qword [rsp + 0x20], r11
call qword [rdi + 0x730]
xor edx, edx
mov rcx, rdi
mov ebx, eax
call fcn.140025e10
mov eax, ebx
jmp 0x140028117
test edx, edx
js 0x140028115
cmp ebx, 2
jg 0x140028115
mov r9, qword [rdi + 0x680]
lea rdx, [0x140069b08]
lea rcx, [rbx + rbx*2]
add rcx, rdx
mov edx, 2
lea r8d, [rdx - 1]
call fcn.14005175c
mov r9, qword [rdi + 0x680]
mov r8d, 1
mov rdx, rsi
mov rcx, rbp
call fcn.14005175c
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret

Function at 0x140028130
Capabilities:
Write file on windows

Disassembly:
test rcx, rcx
je 0x140028286
mov r11, rsp
mov qword [r11 + 0x10], rdx
mov qword [r11 + 0x18], r8
mov qword [r11 + 0x20], r9
push rbx
sub rsp, 0x860
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rsp + 0x840], rax
cmp dword [rcx + 0xfa4], 0
mov rbx, rcx
je 0x14002826e
mov r8, rdx
lea r9, [r11 + 0x18]
lea rcx, [rsp + 0x30]
mov edx, 0x801
mov qword [r11 - 0x10], rdi
call fcn.1400324e0
cmp eax, 0x801
jb 0x1400281dd
mov rdx, qword [rsp + 0x878]
or rcx, 0xffffffffffffffff
xor eax, eax
mov rdi, rdx
repne scasb al, byte [rdi]
not rcx
cmp byte [rcx + rdx - 2], 0xa
jne 0x1400281c4
lea r8, str...._n
lea edx, [rax + 5]
lea rcx, [rsp + 0x82c]
jmp 0x1400281d8
lea r8, [0x140069b20]
mov edx, 4
lea rcx, [rsp + 0x82d]
call fcn.140032550
or rcx, 0xffffffffffffffff
xor eax, eax
lea rdi, [rsp + 0x30]
repne scasb al, byte [rdi]
not rcx
lea rdi, [rcx - 1]
cmp qword [rbx + 0x730], rax
je 0x140028230
lea edx, [rax + 1]
mov rcx, rbx
call fcn.140025e10
mov rdx, qword [rbx + 0x688]
lea r8, [rsp + 0x30]
mov qword [rsp + 0x20], rdx
mov r9, rdi
mov rcx, rbx
xor edx, edx
call qword [rbx + 0x730]
xor edx, edx
mov rcx, rbx
call fcn.140025e10
jmp 0x140028266
mov r9, qword [rbx + 0x680]
mov edx, 2
lea rcx, [0x140069b08]
lea r8d, [rdx - 1]
call fcn.14005175c
mov r9, qword [rbx + 0x680]
lea rcx, [rsp + 0x30]
mov r8d, 1
mov rdx, rdi
call fcn.14005175c
mov rdi, qword [rsp + 0x858]
mov rcx, qword [rsp + 0x840]
xor rcx, rsp
call fcn.1400512b0
add rsp, 0x860
pop rbx
repz ret
Function at 0x140028139
Capabilities:
Write file on windows

Disassembly:
test rcx, rcx
je 0x140028286
mov r11, rsp
mov qword [r11 + 0x10], rdx
mov qword [r11 + 0x18], r8
mov qword [r11 + 0x20], r9
push rbx
sub rsp, 0x860
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rsp + 0x840], rax
cmp dword [rcx + 0xfa4], 0
mov rbx, rcx
je 0x14002826e
mov r8, rdx
lea r9, [r11 + 0x18]
lea rcx, [rsp + 0x30]
mov edx, 0x801
mov qword [r11 - 0x10], rdi
call fcn.1400324e0
cmp eax, 0x801
jb 0x1400281dd
mov rdx, qword [rsp + 0x878]
or rcx, 0xffffffffffffffff
xor eax, eax
mov rdi, rdx
repne scasb al, byte [rdi]
not rcx
cmp byte [rcx + rdx - 2], 0xa
jne 0x1400281c4
lea r8, str...._n
lea edx, [rax + 5]
lea rcx, [rsp + 0x82c]
jmp 0x1400281d8
lea r8, [0x140069b20]
mov edx, 4
lea rcx, [rsp + 0x82d]
call fcn.140032550
or rcx, 0xffffffffffffffff
xor eax, eax
lea rdi, [rsp + 0x30]
repne scasb al, byte [rdi]
not rcx
lea rdi, [rcx - 1]
cmp qword [rbx + 0x730], rax
je 0x140028230
lea edx, [rax + 1]
mov rcx, rbx
call fcn.140025e10
mov rdx, qword [rbx + 0x688]
lea r8, [rsp + 0x30]
mov qword [rsp + 0x20], rdx
mov r9, rdi
mov rcx, rbx
xor edx, edx
call qword [rbx + 0x730]
xor edx, edx
mov rcx, rbx
call fcn.140025e10
jmp 0x140028266
mov r9, qword [rbx + 0x680]
mov edx, 2
lea rcx, [0x140069b08]
lea r8d, [rdx - 1]
call fcn.14005175c
mov r9, qword [rbx + 0x680]
lea rcx, [rsp + 0x30]
mov r8d, 1
mov rdx, rdi
call fcn.14005175c
mov rdi, qword [rsp + 0x858]
mov rcx, qword [rsp + 0x840]
xor rcx, rsp
call fcn.1400512b0
add rsp, 0x860
pop rbx
repz ret

Function at 0x140028290
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x20], r9
push rbx
sub rsp, 0x160
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rsp + 0x140], rax
cmp dword [rcx + 0xfa4], 0
mov rbx, rcx
jne 0x1400282d3
cmp qword [rcx + 0x690], 0
je 0x1400283d2
mov r8, rdx
lea r9, [rsp + 0x180]
lea rcx, [rsp + 0x30]
mov edx, pe_nt_image_headers64
mov qword [rsp + 0x158], rdi
call fcn.1400324e0
mov rdx, qword [rbx + 0x690]
or rcx, 0xffffffffffffffff
xor eax, eax
lea rdi, [rsp + 0x30]
repne scasb al, byte [rdi]
not rcx
lea rdi, [rcx - 1]
test rdx, rdx
je 0x14002833c
cmp dword [rbx + 0x16a0], eax
jne 0x14002833c
lea rcx, [rsp + 0x30]
movzx eax, byte [rcx]
inc rdx
inc rcx
mov byte [rdx - 1], al
test al, al
jne 0x140028322
mov dword [rbx + 0x16a0], 1
cmp dword [rbx + 0xfa4], 0
je 0x1400283ca
cmp qword [rbx + 0x730], 0
mov word [rsp + rdi + 0x30], 0xa
je 0x140028393
mov edx, 1
mov rcx, rbx
call fcn.140025e10
mov rdx, qword [rbx + 0x688]
lea r9, [rdi + 1]
mov qword [rsp + 0x20], rdx
lea r8, [rsp + 0x30]
mov rcx, rbx
xor edx, edx
call qword [rbx + 0x730]
xor edx, edx
mov rcx, rbx
call fcn.140025e10
jmp 0x1400283ca
mov r9, qword [rbx + 0x680]
mov edx, 2
lea rcx, [0x140069b08]
lea r8d, [rdx - 1]
call fcn.14005175c
mov r9, qword [rbx + 0x680]
lea rdx, [rdi + 1]
lea rcx, [rsp + 0x30]
mov r8d, 1
call fcn.14005175c
mov rdi, qword [rsp + 0x158]
mov rcx, qword [rsp + 0x140]
xor rcx, rsp
call fcn.1400512b0
add rsp, 0x160
pop rbx
ret
Function at 0x1400286f0
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
mov rsi, rcx
movsxd rcx, edx
mov rax, qword [rsi + 0x6f8]
mov rbp, qword [rsi + rcx*8 + 0x4c0]
lea rbx, [rcx + 0x28]
shl rbx, 5
add rbx, rsi
mov rdi, qword [rbx + 8]
sub rdi, qword [rbx + 0x10]
test byte [rax + 0x7c], 3
je 0x1400287cc
lea rax, [0x1400283f0]
cmp qword [rsi + rcx*8 + 0x4e0], rax
jne 0x1400287cc
cmp qword [rbx], 0
je 0x140028756
test rdi, rdi
je 0x1400287cc
or r8, 0xffffffffffffffff
xor r9d, r9d
mov rcx, rbp
or rdx, r8
call fcn.14003e760
cmp eax, 0xffffffff
je 0x1400287cc
test al, 1
je 0x1400287cc
cmp qword [rbx], 0
jne 0x1400287ab
mov rax, qword [rsi]
mov ecx, dword [rax + 0xbb8]
add ecx, ecx
movsxd rcx, ecx
mov qword [rbx + 8], rcx
call qword [fcn.140051160]
mov rdi, qword [rbx + 8]
xor ecx, ecx
mov qword [rbx], rax
mov qword [rbx + 0x10], rcx
mov qword [rbx + 0x18], rcx
test rax, rax
jne 0x1400287ab
mov qword [rbx + 8], rcx
jmp 0x1400287cc
mov rdx, qword [rbx]
xor r9d, r9d
mov r8d, edi
add rdx, qword [rbx + 0x10]
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_recv]
movsxd rcx, eax
test eax, eax
jle 0x1400287cc
add qword [rbx + 0x10], rcx
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret

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

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
sub rsp, 0x130
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rsp + 0x120], rax
mov rbp, qword [rsp + 0x180]
movsxd rax, edx
mov rsi, r9
mov rbx, qword [rcx + rax*8 + 0x4c0]
mov rdi, r8
mov r12, rcx
call fcn.1400286f0
xor r9d, r9d
mov r8d, esi
mov rdx, rdi
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_send]
mov dword [rbp], 0
movsxd rdi, eax
cmp rdi, 0xffffffffffffffff
jne 0x1400288a4
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, eax
cmp eax, 0x2733
jne 0x14002886d
mov dword [rbp], 0x51
xor eax, eax
jmp 0x1400288a7
lea rdx, [rsp + 0x20]
mov r8d, pe_nt_image_headers64
mov ecx, eax
call fcn.14003f6a0
mov rcx, qword [r12]
lea rdx, str.Send_failure:__s
mov r8, rax
call fcn.140028290
mov r11, qword [r12]
mov dword [r11 + 0x12a0], ebx
mov dword [rbp], gethostname
mov rax, rdi
mov rcx, qword [rsp + 0x120]
xor rcx, rsp
call fcn.1400512b0
add rsp, 0x130
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x14002c030
Capabilities:
Encode data using xor
Hash data using djb2

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
test rcx, rcx
je 0x14002c0ef
call fcn.14002beb0
test eax, eax
jne 0x14002c0ef
or rcx, 0xffffffffffffffff
mov qword [rsp + 0x30], rsi
mov qword [rsp + 0x38], rdi
xor eax, eax
mov rdi, rbx
xor esi, esi
repne scasb al, byte [rdi]
lea edx, [rsi + 0x2e]
not rcx
lea r8, [rcx - 1]
lea rdi, [rcx - 1]
mov rcx, rbx
call fcn.140046ee0
test rax, rax
je 0x14002c0a6
sub rax, rbx
lea edx, [rsi + 0x2e]
mov rcx, rbx
mov r8, rax
call fcn.140046ee0
mov rsi, rax
test rax, rax
je 0x14002c0a6
inc rsi
mov rcx, rbx
sub rcx, rsi
add rdi, rcx
test rsi, rsi
cmovne rbx, rsi
lea rsi, [rbx + rdi]
mov edi, 0x1505
cmp rbx, rsi
jae 0x14002c0db
nop dword [rax + rax]
movzx ecx, byte [rbx]
call fcn.140030c80
inc rbx
movsx rcx, al
imul rdi, rdi, 0x21
xor rdi, rcx
cmp rbx, rsi
jb 0x14002c0c0
mov rsi, qword [rsp + 0x30]
movzx eax, dil
mov rdi, qword [rsp + 0x38]
add rsp, 0x20
pop rbx
ret
xor eax, eax
add rsp, 0x20
pop rbx
ret

Function at 0x14002e4d0
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x70
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rsp + 0x68], rax
xor esi, esi
mov rdi, rdx
mov rbx, rcx
mov eax, esi
lea r9, [rsp + 0x50]
lea r8d, [rsi + 8]
cmp dword [rcx + 0xfdc], eax
mov edx, 0xffff
mov rcx, rdi
setne al
mov dword [rsp + 0x20], 4
mov dword [rsp + 0x50], eax
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x14002e53f
lea rdx, str.Failed_to_set_SO_KEEPALIVE_on_fd__d_n
mov r8, rdi
mov rcx, rbx
call fcn.140028130
jmp 0x14002e5ce
mov ecx, dword [rbx + 0xecc]
mov dword [rsp + 0x58], 1
call fcn.14002bc50
mov ecx, dword [rbx + 0xed0]
imul eax, eax, 0x3e8
mov dword [rsp + 0x50], eax
mov dword [rsp + 0x5c], eax
call fcn.14002bc50
mov qword [rsp + 0x40], rsi
mov qword [rsp + 0x38], rsi
lea r8, [rsp + 0x58]
mov r9d, listen
mov edx, 0x98000004
imul eax, eax, 0x3e8
mov dword [rsp + 0x50], eax
mov dword [rsp + 0x60], eax
lea rax, [rsp + 0x54]
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 0x14002e5ce
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.140028130
mov rcx, qword [rsp + 0x68]
xor rcx, rsp
call fcn.1400512b0
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret
Function at 0x14002edf0
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x240
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rsp + 0x230], rax
cmp dword [rcx + 0x32c], 3
mov rdi, rdx
mov rbx, rcx
jne 0x14002f036
cmp dword [rcx + 0x66c], 0
mov qword [rsp + 0x260], rsi
jne 0x14002f026
cmp dword [rcx + 0x6c8], 0
jne 0x14002f026
mov rsi, qword [rcx]
lea r8, [rsp + 0x20]
lea rdx, [rsp + 0xb0]
mov rcx, rdi
mov dword [rsp + 0x20], 0x80
call qword [sym.imp.WS2_32.dll_getpeername]
test eax, eax
je 0x14002eea0
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, [rsp + 0x130]
mov r8d, pe_nt_image_headers64
mov ecx, eax
mov ebx, eax
call fcn.14003f6a0
lea rdx, str.getpeername___failed_with_errno__d:__s
mov r8d, ebx
mov r9, rax
mov rcx, rsi
call fcn.140028290
jmp 0x14002f02e
lea rcx, [rsp + 0x30]
xor edx, edx
mov r8d, 0x80
mov dword [rsp + 0x24], 0x80
call fcn.14004f6e0
lea r8, [rsp + 0x24]
lea rdx, [rsp + 0x30]
mov rcx, rdi
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x14002ef08
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, [rsp + 0x130]
mov r8d, pe_nt_image_headers64
mov ecx, eax
mov ebx, eax
call fcn.14003f6a0
lea rdx, str.getsockname___failed_with_errno__d:__s
mov r8d, ebx
mov r9, rax
mov rcx, rsi
call fcn.140028290
jmp 0x14002f02e
mov edx, dword [rsp + 0x20]
lea r9, [rbx + 0x42c]
lea r8, [rbx + 0x3fe]
lea rcx, [rsp + 0xb0]
call fcn.14002ed60
test eax, eax
jne 0x14002ef6a
call fcn.140050a04
mov rbx, rax
call fcn.140050a04
mov ecx, dword [rbx]
lea rdx, [rsp + 0x130]
mov r8d, pe_nt_image_headers64
mov rdi, rax
call fcn.14003f6a0
mov r8d, dword [rdi]
lea rdx, str.ssrem_inet_ntop___failed_with_errno__d:__s
mov r9, rax
mov rcx, rsi
call fcn.140028290
jmp 0x14002f02e
mov rax, qword [rbx + 0x3fe]
mov edx, dword [rsp + 0x24]
lea r9, [rbx + 0x460]
mov qword [rbx + 0x2f8], rax
mov rax, qword [rbx + 0x406]
lea r8, [rbx + 0x430]
mov qword [rbx + 0x300], rax
mov rax, qword [rbx + 0x40e]
lea rcx, [rsp + 0x30]
mov qword [rbx + 0x308], rax
mov rax, qword [rbx + 0x416]
mov qword [rbx + 0x310], rax
mov rax, qword [rbx + 0x41e]
mov qword [rbx + 0x318], rax
mov eax, dword [rbx + 0x426]
mov dword [rbx + 0x320], eax
movzx eax, word [rbx + 0x42a]
mov word [rbx + 0x324], ax
call fcn.14002ed60
test eax, eax
jne 0x14002f026
call fcn.140050a04
mov rbx, rax
call fcn.140050a04
mov ecx, dword [rbx]
lea rdx, [rsp + 0x130]
mov r8d, pe_nt_image_headers64
mov rdi, rax
call fcn.14003f6a0
mov r8d, dword [rdi]
lea rdx, str.ssloc_inet_ntop___failed_with_errno__d:__s
mov r9, rax
mov rcx, rsi
call fcn.140028290
jmp 0x14002f02e
mov rcx, rbx
call fcn.14002ec40
mov rsi, qword [rsp + 0x260]
mov rcx, qword [rsp + 0x230]
xor rcx, rsp
call fcn.1400512b0
mov rbx, qword [rsp + 0x268]
add rsp, 0x240
pop rdi
ret
Function at 0x14002f1d0
Capabilities:
Set socket configuration

Disassembly:
push rbx
sub rsp, 0x150
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rsp + 0x140], rax
mov rbx, qword [rcx]
mov rax, rdx
mov edx, 6
lea r9, [rsp + 0x30]
lea r8d, [rdx - 5]
mov rcx, rax
mov dword [rsp + 0x30], 1
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x14002f246
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, [rsp + 0x40]
mov r8d, pe_nt_image_headers64
mov ecx, eax
call fcn.14003f6a0
lea rdx, str.Could_not_set_TCP_NODELAY:__s_n
mov rcx, rbx
mov r8, rax
call fcn.140028130
mov rcx, qword [rsp + 0x140]
xor rcx, rsp
call fcn.1400512b0
add rsp, 0x150
pop rbx
ret

Function at 0x14002f260
Capabilities:
Set socket configuration

Disassembly:
push rbx
sub rsp, 0x30
mov eax, dword [0x1400903c0]
mov rbx, rcx
mov dword [rsp + 0x50], 0x4020
mov dword [rsp + 0x48], 0
mov dword [rsp + 0x58], 4
test eax, eax
jne 0x14002f2bd
lea r9d, [rax + 3]
lea r8d, [rax + 2]
lea ecx, [rax + 6]
xor edx, edx
call fcn.14001e220
test eax, eax
je 0x14002f2b1
mov dword [0x1400903c0], 2
add rsp, 0x30
pop rbx
ret
mov dword [0x1400903c0], 1
jmp 0x14002f2c2
cmp eax, 2
je 0x14002f314
lea rax, [rsp + 0x58]
lea r9, [rsp + 0x48]
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 0x14002f2f3
mov eax, dword [rsp + 0x50]
cmp dword [rsp + 0x48], eax
jg 0x14002f314
lea r9, [rsp + 0x50]
mov edx, 0xffff
mov r8d, 0x1001
mov rcx, rbx
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
add rsp, 0x30
pop rbx
ret
Function at 0x140031320
Capabilities:
Resolve dns

Disassembly:
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x20
xor r15d, r15d
mov r14, r9
mov qword [r9], r15
lea r9, [rsp + 0x68]
mov edi, r15d
mov r13d, r15d
call qword [sym.imp.WS2_32.dll_getaddrinfo]
mov r12d, eax
test eax, eax
jne 0x1400314e3
mov qword [rsp + 0x50], rbx
mov rbx, qword [rsp + 0x68]
test rbx, rbx
je 0x1400314c9
mov qword [rsp + 0x58], rbp
mov qword [rsp + 0x60], rsi
mov eax, dword [rbx + 4]
cmp eax, 2
jne 0x14003137d
lea ebp, [rax + 0xe]
jmp 0x140031389
cmp eax, 0x17
jne 0x140031431
lea ebp, [rax + 5]
cmp qword [rbx + 0x20], r15
je 0x140031431
mov rax, qword [rbx + 0x10]
test rax, rax
je 0x140031431
cmp rax, rbp
jb 0x140031431
mov ecx, gethostbyname
call qword [fcn.140051160]
mov rsi, rax
test rax, rax
je 0x14003146c
mov ecx, dword [rbx]
mov dword [rax], ecx
mov ecx, dword [rbx + 4]
mov dword [rax + 4], ecx
mov ecx, dword [rbx + 8]
mov dword [rax + 8], ecx
mov ecx, dword [rbx + 0xc]
mov dword [rax + 0x10], ebp
mov dword [rax + 0xc], ecx
mov rcx, rbp
mov qword [rax + 0x20], r15
mov qword [rax + 0x18], r15
mov qword [rax + 0x28], r15
call qword [fcn.140051160]
mov qword [rsi + 0x20], rax
test rax, rax
je 0x14003145b
mov rdx, qword [rbx + 0x20]
mov r8, rbp
mov rcx, rax
call fcn.140050270
mov rcx, qword [rbx + 0x18]
test rcx, rcx
je 0x14003141e
call qword [case.0x14002c17c.0]
mov qword [rsi + 0x18], rax
test rax, rax
je 0x140031440
test rdi, rdi
cmove rdi, rsi
test r13, r13
je 0x14003142e
mov qword [r13 + 0x28], rsi
mov r13, rsi
mov rbx, qword [rbx + 0x28]
test rbx, rbx
jne 0x140031370
jmp 0x140031472
mov rcx, qword [rsi + 0x20]
mov r12d, 8
call qword [fcn.140051120]
mov rcx, rsi
call qword [fcn.140051120]
jmp 0x140031472
mov rcx, rsi
mov r12d, 8
call qword [fcn.140051120]
jmp 0x140031472
mov r12d, 8
mov rcx, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x58]
test rcx, rcx
je 0x14003148c
call qword [sym.imp.WS2_32.dll_freeaddrinfo]
test r12d, r12d
je 0x1400314c4
test rdi, rdi
je 0x1400314bf
mov rcx, qword [rdi + 0x20]
call qword [fcn.140051120]
mov rcx, qword [rdi + 0x18]
call qword [fcn.140051120]
mov rbx, qword [rdi + 0x28]
mov rcx, rdi
call qword [fcn.140051120]
mov rdi, rbx
test rbx, rbx
jne 0x140031496
mov rdi, r15
jmp 0x1400314d8
test rdi, rdi
jne 0x1400314d8
mov r12d, 0x2af9
mov ecx, r12d
call qword [sym.imp.WS2_32.dll_WSASetLastError]
mov rbx, qword [rsp + 0x50]
mov qword [r14], rdi
mov eax, r12d
add rsp, 0x20
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x140031910
Capabilities:
Connect socket
Get local ipv4 addresses
Get socket information
Receive data
Receive data on socket
Send data
Send data on socket
Set socket configuration

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x70
mov rax, qword [0x14008e168]
xor rax, rsp
mov qword [rsp + 0x60], rax
mov edx, 1
mov edi, 2
mov rsi, r9
lea r8d, [rdx + 5]
mov ecx, edi
mov dword [rsp + 0x30], reloc.WS2_32.dll_recv
mov dword [rsp + 0x34], 1
call qword [sym.imp.WS2_32.dll_socket]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140031b05
xor eax, eax
mov ecx, 0x7f000001
mov qword [rsp + 0x38], rax
mov word [rsp + 0x38], di
mov qword [rsp + 0x40], rax
call qword [sym.imp.WS2_32.dll_htonl]
lea r9, [rsp + 0x34]
lea r8d, [rdi + 2]
mov dword [rsp + 0x3c], eax
xor eax, eax
mov edx, 0xffff
mov rcx, rbx
mov qword [rsi + 8], 0xffffffffffffffff
mov qword [rsi], 0xffffffffffffffff
mov word [rsp + 0x3a], ax
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
je 0x140031ae9
lea r8d, [rdi + 0xe]
lea rdx, [rsp + 0x38]
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
je 0x140031ae9
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x38]
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_getsockname]
cmp eax, 0xffffffff
je 0x140031ae9
lea edx, [rdi - 1]
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
je 0x140031ae9
lea edx, [rdi - 1]
xor r8d, r8d
mov ecx, edi
call qword [sym.imp.WS2_32.dll_socket]
mov qword [rsi], rax
cmp rax, 0xffffffffffffffff
je 0x140031ae9
lea r8d, [rdi + 0xe]
lea rdx, [rsp + 0x38]
mov rcx, rax
call qword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x140031ae9
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_accept]
mov qword [rsi + 8], rax
cmp rax, 0xffffffffffffffff
je 0x140031ae9
lea r8, [0x14006a8c8]
lea edx, [rdi + 0xa]
lea rcx, [rsp + 0x48]
mov r9, rsi
call fcn.140032550
or rcx, 0xffffffffffffffff
xor eax, eax
lea rdi, [rsp + 0x48]
lea rdx, [rsp + 0x48]
xor r9d, r9d
repne scasb al, byte [rdi]
not rcx
lea rdi, [rcx - 1]
lea r8d, [rcx - 1]
mov rcx, qword [rsi]
call qword [sym.imp.WS2_32.dll_send]
movsxd rdx, eax
cmp rdx, rdi
jne 0x140031ae9
mov rcx, qword [rsi + 8]
xor r9d, r9d
lea rdx, [rsp + 0x54]
lea r8d, [r9 + 0xc]
call qword [sym.imp.WS2_32.dll_recv]
movsxd rcx, eax
cmp rcx, rdi
jne 0x140031ae9
lea rdx, [rsp + 0x54]
lea rcx, [rsp + 0x48]
mov r8, rdi
call fcn.1400505c0
test eax, eax
jne 0x140031ae9
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_closesocket]
xor eax, eax
jmp 0x140031b08
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, qword [rsi]
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, qword [rsi + 8]
call qword [sym.imp.WS2_32.dll_closesocket]
or eax, 0xffffffff
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.1400512b0
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rsp, r11
pop rdi
ret
Function at 0x1400331d0
Capabilities:
Create thread

Disassembly:
sub rsp, 0x38
xor eax, eax
mov r9, rdx
mov r8, rcx
mov qword [rsp + 0x28], rax
xor edx, edx
xor ecx, ecx
mov dword [rsp + 0x20], eax
call fcn.1400532b0
test rax, rax
je 0x1400331f9
cmp rax, 0xffffffffffffffff
jne 0x1400331fb
xor eax, eax
add rsp, 0x38
ret

Function at 0x140035930
Capabilities:
Hash data via wincrypt
Initialize hashing via wincrypt

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
push rsi
push rdi
push r12
sub rsp, 0x50
mov rdi, r8
xor r12d, r12d
mov rbx, r9
mov rsi, rdx
mov rbp, rcx
mov r8, r9
mov rcx, rdi
xor edx, edx
mov qword [rax - 0x28], r12
mov qword [rax - 0x30], r12
mov dword [rax + 0x20], r12d
mov dword [rax - 0x38], 4
mov dword [rax - 0x34], ebx
call fcn.14004f6e0
mov r9d, dword [rsp + 0x90]
lea rcx, [rsp + 0x40]
xor r8d, r8d
xor edx, edx
mov dword [rsp + 0x20], 0xf0000000
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
test eax, eax
je 0x140035a4c
mov edx, dword [rsp + 0x98]
mov rcx, qword [rsp + 0x40]
lea rax, [rsp + 0x38]
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
je 0x140035a2a
mov rcx, qword [rsp + 0x38]
xor r9d, r9d
mov r8d, esi
mov rdx, rbp
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
je 0x140035a2a
mov rcx, qword [rsp + 0x38]
lea r9, [rsp + 0x30]
lea r8, [rsp + 0x88]
lea edx, [r12 + 4]
mov dword [rsp + 0x20], r12d
call qword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
test eax, eax
je 0x140035a2a
mov eax, dword [rsp + 0x88]
cmp rbx, rax
jb 0x140035a2a
mov rcx, qword [rsp + 0x38]
lea r9, [rsp + 0x34]
lea edx, [r12 + 2]
mov r8, rdi
mov dword [rsp + 0x20], r12d
call qword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
mov rcx, qword [rsp + 0x38]
test rcx, rcx
je 0x140035a3a
call qword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
mov rcx, qword [rsp + 0x40]
test rcx, rcx
je 0x140035a4c
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov rbx, qword [rsp + 0x70]
mov rbp, qword [rsp + 0x78]
add rsp, 0x50
pop r12
pop rdi
pop rsi
ret

Function at 0x1400379d0
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push r12
sub rsp, 0x20
mov r12, rcx
mov ebx, 1
xor ecx, ecx
mov edx, ebx
xor ebp, ebp
call qword [fcn.14005104c]
mov rdi, rax
test rax, rax
je 0x140037a4d
nop word [rax + rax]
mov r8d, ebx
mov rdx, rdi
mov rcx, r12
mov rbp, rdi
mov esi, ebx
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
mov ebx, eax
test eax, eax
je 0x140037a78
cmp ebx, esi
je 0x140037a78
cmp ebx, 0x8000
ja 0x140037a78
cmp ebx, esi
jb 0x140037a73
mov edx, ebx
mov rcx, rdi
call qword [fcn.14005104c]
mov rdi, rax
test rax, rax
jne 0x140037a10
mov rcx, rbp
call qword [fcn.140051120]
xor eax, eax
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x48]
add rsp, 0x20
pop r12
ret
mov rax, rdi
jmp 0x140037a58
mov rcx, rdi
jmp 0x140037a50
jmp 0x1400379d0