joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140052270
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rbx, rcx
mov esi, 0x40
mov ecx, esi
call fcn.140061660
mov rdx, rbx
mov rcx, rax
mov rdi, rax
call fcn.1400bf3c8
or rdx, 0xffffffffffffffff
inc rdx
cmp word [rdi + rdx*2], 0
jne 0x1400522a0
sub esi, edx
mov ecx, esi
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
jmp fcn.1400618c0

Function at 0x140052320
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rdi, rcx
cmp edx, 0xd
jne 0x14005236d
mov ebx, 0x40
mov edx, r8d
mov ecx, ebx
call fcn.140061660
mov rdx, rdi
mov rcx, rax
call fcn.1400bf3f8
or rdx, 0xffffffffffffffff
inc rdx
cmp word [rax + rdx*2], 0
jne 0x140052350
sub ebx, edx
mov ecx, ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
jmp fcn.1400618c0
cmp edx, 1
je 0x14005238b
cmp edx, 0x18
je 0x14005238b
cmp edx, 3
je 0x140052386
cmp edx, 0x19
je 0x140052386
cmp edx, 0xb
jne 0x14005238e
movzx edi, cx
jmp 0x14005238e
movzx edi, cl
mov ebx, 0x20
mov edx, r8d
mov ecx, ebx
call fcn.140061660
lea rdx, [0x1400ce1b4]
mov r8d, edi
mov rcx, rax
call fcn.1400c0180
sub ebx, eax
mov ecx, ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
jmp fcn.1400618c0

Function at 0x140052630
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rsi
push rdi
push r15
sub rsp, 0x28
mov ebp, r9d
mov edi, edx
mov rsi, rcx
test r8, r8
je 0x14005271a
movzx r15d, word [r8]
test r15w, r15w
je 0x14005271a
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x58], r12
mov qword [rsp + 0x60], r13
xor r13d, r13d
test edx, edx
mov qword [rsp + 0x20], r14
cmovs edi, r13d
test rcx, rcx
je 0x14005269d
cmp word [rcx], r13w
je 0x14005269d
or rbx, 0xffffffffffffffff
inc rbx
cmp word [rcx + rbx*2], r13w
jne 0x140052685
cmp ebx, edi
cmovg ebx, edi
sub edi, ebx
jns 0x1400526a0
mov edi, r13d
jmp 0x1400526a0
mov ebx, r13d
call fcn.1400615f0
lea ecx, [rbx + rdi]
mov edx, ebp
mov r12d, eax
call fcn.140061660
mov r14, rax
test r12d, r12d
je 0x1400526c5
mov ecx, r12d
call fcn.1400617a0
mov rsi, rax
mov r12, qword [rsp + 0x58]
test ebx, ebx
je 0x1400526e3
movsxd rcx, edi
movsxd r8, ebx
mov rdx, rsi
lea rcx, [r14 + rcx*2]
add r8, r8
call sub.msvcrt.dll_memmove
test edi, edi
je 0x1400526f9
mov edx, edi
mov rdi, r14
movzx eax, r15w
mov ecx, edx
lea r14, [r14 + rdx*2]
rep stosw word [rdi], ax
movsxd rax, ebx
mov rbx, qword [rsp + 0x50]
mov word [r14 + rax*2], r13w
mov r14, qword [rsp + 0x20]
mov r13, qword [rsp + 0x60]
add rsp, 0x28
pop r15
pop rdi
pop rsi
pop rbp
ret
mov ecx, r9d
add rsp, 0x28
pop r15
pop rdi
pop rsi
pop rbp
jmp fcn.140061880
Function at 0x140052ee8
Capabilities:
Accept command line arguments

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x20
mov rdi, rcx
mov rcx, qword [0x14010bb20]
call fcn.14005ef84
xor ebp, ebp
or esi, 0xffffffff
mov r14, rax
mov ebx, ebp
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
movzx edx, word [rax]
test dx, dx
je 0x140052fe5
mov rcx, qword [rsp + 0x40]
mov r9w, 0x22
cmp dx, 0x20
jne 0x140052f3f
add rax, 2
cmp word [rax], 0x20
je 0x140052f35
movzx edx, word [rax]
mov r8d, 1
cmp dx, r9w
jne 0x140052f7d
add rax, 2
mov rbx, rax
movzx ecx, word [rax]
test cx, cx
je 0x140052fbd
cmp cx, r9w
je 0x140052f6f
add rax, 2
movzx ecx, word [rax]
test cx, cx
jne 0x140052f5d
cmp word [rax], bp
je 0x140052fbd
mov rcx, rax
add rax, 2
jmp 0x140052fc5
test dx, dx
je 0x140052fc2
mov rbx, rax
cmp dx, 0x20
je 0x140052f6f
add rax, 2
cmp word [rax], r9w
jne 0x140052fb3
add rax, 2
movzx ecx, word [rax]
test cx, cx
je 0x140052fbd
cmp cx, r9w
je 0x140052fb3
add rax, 2
movzx ecx, word [rax]
test cx, cx
jne 0x140052fa1
movzx edx, word [rax]
test dx, dx
jne 0x140052f85
jmp 0x140052f6f
mov rcx, rax
jmp 0x140052fc5
mov r8d, ebp
cmp dword [r14], esi
jne 0x140052fcf
test rdi, rdi
jne 0x140052fef
test r8d, r8d
je 0x140052fd6
inc esi
movzx edx, word [rax]
mov rbx, rbp
test dx, dx
jne 0x140052f2f
test rdi, rdi
jne 0x140053004
movsxd rax, esi
jmp 0x140053006
test rbx, rbx
je 0x140053004
sub rcx, rbx
mov rax, rbx
sar rcx, 1
mov dword [rdi], ecx
inc dword [r14]
jmp 0x140053006
mov dword [rdi], ebp
mov rbx, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x50]
add rsp, 0x20
pop r14
pop rdi
pop rsi
ret

