joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40d1d0
Capabilities:
Read file on windows

Disassembly:
mov r11, rsp
sub rsp, 0x4f8
mov rax, qword [0x00424338]
mov qword [rsp + 0x4d0], rax
mov r8, qword [sym.imp.msvcp60.dll_unsigned_long_long_unsigned___int64__const_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::npos]
mov qword [r11 + 0x18], rbx
mov qword [r11 + 0x20], rbp
mov r8, qword [r8]
mov qword [r11 - 8], rsi
mov rbp, rdx
xor edx, edx
mov qword [r11 - 0x10], rdi
mov rbx, rcx
xor sil, sil
call qword [sym.imp.msvcp60.dll_public:_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char______ptr64___cdecl_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::erase_unsigned_long_long_unsigned___int64___unsigned_long_long_unsigned___int64_____ptr64]
lea rcx, [rsp + 0x41]
xor edx, edx
mov r8d, 0x87
mov byte [rsp + 0x40], sil
call sub.msvcrt.dll_memset
lea rdx, [rsp + 0x40]
xor r8d, r8d
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_OpenFile]
test eax, eax
movsxd rdi, eax
jne 0x40d278
xor ecx, ecx
call fcn.00406ef0
lea rdx, [0x0041d1f0]
lea rcx, [rsp + 0x38]
mov rbx, rax
call fcn.004108b0
lea rdx, str._comm__read_file__s__OpenFile_failed:__s
mov r9, rbx
mov r8, rbp
mov rcx, rax
call fcn.004109b0
jmp 0x40d370
mov qword [rsp + 0x4e0], r12
lea rcx, [rsp + 0xd0]
xor r12d, r12d
xor edx, edx
mov r8d, 0x400
mov dword [rsp + 0x30], r12d
call sub.msvcrt.dll_memset
lea r9, [rsp + 0x30]
lea rdx, [rsp + 0xd0]
mov r8d, 0x400
mov rcx, rdi
mov qword [rsp + 0x20], r12
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40d32a
nop
nop
nop
nop
mov r8d, dword [rsp + 0x30]
lea rdx, [rsp + 0xd0]
mov rcx, rbx
call qword [sym.imp.msvcp60.dll_public:_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char______ptr64___cdecl_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::append_char_const____ptr64__unsigned_long_long_unsigned___int64_____ptr64]
cmp dword [rsp + 0x30], 0x400
jb 0x40d35c
lea rcx, [rsp + 0xd0]
xor edx, edx
mov r8d, 0x400
call sub.msvcrt.dll_memset
lea r9, [rsp + 0x30]
lea rdx, [rsp + 0xd0]
mov r8d, 0x400
mov rcx, rdi
mov qword [rsp + 0x20], r12
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x40d2d0
xor ecx, ecx
call fcn.00406ef0
lea rdx, [0x0041d228]
lea rcx, [rsp + 0x38]
mov rbx, rax
call fcn.004108b0
lea rdx, str._comm__read_file__s__ReadFile_failed:__s
mov r9, rbx
mov r8, rbp
mov rcx, rax
call fcn.004109b0
jmp 0x40d35f
mov sil, 1
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r12, qword [rsp + 0x4e0]
mov rdi, qword [rsp + 0x4e8]
mov rbp, qword [rsp + 0x518]
mov rbx, qword [rsp + 0x510]
mov al, sil
mov rsi, qword [rsp + 0x4f0]
mov rcx, qword [rsp + 0x4d0]
call fcn.00419e60
add rsp, 0x4f8
ret
Function at 0x40d3f0
Capabilities:
Write file on windows

Disassembly:
mov r11, rsp
sub rsp, 0x108
mov rax, qword [0x00424338]
mov qword [rsp + 0xd0], rax
mov qword [r11 + 0x20], rbx
mov qword [r11 - 8], rbp
mov qword [r11 - 0x10], rsi
mov qword [r11 - 0x18], rdi
mov rbp, rcx
mov qword [r11 - 0x20], r12
mov r12, rdx
mov rbx, r8
lea rcx, [rsp + 0x41]
xor dil, dil
xor edx, edx
mov r8d, 0x87
mov byte [rsp + 0x40], dil
call sub.msvcrt.dll_memset
lea rdx, [rsp + 0x40]
mov r8d, 0x1001
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_OpenFile]
test eax, eax
movsxd rsi, eax
jne 0x40d48d
xor ecx, ecx
call fcn.00406ef0
lea rdx, [0x0041d260]
lea rcx, [rsp + 0x30]
mov rbx, rax
call fcn.004108b0
lea rdx, str._comm__write_file__s__OpenFile_failed:__s
mov r9, rbx
mov r8, rbp
mov rcx, rax
call fcn.004109b0
jmp 0x40d4ec
lea r9, [rsp + 0x38]
mov r8d, ebx
mov rdx, r12
mov rcx, rsi
mov qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x40d4e0
xor ecx, ecx
call fcn.00406ef0
lea rdx, str._warn__
lea rcx, [rsp + 0x30]
mov rbx, rax
call fcn.004108b0
lea rdx, str._comm__write_file__s__WriteFile_failed:__s
mov r9, rbx
mov r8, rbp
mov rcx, rax
call fcn.004109b0
jmp 0x40d4e3
mov dil, 1
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r12, qword [rsp + 0xe8]
mov rsi, qword [rsp + 0xf8]
mov rbp, qword [rsp + 0x100]
mov rbx, qword [rsp + 0x128]
mov al, dil
mov rdi, qword [rsp + 0xf0]
mov rcx, qword [rsp + 0xd0]
call fcn.00419e60
add rsp, 0x108
ret
Function at 0x40dba0
Capabilities:
Read file on windows

Disassembly:
sub rsp, 0x28
mov r9, qword [rcx + 0x150]
mov rax, rdx
test r9, r9
je 0x40dbc8
mov edx, 1
mov rcx, rax
call qword [sym.imp.msvcrt.dll_fread]
cdqe
add rsp, 0x28
ret
xor eax, eax
add rsp, 0x28
ret
Function at 0x40eb70
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
test rcx, rcx
je 0x40eba7
push rbx
sub rsp, 0x20
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40eb94
add rsp, 0x20
pop rbx
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
and eax, 0xfffffffe
mov rcx, rbx
mov edx, eax
call qword [sym.imp.KERNEL32.dll_SetFileAttributesA]
add rsp, 0x20
pop rbx
ret 0

Function at 0x40ebb0
Capabilities:
Delete file
Move file

Disassembly:
push rbx
sub rsp, 0x190
mov qword [rsp + 0x60], 0xfffffffffffffffe
mov rax, qword [0x00424338]
mov qword [rsp + 0x180], rax
mov rbx, rcx
mov qword [rsp + 0x50], rcx
test rcx, rcx
jne 0x40ebe6
lea eax, [rcx - 1]
jmp 0x40ecbe
test edx, edx
je 0x40ebff
call fcn.0040eb70
mov rcx, rbx
call fcn.0040e700
nop
jmp 0x40ebff
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x40ecbc
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x40ecb5
lea rcx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_GetSystemTime]
mov byte [rsp + 0x70], 0
xor edx, edx
mov r8d, 0x103
lea rcx, [rsp + 0x71]
call sub.msvcrt.dll_memset
movzx r11d, word [rsp + 0x5e]
movzx eax, word [rsp + 0x5c]
movzx r8d, word [rsp + 0x5a]
movzx r9d, word [rsp + 0x58]
movzx r10d, word [rsp + 0x56]
mov dword [rsp + 0x40], r11d
mov dword [rsp + 0x38], eax
mov dword [rsp + 0x30], r8d
mov dword [rsp + 0x28], r9d
mov dword [rsp + 0x20], r10d
mov r9, rbx
lea r8, str._s._x_x_x_x_x
mov edx, 0x103
lea rcx, [rsp + 0x70]
call qword [sym.imp.msvcrt.dll__snprintf]
mov r8d, 3
lea rdx, [rsp + 0x70]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_MoveFileExA]
xor edx, edx
lea r8d, [rdx + 4]
lea rcx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_MoveFileExA]
mov eax, 0xffffffff
jmp 0x40ecbe
xor eax, eax
mov rcx, qword [rsp + 0x180]
call fcn.00419e60
add rsp, 0x190
pop rbx
ret
Function at 0x40f320
Capabilities:
Read file on windows