Function at 0x140053038
Capabilities:
Get thread local storage value

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 0x20], rsi
push rdi
sub rsp, 0x20
mov ebx, ecx
lea rcx, [rax + 0x10]
xor ebp, ebp
mov dword [rax + 0x10], ebp
call fcn.140052ee8
mov esi, dword [rsp + 0x38]
mov ecx, esi
mov edx, ebx
mov rdi, rax
call fcn.140061660
mov ecx, ebp
jmp 0x14005308e
test esi, esi
je 0x140053093
movzx edx, word [rdi]
cmp dx, 0x22
jne 0x140053081
inc ecx
jmp 0x140053088
mov word [rax], dx
add rax, 2
add rdi, 2
dec esi
cmp word [rdi], bp
jne 0x140053070
mov word [rax], bp
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
jmp fcn.1400618c0
Function at 0x140053980
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x140106008], 0
jne 0x1400539a5
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x140106008], 1
mov dword [0x14010600c], eax
mov rcx, qword [0x1401058d4]
xor edx, edx
mov r8d, 0x90
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [0x14010600c]
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetTickCount]
xor ebx, eax
mov ecx, ebx
add rsp, 0x20
pop rbx
jmp 0x140053b60
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
cmp dword [0x140106008], 0
mov ebx, ecx
jne 0x140053b84
call fcn.140053980
mov ecx, dword [0x14010600c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
test rax, rax
jne 0x140053bac
call fcn.140053980
mov ecx, dword [0x14010600c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
lea rdx, [rdi + 8]
mov r8d, reloc.WS2_32.dll_recvfrom
nop word [rax + rax]
imul eax, ebx, 0x53a9b4fb
mov ecx, 1
mov ebx, 1
sub ecx, eax
lea rdx, [rdx + 4]
mov dword [rdx + 0x40], ecx
imul eax, ecx, 0x53a9b4fb
sub ebx, eax
mov dword [rdx - 4], ebx
dec r8
jne 0x140053bc0
lea esi, [r8 + 0x1f]
mov dword [rdi], r8d
mov dword [rdi + 4], 0xa
lea ebp, [rsi - 0xf]
nop word [rax + rax]
movsxd r11, dword [rdi]
movsxd rbx, dword [rdi + 4]
mov r10d, dword [rdi + rbx*4 + 8]
mov r9d, dword [rdi + r11*4 + 8]
mov eax, dword [rdi + r11*4 + 0x4c]
ror r9d, 5
lea rcx, [rdi + r11*4]
lea r8, [rdi + r11*4]
ror eax, 0xd
add r9d, r10d
add eax, dword [rdi + rbx*4 + 0x4c]
dec r11d
mov dword [r8 + 0x4c], r9d
cmovs r11d, ebp
dec ebx
mov dword [rcx + 8], eax
cmovs ebx, ebp
mov dword [rdi], r11d
mov dword [rdi + 4], ebx
dec rsi
jne 0x140053c00
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x140053b60
Capabilities:
Get thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x140106008], 0
jne 0x1400539a5
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x140106008], 1
mov dword [0x14010600c], eax
mov rcx, qword [0x1401058d4]
xor edx, edx
mov r8d, 0x90
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [0x14010600c]
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetTickCount]
xor ebx, eax
mov ecx, ebx
add rsp, 0x20
pop rbx
jmp 0x140053b60
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
cmp dword [0x140106008], 0
mov ebx, ecx
jne 0x140053b84
call fcn.140053980
mov ecx, dword [0x14010600c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
test rax, rax
jne 0x140053bac
call fcn.140053980
mov ecx, dword [0x14010600c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
lea rdx, [rdi + 8]
mov r8d, reloc.WS2_32.dll_recvfrom
nop word [rax + rax]
imul eax, ebx, 0x53a9b4fb
mov ecx, 1
mov ebx, 1
sub ecx, eax
lea rdx, [rdx + 4]
mov dword [rdx + 0x40], ecx
imul eax, ecx, 0x53a9b4fb
sub ebx, eax
mov dword [rdx - 4], ebx
dec r8
jne 0x140053bc0
lea esi, [r8 + 0x1f]
mov dword [rdi], r8d
mov dword [rdi + 4], 0xa
lea ebp, [rsi - 0xf]
nop word [rax + rax]
movsxd r11, dword [rdi]
movsxd rbx, dword [rdi + 4]
mov r10d, dword [rdi + rbx*4 + 8]
mov r9d, dword [rdi + r11*4 + 8]
mov eax, dword [rdi + r11*4 + 0x4c]
ror r9d, 5
lea rcx, [rdi + r11*4]
lea r8, [rdi + r11*4]
ror eax, 0xd
add r9d, r10d
add eax, dword [rdi + rbx*4 + 0x4c]
dec r11d
mov dword [r8 + 0x4c], r9d
cmovs r11d, ebp
dec ebx
mov dword [rcx + 8], eax
cmovs ebx, ebp
mov dword [rdi], r11d
mov dword [rdi + 4], ebx
dec rsi
jne 0x140053c00
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret

Function at 0x140053c60
Capabilities:
Get thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x140106008], 0
mov rbx, rcx
jne 0x140053c77
call fcn.140053980
mov ecx, dword [0x14010600c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r9, rax
test rax, rax
jne 0x140053c9f
call fcn.140053980
mov ecx, dword [0x14010600c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r9, rax
movsxd r8, dword [r9]
movsxd rdx, dword [r9 + 4]
mov eax, reloc.WS2_32.dll_recv
mov r10d, dword [r9 + r8*4 + 0x4c]
mov r11d, dword [r9 + r8*4 + 8]
ror r10d, 0xd
add r10d, dword [r9 + rdx*4 + 0x4c]
ror r11d, 5
add r11d, dword [r9 + rdx*4 + 8]
mov dword [r9 + r8*4 + 8], r10d
mov dword [r9 + r8*4 + 0x4c], r11d
dec r8d
mov ecx, r11d
cmovs r8d, eax
dec edx
cmovs edx, eax
mov dword [r9], r8d
mov dword [r9 + 4], edx
inc rbx
je 0x140053d18
mov edx, r10d
mov r8, rbx
mov eax, ebx
shr r8, 0x20
imul rax, rdx
shr rax, 0x20
imul rcx, r8
imul rdx, r8
shr rcx, 0x20
add rax, rcx
add rax, rdx
add rsp, 0x20
pop rbx
ret
mov eax, r10d
shl rax, 0x20
and rax, rcx
add rsp, 0x20
pop rbx
ret
Function at 0x140054bf4
Capabilities:
Create thread

Disassembly:
lea r8, str.Mozilla_5.0_Gecko_41.0_Firefox_41.0
xor edx, edx
jmp 0x140054bf4
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x30
mov rbp, rcx
mov rcx, qword [0x14010bbe0]
mov r12, r8
mov r14d, edx
xor ebx, ebx
call fcn.14005ef84
mov r15, rax
test rbp, rbp
je 0x140054cd8
mov rcx, qword [0x1401058d4]
lea edx, [rbx + 8]
mov r8d, 0x98
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
lea esi, [rbx + 1]
mov rcx, rbp
or dword [rax + 4], 0xffffffff
mov dword [rax], esi
mov rdi, rax
call sub.msvcrt.dll__wcsdup
mov rcx, r12
mov qword [rdi + 8], rax
call sub.msvcrt.dll__wcsdup
mov dword [rdi + 0x40], r14d
mov qword [rdi + 0x60], rax
mov eax, dword [r15]
mov dword [rdi + 0x44], eax
mov eax, dword [r15 + 4]
mov dword [rdi + 0x90], esi
mov dword [rdi + 0x48], eax
test sil, r14b
je 0x140054cc5
lea rax, [rsp + 0x60]
lea r8, [0x140054ec8]
mov r9, rdi
mov qword [rsp + 0x28], rax
mov edx, 0x10000
xor ecx, ecx
mov dword [rsp + 0x20], ebx
call qword [sym.imp.KERNEL32.dll_CreateThread]
test rax, rax
je 0x140054cb8
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x140054cbc
mov esi, dword [rsp + 0x60]
test esi, esi
je 0x140054cd0
mov rbx, rdi
jmp 0x140054cd8
mov rcx, rdi
call fcn.140054cf4
mov rbx, rax
mov rcx, rdi
call fcn.140054f90
mov rbp, qword [rsp + 0x70]
mov rax, rbx
mov rbx, qword [rsp + 0x68]
add rsp, 0x30
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret

Function at 0x140055858
Capabilities:
Initialize winsock library

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x1c0
mov ebx, reloc.WS2_32.dll_recv
lea r8, [fcn.140055764]
lea ecx, [rbx + 0x28]
mov edx, ebx
call fcn.14005f2b0
xor r8d, r8d
xor edx, edx
mov ecx, ebx
mov qword [0x140106038], rax
call fcn.14005f01c
xor ebx, ebx
cmp word [0x140106030], bx
mov qword [0x14010bc40], rax
jne 0x14005597b
lea rdx, [rsp + 0x20]
mov ecx, 0x101
call qword [sym.imp.WS2_32.dll_WSAStartup]
lea edi, [rbx + 1]
mov word [0x140106030], di
test eax, eax
je 0x1400558c9
mov word [0x140106030], bx
lea rcx, str.ws2_32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov qword [0x140106060], rax
test rax, rax
je 0x14005597b
lea rdx, [0x1400ce810]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140106060]
lea rdx, [0x1400ce820]
mov qword [0x140106040], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140106060]
lea rdx, str.getnameinfo
mov qword [0x140106048], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140106060]
lea rdx, str.WSAStringToAddressA
mov qword [0x140106050], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp qword [0x140106040], rbx
mov qword [0x140106058], rax
je 0x14005597b
cmp qword [0x140106048], rbx
je 0x14005597b
cmp qword [0x140106050], rbx
je 0x14005597b
mov ecx, dword [0x140106034]
test rax, rax
cmovne ecx, edi
mov dword [0x140106034], ecx
mov rbx, qword [rsp + 0x1d0]
add rsp, 0x1c0
pop rdi
ret
Function at 0x140055fa4
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x760]
sub rsp, 0x860
mov rsi, rcx
mov rcx, qword [0x14010bc40]
xor edi, edi
mov r15d, edi
call fcn.14005ef84
mov rcx, qword [rsi]
lea r12d, [rdi + 1]
mov r14, rax
cmp word [rsi + 0x24], r12w
jne 0x14005602d
xor r8d, r8d
xor edx, edx
call qword [sym.imp.WS2_32.dll_accept]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x14005619f
lea rcx, [rsi + 0x30]
lea edx, [rdi + 0x28]
call fcn.14005fcb0
mov r15d, r12d
mov dword [rax], r12d
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov rcx, rax
mov rax, qword [rsi + 0x28]
mov qword [r14 + 8], rax
mov qword [r14], rcx
jmp 0x14005619f
xor r9d, r9d
mov r8d, 0x800
lea rdx, [rsp + 0x60]
cmp word [rsi + 0x26], di
je 0x14005605e
lea rax, [rbp + 0x7a0]
mov dword [rbp + 0x7a0], 0x1c
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
jmp 0x140056079
lea rax, [rbp + 0x7a8]
mov dword [rbp + 0x7a8], reloc.WS2_32.dll_recv
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x30]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_recvfrom]
mov r12d, eax
test eax, eax
jle 0x14005619f
mov rbx, qword [rsi + 0x30]
mov r15d, 2
test rbx, rbx
je 0x1400560d9
lea rcx, [rbx + 0x14]
cmp word [rsi + 0x26], di
je 0x1400560b6
movsxd r8, dword [rbp + 0x7a0]
lea rdx, [rsp + 0x40]
jmp 0x1400560c2
movsxd r8, dword [rbp + 0x7a8]
lea rdx, [rsp + 0x30]
call sub.msvcrt.dll_memcmp
test eax, eax
je 0x1400560d0
mov rbx, qword [rbx]
jmp 0x140056099
lea rdi, [rbx + 0x10]
test rbx, rbx
jne 0x140056128
lea rcx, [rsi + 0x30]
mov edx, 0x60
call fcn.14005fcb0
xor r8d, r8d
mov dword [rax], r15d
mov qword [rax + 0x28], rsi
mov rdi, rax
mov al, byte [rsi + 0x26]
mov byte [rdi + 0x20], al
cmp word [rsi + 0x26], r8w
je 0x14005611e
movups xmm0, xmmword [rsp + 0x40]
movups xmmword [rdi + 4], xmm0
movsd xmm1, qword [rsp + 0x50]
movsd qword [rdi + 0x14], xmm1
mov eax, dword [rsp + 0x58]
mov dword [rdi + 0x1c], eax
jmp 0x140056128
movups xmm0, xmmword [rsp + 0x30]
movdqu xmmword [rdi + 4], xmm0
mov r8, qword [rdi + 0x38]
mov rcx, qword [0x1401058d4]
test r8, r8
jne 0x140056164
movsxd rbx, r12d
xor edx, edx
mov r8, rbx
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
lea rdx, [rsp + 0x60]
mov r8, rbx
mov rcx, rax
mov qword [rdi + 0x38], rax
mov dword [rdi + 0x40], r12d
mov qword [rdi + 0x48], rax
call sub.msvcrt.dll_memcpy
jmp 0x140056194
mov eax, dword [rdi + 0x40]
mov edx, 8
add eax, r12d
movsxd r9, eax
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
movsxd rcx, dword [rdi + 0x40]
lea rdx, [rsp + 0x60]
add rcx, rax
movsxd r8, r12d
mov qword [rdi + 0x38], rax
call sub.msvcrt.dll_memcpy
add dword [rdi + 0x40], r12d
mov qword [r14], rdi
mov rcx, qword [rsi + 0x28]
mov qword [r14 + 8], rcx
mov eax, r15d
mov rbx, qword [rsp + 0x8b0]
add rsp, 0x860
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
Function at 0x140056428
Capabilities:
Get socket status
Receive data
Receive data on socket
Set socket configuration