Disassembly:
mov r11, rsp
sub rsp, 0xc8
mov rax, qword [0x00424338]
mov qword [rsp + 0xa0], rax
test rdx, rdx
mov qword [r11 + 0x20], rbp
mov rbp, rdx
je 0x40f4bf
test rcx, rcx
je 0x40f4bf
lea rdx, [0x0041d464]
mov qword [r11 - 0x18], r12
call qword [sym.imp.msvcrt.dll_fopen]
test rax, rax
mov r12, rax
je 0x40f4bb
mov ecx, 0x4000
mov qword [rsp + 0xc0], rsi
mov qword [rsp + 0xb8], rdi
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov rcx, r12
mov rsi, rax
call qword [sym.imp.msvcrt.dll__fileno]
lea rcx, [rsp + 0x20]
mov edi, eax
call fcn.004158a0
mov r8d, 0x4000
mov rdx, rsi
mov ecx, edi
call qword [sym.imp.msvcrt.dll__read]
test eax, eax
jle 0x40f3e5
nop
nop
nop
lea rcx, [rsp + 0x20]
mov r8d, eax
mov rdx, rsi
call fcn.00416ab0
mov r8d, 0x4000
mov rdx, rsi
mov ecx, edi
call qword [sym.imp.msvcrt.dll__read]
test eax, eax
jg 0x40f3c0
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x90]
mov qword [rsp + 0xe0], rbx
call fcn.00416de0
mov byte [rbp], 0
xor ebx, ebx
nop
nop
nop
movzx r9d, byte [rsp + rbx + 0x90]
lea r8, str._02x
lea rcx, [rsp + 0x80]
mov edx, reloc.WS2_32.dll_recv
call fcn.0040df80
xor eax, eax
mov rdi, rbp
mov rcx, 0xffffffffffffffff
lea rdx, [rsp + 0x80]
repne scasb al, byte [rdi]
xor ecx, ecx
nop
nop
movzx eax, byte [rdx + rcx]
inc rcx
test al, al
mov byte [rdi + rcx - 2], al
jne 0x40f450
inc rbx
cmp rbx, 0x10
jl 0x40f410
mov rcx, r12
call qword [sym.imp.msvcrt.dll_fclose]
mov rcx, rsi
call fcn.00419af0
mov rdi, qword [rsp + 0xb8]
mov rsi, qword [rsp + 0xc0]
mov rbx, qword [rsp + 0xe0]
mov eax, 1
mov r12, qword [rsp + 0xb0]
mov rbp, qword [rsp + 0xe8]
mov rcx, qword [rsp + 0xa0]
call fcn.00419e60
add rsp, 0xc8
ret
xor eax, eax
jmp 0x40f496
xor eax, eax
jmp 0x40f49e
Function at 0x4108d0
Capabilities:
Print debug messages

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x20], r9
sub rsp, 0x58
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x48], rsi
mov rbx, rcx
lea rsi, [0x00428a40]
xor edx, edx
mov r8d, 0x5000
mov rcx, rsi
mov qword [rsp + 0x40], rdi
call sub.msvcrt.dll_memset
xor eax, eax
lea rcx, [rsp + 0x30]
lea rdi, [rsp + 0x70]
mov word [rsp + 0x30], 0
mov dword [rsp + 0x3a], eax
mov qword [rsp + 0x32], rax
mov word [rsp + 0x3e], ax
call qword [sym.imp.KERNEL32.dll_GetSystemTime]
mov rax, qword [rbx]
movzx r11d, word [rsp + 0x3c]
movzx r9d, word [rsp + 0x3a]
movzx r8d, word [rsp + 0x38]
mov qword [rsp + 0x28], rax
lea rdx, [0x0041d7e0]
mov rcx, rsi
mov dword [rsp + 0x20], r11d
call qword [sym.imp.msvcrt.dll_swprintf]
mov rdx, qword [rsp + 0x68]
mov r8, rdi
movsxd rbx, eax
lea rcx, [rsi + rbx*2]
call qword [sym.imp.msvcrt.dll_vswprintf]
lea rdx, [0x0041d808]
add eax, ebx
cdqe
lea rcx, [rsi + rax*2]
call qword [sym.imp.msvcrt.dll_swprintf]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov rdi, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
mov rbx, qword [rsp + 0x50]
add rsp, 0x58
ret

Function at 0x4109b0
Capabilities:
Print debug messages

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x20], r9
sub rsp, 0x78
mov qword [rsp + 0x70], rbx
mov rbx, rcx
lea rcx, [rsp + 0x40]
xor r9d, r9d
xor r8d, r8d
mov edx, 0x2801
mov qword [rsp + 0x68], rsi
mov qword [rsp + 0x50], 0
mov qword [rsp + 0x60], rdi
call fcn.00402dd0
xor eax, eax
lea rcx, [rsp + 0x30]
lea rsi, [rsp + 0x90]
mov word [rsp + 0x30], 0
mov dword [rsp + 0x3a], eax
mov qword [rsp + 0x32], rax
mov word [rsp + 0x3e], ax
call qword [sym.imp.KERNEL32.dll_GetSystemTime]
mov rax, qword [rbx]
movzx r11d, word [rsp + 0x3c]
mov rdi, qword [rsp + 0x50]
movzx r9d, word [rsp + 0x3a]
movzx r8d, word [rsp + 0x38]
mov qword [rsp + 0x28], rax
lea rdx, str.__02u:_02u:_02u__s
mov rcx, rdi
mov dword [rsp + 0x20], r11d
call qword [sym.imp.msvcrt.dll_sprintf]
mov rdx, qword [rsp + 0x88]
mov r8, rsi
movsxd rbx, eax
lea rcx, [rdi + rbx]
call qword [sym.imp.msvcrt.dll_vsprintf]
lea rdx, [0x0041d7dc]
add ebx, eax
movsxd rcx, ebx
add rcx, rdi
call qword [sym.imp.msvcrt.dll_sprintf]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_OutputDebugStringA]
test rdi, rdi
mov rsi, qword [rsp + 0x68]
mov rbx, qword [rsp + 0x70]
je 0x410a9e
mov rcx, rdi
call fcn.00419af0
mov rdi, qword [rsp + 0x60]
add rsp, 0x78
ret
Function at 0x412f20
Capabilities:
Send data
Send data on socket

Disassembly:
sub rsp, 0x58
cmp qword [rcx], 0xffffffffffffffff
mov qword [rsp + 0x60], rbx
mov qword [rsp + 0x68], rbp
mov qword [rsp + 0x48], r13
mov ebp, r8d
mov rbx, rdx
mov r13, rcx
jne 0x412f86
lea rdx, [0x0041d978]
lea rcx, [rsp + 0x30]
call fcn.004108b0
mov r9d, dword [r13 + 0x8c]
lea r8, [r13 + 9]
lea rdx, str._comm__Socket__s:_d_::send_error:_Invalid_Socket.
mov rcx, rax
call fcn.004109b0
mov eax, 0xffffffff
mov r13, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x68]
mov rbx, qword [rsp + 0x60]
add rsp, 0x58
ret
test rdx, rdx
jne 0x412fcf
lea rdx, [0x0041d9b8]
lea rcx, [rsp + 0x30]
call fcn.004108b0
mov r9d, dword [r13 + 0x8c]
lea r8, [r13 + 9]
lea rdx, str._comm__Socket__s:_d_::send_error:_NULL_buffer.
mov rcx, rax
call fcn.004109b0
mov eax, 0xffffffff
mov r13, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x68]
mov rbx, qword [rsp + 0x60]
add rsp, 0x58
ret
mov qword [rsp + 0x70], rsi
mov qword [rsp + 0x50], r12
xor r12d, r12d
test r8d, r8d
mov esi, r12d
je 0x413064
nop
nop
mov rcx, qword [r13]
movsxd rdx, r12d
xor r9d, r9d
add rdx, rbx
mov r8d, ebp
call qword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
mov esi, eax
je 0x41301a
test eax, eax
je 0x413064
add r12d, eax
sub ebp, eax
jne 0x412ff0
jmp 0x413064
mov qword [rsp + 0x78], rdi
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
call fcn.00406ef0
lea rdx, [0x0041d9f0]
lea rcx, [rsp + 0x30]
mov rbx, rax
call fcn.004108b0
mov r9d, dword [r13 + 0x8c]
lea r8, [r13 + 9]
lea rdx, str._comm__Socket__s:_d_::send_error:__s.
mov rcx, rax
mov qword [rsp + 0x20], rbx
call fcn.004109b0
mov rdi, qword [rsp + 0x78]
mov r13, qword [rsp + 0x48]
mov rbx, qword [rsp + 0x60]
test ebp, ebp
mov rbp, qword [rsp + 0x68]
cmove esi, r12d
mov r12, qword [rsp + 0x50]
mov eax, esi
mov rsi, qword [rsp + 0x70]
add rsp, 0x58
ret
Function at 0x413090
Capabilities:
Send data
Send data on socket

Disassembly:
sub rsp, 0x58
cmp qword [rcx], 0xffffffffffffffff
mov qword [rsp + 0x60], rbx
mov qword [rsp + 0x68], rbp
mov qword [rsp + 0x78], rdi
mov qword [rsp + 0x48], r13
mov ebp, r9d
mov r13, rcx
mov rbx, r8
mov rdi, rdx
jne 0x4130ef
lea rdx, [0x0041da20]
lea rcx, [rsp + 0x30]
call fcn.004108b0
mov r9d, dword [r13 + 0x8c]
lea r8, [r13 + 9]
lea rdx, str._comm__Socket__s:_d_::sendto_error:_Invalid_Socket.
mov rcx, rax
call fcn.004109b0
mov eax, 0xffffffff
jmp 0x4131c9
test rbx, rbx
jne 0x413127
lea rdx, [0x0041da60]
lea rcx, [rsp + 0x30]
call fcn.004108b0
mov r9d, dword [r13 + 0x8c]
lea r8, [r13 + 9]
lea rdx, str._comm__Socket__s:_d_::sendto_error:_NULL_buffer.
mov rcx, rax
call fcn.004109b0
lea eax, [rbx - 1]
jmp 0x4131c9
mov qword [rsp + 0x70], rsi
mov qword [rsp + 0x50], r12
xor r12d, r12d
test r9d, r9d
mov esi, r12d
je 0x4131b7
mov rcx, qword [r13]
movsxd rdx, r12d
xor r9d, r9d
mov r8d, ebp
add rdx, rbx
mov dword [rsp + 0x28], reloc.WS2_32.dll_recv
mov qword [rsp + 0x20], rdi
call qword [sym.imp.WS2_32.dll_sendto]
cmp eax, 0xffffffff
mov esi, eax
je 0x413177
test eax, eax
je 0x4131b7
add r12d, eax
sub ebp, eax
jne 0x413140
jmp 0x4131b7
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
call fcn.00406ef0
lea rdx, [0x0041daa0]
lea rcx, [rsp + 0x30]
mov rbx, rax
call fcn.004108b0
mov r9d, dword [r13 + 0x8c]
lea r8, [r13 + 9]
lea rdx, str._comm__Socket__s:_d_::sendto_error:__s.
mov rcx, rax
mov qword [rsp + 0x20], rbx
call fcn.004109b0
test ebp, ebp
cmove esi, r12d
mov r12, qword [rsp + 0x50]
mov eax, esi
mov rsi, qword [rsp + 0x70]
mov r13, qword [rsp + 0x48]
mov rdi, qword [rsp + 0x78]
mov rbp, qword [rsp + 0x68]
mov rbx, qword [rsp + 0x60]
add rsp, 0x58
ret
Function at 0x4132a0
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub rsp, 0x48
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x60], rsi
mov rsi, rcx
mov rcx, qword [rcx]
mov ebx, r8d
cmp rcx, 0xffffffffffffffff
jne 0x4132fc
lea rdx, [0x0041dad0]
lea rcx, [rsp + 0x30]
call fcn.004108b0
mov r9d, dword [rsi + 0x8c]
lea r8, [rsi + 9]
lea rdx, str._comm__Socket__s:_d_::recv_error:_Invalid_Socket.
mov rcx, rax
call fcn.004109b0
mov eax, 0xffffffff
mov rsi, qword [rsp + 0x60]
mov rbx, qword [rsp + 0x50]
add rsp, 0x48
ret
test rdx, rdx
jne 0x413340
lea rdx, [0x0041db10]
lea rcx, [rsp + 0x30]
call fcn.004108b0
mov r9d, dword [rsi + 0x8c]
lea r8, [rsi + 9]
lea rdx, str._comm__Socket__s:_d_::recv_error:_NULL_buffer.
mov rcx, rax
call fcn.004109b0
mov eax, 0xffffffff
mov rsi, qword [rsp + 0x60]
mov rbx, qword [rsp + 0x50]
add rsp, 0x48
ret
cmp byte [rsi + 8], 0
mov qword [rsp + 0x58], rbp
je 0x413364
mov r8d, 1
test ebx, ebx
cmovg r8d, ebx
xor r9d, r9d
call qword [sym.imp.WS2_32.dll_recv]
mov ebp, eax
jmp 0x413392
lea rax, [rsp + 0x30]
mov r8d, 1
test ebx, ebx
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r9
cmovg r8d, ebx
xor r9d, r9d
mov dword [rsp + 0x30], reloc.WS2_32.dll_recv
call qword [sym.imp.WS2_32.dll_recvfrom]
mov ebp, eax
cmp ebp, 0xffffffff
jne 0x4133e3
mov qword [rsp + 0x68], rdi
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
call fcn.00406ef0
lea rdx, [0x0041db48]
lea rcx, [rsp + 0x30]
mov rbx, rax
call fcn.004108b0
mov r9d, dword [rsi + 0x8c]
lea r8, [rsi + 9]
lea rdx, str._comm__Socket__s:_d_::recv_error:__s.
mov rcx, rax
mov qword [rsp + 0x20], rbx
call fcn.004109b0
mov rdi, qword [rsp + 0x68]
jmp 0x413416
test ebp, ebp
jne 0x413416
test ebx, ebx
jle 0x413416
lea rdx, [0x0041db78]
lea rcx, [rsp + 0x30]
call fcn.004108b0
mov r9d, dword [rsi + 0x8c]
lea r8, [rsi + 9]
lea rdx, str._comm__Socket__s:_d_::recv_info:_The_connection_has_been_gracefully_closed.
mov rcx, rax
call fcn.004109b0
mov rsi, qword [rsp + 0x60]
mov rbx, qword [rsp + 0x50]
mov eax, ebp
mov rbp, qword [rsp + 0x58]
add rsp, 0x48
ret
Function at 0x413440
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub rsp, 0x58
cmp qword [rcx], 0xffffffffffffffff
mov qword [rsp + 0x60], rbx
mov qword [rsp + 0x78], rdi
mov qword [rsp + 0x50], r12
mov qword [rsp + 0x48], r13
mov rdi, r9
mov r13d, r8d
mov rbx, rdx
mov r12, rcx
jne 0x4134a1
lea rdx, [0x0041dbd0]
lea rcx, [rsp + 0x38]
call fcn.004108b0
mov r9d, dword [r12 + 0x8c]
lea r8, [r12 + 9]
lea rdx, str._comm__Socket__s:_d_::recv_all_error:_Invalid_Socket.
mov rcx, rax
call fcn.004109b0
mov eax, 0xffffffff
jmp 0x4135b8
test rdx, rdx
jne 0x4134dd
lea rdx, [0x0041dc10]
lea rcx, [rsp + 0x38]
call fcn.004108b0
mov r9d, dword [r12 + 0x8c]
lea r8, [r12 + 9]
lea rdx, str._comm__Socket__s:_d_::recv_all_error:_NULL_buffer.
mov rcx, rax
call fcn.004109b0
mov eax, 0xffffffff
jmp 0x4135b8
mov qword [rsp + 0x68], rbp
mov qword [rsp + 0x70], rsi
xor esi, esi
test r8d, r8d
mov dword [rsp + 0x30], reloc.WS2_32.dll_recv
mov ebp, esi
jle 0x4135a6
nop
cmp byte [r12 + 8], 0
je 0x413525
mov rcx, qword [r12]
mov r8d, r13d
movsxd rdx, ebp
sub r8d, ebp
add rdx, rbx
xor r9d, r9d
call qword [sym.imp.WS2_32.dll_recv]
mov esi, eax
jmp 0x41354f
mov rcx, qword [r12]
lea rax, [rsp + 0x30]
mov r8d, r13d
mov qword [rsp + 0x28], rax
movsxd rdx, ebp
sub r8d, ebp
add rdx, rbx
xor r9d, r9d
mov qword [rsp + 0x20], rdi
call qword [sym.imp.WS2_32.dll_recvfrom]
mov esi, eax
test esi, esi
je 0x41355f
cmp esi, 0xffffffff
je 0x413564
add ebp, esi
cmp ebp, r13d
jl 0x413500
cmp esi, 0xffffffff
jne 0x4135a6
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
call fcn.00406ef0
lea rdx, [0x0041dc50]
lea rcx, [rsp + 0x38]
mov rbx, rax
call fcn.004108b0
mov r9d, dword [r12 + 0x8c]
lea r8, [r12 + 9]
lea rdx, str._comm__Socket__s:_d_::recv_all_error:__s.
mov rcx, rax
mov qword [rsp + 0x20], rbx
call fcn.004109b0
cmp ebp, r13d
cmove esi, ebp
mov rbp, qword [rsp + 0x68]
mov eax, esi
mov rsi, qword [rsp + 0x70]
mov r13, qword [rsp + 0x48]
mov r12, qword [rsp + 0x50]
mov rdi, qword [rsp + 0x78]
mov rbx, qword [rsp + 0x60]
add rsp, 0x58
ret
Function at 0x413af0
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
sub rsp, 0x58
mov rax, qword [0x00424338]
mov qword [rsp + 0x48], rax
cmp byte [rcx + 8], 0
mov qword [rsp + 0x70], rsi
mov rsi, rcx
je 0x413b22
mov edx, 1
lea ecx, [rdx + 1]
lea r8d, [rdx + 5]
call qword [sym.imp.WS2_32.dll_socket]
jmp 0x413b33
mov edx, 2
mov ecx, edx
lea r8d, [rdx + 0xf]
call qword [sym.imp.WS2_32.dll_socket]
cmp rax, 0xffffffffffffffff
mov qword [rsi], rax
jne 0x413b90
mov qword [rsp + 0x68], rbx
mov qword [rsp + 0x78], rdi
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
call fcn.00406ef0
lea rdx, [0x0041d8b8]
lea rcx, [rsp + 0x30]
mov rbx, rax
call fcn.004108b0
mov r9d, dword [rsi + 0x8c]
lea r8, [rsi + 9]
lea rdx, str._comm__Socket__s:_d_::create_failed:__s
mov rcx, rax
mov qword [rsp + 0x20], rbx
call fcn.004109b0
mov rdi, qword [rsp + 0x78]
mov rbx, qword [rsp + 0x68]
mov rcx, qword [rsi]
cmp rcx, 0xffffffffffffffff
je 0x413bf9
xor eax, eax
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x38]
mov word [rsp + 0x38], 0
mov dword [rsp + 0x30], reloc.WS2_32.dll_recv
mov qword [rsp + 0x3a], rax
mov dword [rsp + 0x42], eax
mov word [rsp + 0x46], ax
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x413be2
movzx ecx, word [rsp + 0x3a]
call qword [sym.imp.WS2_32.dll_htons]
movzx r11d, ax
mov dword [rsi + 0x8c], r11d
mov rax, qword [rsi]
mov rsi, qword [rsp + 0x70]
mov rcx, qword [rsp + 0x48]
call fcn.00419e60
add rsp, 0x58
ret
mov rax, rcx
mov rsi, qword [rsp + 0x70]
mov rcx, qword [rsp + 0x48]
call fcn.00419e60
add rsp, 0x58
ret
Function at 0x413c20
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
sub rsp, 0x78
mov rax, qword [0x00424338]
mov qword [rsp + 0x58], rax
cmp qword [rcx], 0xffffffffffffffff
mov qword [rsp + 0x98], rbx
mov qword [rsp + 0x70], rbp
mov qword [rsp + 0x68], rsi
mov rbp, r8
mov dword [rcx + 0x8c], edx
mov rsi, rcx
jne 0x413c6a
call fcn.00413af0
cmp rax, 0xffffffffffffffff
jne 0x413c6a
mov dword [rsi + 0x8c], eax
jmp 0x413db7
movzx ebx, word [rsi + 0x8c]
xor eax, eax
mov rcx, rbp
mov dword [rsp + 0x38], eax
mov word [rsp + 0x38], 2
mov dword [rsp + 0x3c], eax
mov dword [rsp + 0x40], eax
mov dword [rsp + 0x44], eax
call qword [sym.imp.WS2_32.dll_inet_addr]
test bx, bx
mov dword [rsp + 0x3c], eax
jne 0x413ca3
mov word [rsp + 0x3a], bx
jmp 0x413cb1
movzx ecx, bx
call qword [sym.imp.WS2_32.dll_htons]
mov word [rsp + 0x3a], ax
mov rcx, qword [rsi]
lea rdx, [rsp + 0x38]
mov r8d, reloc.WS2_32.dll_recv
call qword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
je 0x413d3f
cmp byte [rsi + 8], 0
je 0x413ce3
mov rcx, qword [rsi]
mov edx, 5
call qword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
je 0x413d3f
mov rcx, qword [rsi]
cmp rcx, 0xffffffffffffffff
je 0x413db7
xor eax, eax
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x48]
mov word [rsp + 0x48], 0
mov dword [rsp + 0x30], reloc.WS2_32.dll_recv
mov qword [rsp + 0x4a], rax
mov dword [rsp + 0x52], eax
mov word [rsp + 0x56], ax
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x413db7
movzx ecx, word [rsp + 0x4a]
call qword [sym.imp.WS2_32.dll_htons]
movzx r11d, ax
mov dword [rsi + 0x8c], r11d
jmp 0x413db7
mov qword [rsp + 0x60], rdi
mov dword [rsi + 0x8c], 0xffffffff
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
call fcn.00406ef0
lea rdx, [0x0041d8e8]
lea rcx, [rsp + 0x30]
mov rbx, rax
call fcn.004108b0
mov r9d, dword [rsi + 0x8c]
lea r8, [rsi + 9]
lea rdx, str._comm__Socket__s:_d_::listen_failed:__s
mov rcx, rax
mov qword [rsp + 0x20], rbx
call fcn.004109b0
mov rcx, qword [rsi]
cmp rcx, 0xffffffffffffffff
mov rdi, qword [rsp + 0x60]
je 0x413db0
mov edx, 2
call qword [sym.imp.WS2_32.dll_shutdown]
mov rcx, qword [rsi]
call qword [sym.imp.WS2_32.dll_closesocket]
mov qword [rsi], 0xffffffffffffffff
lea rdx, [0x0041d918]
lea rcx, [rsp + 0x30]
call fcn.004108b0
mov r9d, dword [rsi + 0x8c]
lea r8, [rsi + 9]
lea rdx, str._comm__Socket__s_::listen__d___s_
mov rcx, rax
mov qword [rsp + 0x20], rbp
call fcn.004109b0
mov eax, dword [rsi + 0x8c]
mov rsi, qword [rsp + 0x68]
mov rbp, qword [rsp + 0x70]
mov rbx, qword [rsp + 0x98]
mov rcx, qword [rsp + 0x58]
call fcn.00419e60
add rsp, 0x78
ret