Disassembly:
push rbp
push rbx
push rdi
lea rbp, [rsp - 0x950]
sub rsp, 0xa50
xor ebx, ebx
cmp dword [rcx], 1
mov rdi, rcx
jne 0x1400564d2
movsxd rcx, dword [rcx + 8]
lea rax, [rbp + 0x980]
lea rdx, [rsp + 0x40]
mov rdi, rcx
mov qword [rsp + 0x48], rcx
xor r9d, r9d
xor r8d, r8d
inc ecx
mov dword [rsp + 0x40], 1
mov qword [rbp + 0x980], rbx
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_select]
test eax, eax
js 0x1400564cb
je 0x140056551
lea rdx, [rsp + 0x40]
mov rcx, rdi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x140056551
lea r8, [rbp + 0x970]
mov edx, 0x4004667f
mov rcx, rdi
call qword [sym.imp.WS2_32.dll_ioctlsocket]
test eax, eax
jne 0x1400564cb
cmp dword [rbp + 0x970], ebx
je 0x1400564cb
lea ebx, [rax + 2]
jmp 0x140056551
mov ebx, 4
jmp 0x140056551
mov rcx, qword [rcx + 0x30]
lea rax, [rbp + 0x978]
lea rdx, [rbp + 0x150]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x30]
xor r9d, r9d
mov r8d, 0x800
mov dword [rbp + 0x978], reloc.WS2_32.dll_recv
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_recvfrom]
mov dword [rbp + 0x970], eax
test eax, eax
jle 0x140056551
mov rcx, qword [0x1401058d4]
movsxd r8, eax
xor edx, edx
mov ebx, 2
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
movsxd rcx, dword [rbp + 0x970]
mov dword [rdi + 0x40], ecx
mov r8, rcx
lea rdx, [rbp + 0x150]
mov rcx, rax
mov qword [rdi + 0x38], rax
mov qword [rdi + 0x48], rax
call sub.msvcrt.dll_memcpy
movsxd rax, ebx
add rsp, 0xa50
pop rdi
pop rbx
pop rbp
ret
Function at 0x140056b04
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x40
mov r12d, edx
mov rdi, rcx
mov rdx, rcx
mov rcx, qword [0x140106038]
mov r13, r9
mov esi, r8d
xor r14d, r14d
call fcn.14005f1e8
mov rbx, rax
test rax, rax
je 0x140056c3a
cmp r12d, 0xffff
ja 0x140056c23
bt esi, 0x1c
jae 0x140056b67
lea r15d, [r14 + 0x17]
btr esi, 0x1c
jmp 0x140056b6d
mov r15d, 2
mov eax, 1
test esi, esi
mov ecx, r15d
cmove esi, eax
xor r8d, r8d
mov edx, esi
call qword [sym.imp.WS2_32.dll_socket]
mov rbp, rax
cmp rax, 0xffffffffffffffff
je 0x140056c23
lea r8, [rsp + 0x30]
mov edx, 0x8004667e
mov rcx, rax
mov dword [rsp + 0x30], 1
call qword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
jle 0x140056c15
xor ecx, ecx
lea r8, [rbx + 8]
cmp r15d, 0x17
mov rdx, rbp
mov r9, r8
sete cl
mov dword [rsp + 0x28], r12d
mov qword [rsp + 0x20], r13
call fcn.140057130
test eax, eax
je 0x140056c15
cmp esi, 1
jne 0x140056bed
lea edx, [rsi + 0x63]
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_listen]
test eax, eax
jne 0x140056c15
xor eax, eax
cmp r15d, 0x17
mov qword [rbx], rbp
sete al
cmp rdi, 0xffffffffffffffff
mov word [rbx + 0x24], si
mov word [rbx + 0x26], ax
mov rax, rdi
mov r14, rbx
cmove rax, rbx
mov qword [rbx + 0x28], rax
jmp 0x140056c1e
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_closesocket]
test r14, r14
jne 0x140056c3a
mov rcx, qword [0x140106038]
cmp rdi, 0xffffffffffffffff
cmove rdi, rbx
mov rdx, rdi
call fcn.14005f11c
lea r11, [rsp + 0x40]
mov rax, r14
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret

Function at 0x140056c84
Capabilities:
Get hostname
Resolve dns

Disassembly:
xor ecx, ecx
jmp 0x140056c84
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x120
xor ebx, ebx
mov edi, ecx
mov dword [0x14010bc60], ecx
lea rcx, [rsp + 0x20]
mov edx, 0xff
mov dword [0x14010bc80], ebx
mov qword [0x14010bcb8], rbx
mov qword [0x14010bcc0], rbx
call qword [sym.imp.WS2_32.dll_gethostname]
test eax, eax
jne 0x140056d42
cmp edi, 0x10000000
jne 0x140056d18
cmp dword [0x140106034], ebx
je 0x140056d42
mov rcx, qword [0x140106070]
test rcx, rcx
je 0x140056cec
call qword [0x140106048]
mov qword [0x140106070], rbx
lea r9, [0x140106070]
lea rcx, [rsp + 0x20]
xor r8d, r8d
xor edx, edx
call qword [0x140106040]
test rax, rax
jne 0x140056d42
mov rax, qword [0x140106070]
mov qword [0x14010bcc0], rax
jmp 0x140056d3d
lea rcx, [rsp + 0x20]
call qword [sym.imp.WS2_32.dll_gethostbyname]
test rax, rax
je 0x140056d42
lea rcx, [0x14010bca0]
mov r8d, 0x20
mov rdx, rax
call sub.msvcrt.dll_memcpy
mov ebx, 1
movsxd rax, ebx
mov rbx, qword [rsp + 0x130]
add rsp, 0x120
pop rdi
ret
Function at 0x140056e04
Capabilities:
Send data
Send data on socket

Disassembly:
sub rsp, 0x38
cmp dword [rcx], 1
mov r10d, r8d
mov r11, rdx
jne 0x140056e22
mov rcx, qword [rcx + 8]
xor r9d, r9d
call qword [sym.imp.WS2_32.dll_send]
jmp 0x140056e60
cmp byte [rcx + 0x20], 0
lea r8, [rcx + 4]
mov edx, 0x1c
jne 0x140056e36
mov edx, reloc.WS2_32.dll_recv
mov rax, qword [rcx + 0x28]
test rax, rax
je 0x140056e44
mov rcx, qword [rax]
jmp 0x140056e48
mov rcx, qword [rcx + 0x30]
mov dword [rsp + 0x28], edx
mov qword [rsp + 0x20], r8
xor r9d, r9d
mov r8d, r10d
mov rdx, r11
call qword [sym.imp.WS2_32.dll_sendto]
cdqe
add rsp, 0x38
ret

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

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
xor esi, esi
cmp dword [rcx], 1
mov rax, rdx
mov rdi, rcx
jne 0x140056ec9
mov rcx, qword [rcx + 8]
xor r9d, r9d
call qword [sym.imp.WS2_32.dll_recv]
mov esi, eax
jmp 0x140056f11
cmp qword [rcx + 0x38], rsi
je 0x140056f11
cmp r8d, dword [rcx + 0x40]
mov rdx, qword [rcx + 0x48]
mov esi, r8d
cmovg esi, dword [rcx + 0x40]
mov rcx, rax
movsxd rbx, esi
mov r8, rbx
call sub.msvcrt.dll_memcpy
sub dword [rdi + 0x40], esi
add qword [rdi + 0x48], rbx
cmp dword [rdi + 0x40], 0
jne 0x140056f11
mov r8, qword [rdi + 0x38]
mov rcx, qword [0x1401058d4]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
and qword [rdi + 0x38], 0
mov rbx, qword [rsp + 0x30]
movsxd rax, esi
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret

Function at 0x140057060
Capabilities:
Receive data
Receive data on socket
Set socket configuration

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rsi
mov dword [rax + 0x10], edx
push rdi
sub rsp, 0x20
xor ebx, ebx
mov rsi, r8
movsxd rdi, ecx
cmp edx, 0xffffffff
jne 0x140057096
lea r8, [rax + 0x10]
mov rcx, rdi
mov edx, 0x4004667f
call qword [sym.imp.WS2_32.dll_ioctlsocket]
mov edx, dword [rsp + 0x38]
test edx, edx
je 0x1400570d9
mov r8d, edx
mov rcx, rdi
mov r9d, 2
mov rdx, rsi
call qword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
jne 0x1400570cd
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
add eax, 0xffffd8bb
and eax, 0xfffffffa
neg eax
sbb ebx, ebx
not ebx
and ebx, 0xfffffffe
jmp 0x1400570d9
mov ecx, 0xfffffffe
test eax, eax
cmove eax, ecx
mov ebx, eax
mov rsi, qword [rsp + 0x40]
movsxd rax, ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret