joyce8/EMBER2024-capa huggingface dataset:
Function at 0x491493
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
mov esi, ecx
push edi
lea edi, [esi + 0xd0]
mov ecx, edi
xor ebx, ebx
call sym.Install.exe_public:_struct_HWND______thiscall_DuiLib::CWindowWnd::operator_struct_HWND____void_const
test eax, eax
jle 0x4914e2
push ebx
mov ecx, edi
mov byte [ebp - 1], 0
call sym.Install.exe_public:_void____thiscall_DuiLib::CStdPtrArray::operator___int_const
mov edx, dword [eax]
lea ecx, [ebp - 1]
push ecx
push dword [ebp + 0x10]
mov ecx, eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [edx]
cmp byte [ebp - 1], 0
jne 0x491543
mov ecx, edi
inc ebx
call sym.Install.exe_public:_struct_HWND______thiscall_DuiLib::CWindowWnd::operator_struct_HWND____void_const
cmp ebx, eax
jl 0x4914b1
mov eax, dword [ebp + 8]
sub eax, 0x100
je 0x49159c
sub eax, 4
je 0x491547
dec eax
dec eax
jne 0x491593
push dword [ebp + 0xc]
mov word [ebp + 8], ax
lea edi, [ebp + 0xa]
stosw word es:[edi], ax
call fcn.004c4312
pop ecx
mov ecx, dword [esi + 0x50]
push reloc.WS2_32.dll_ioctlsocket
lea edx, [ebp + 8]
push edx
mov word [ebp + 8], ax
mov eax, dword [ecx]
push sym.Install.exe_private:_static_class_DuiLib::CControlUI____stdcall_DuiLib::CPaintManagerUI::__FindControlFromShortcut_class_DuiLib::CControlUI___void__
call dword [eax + 0xfc]
mov esi, eax
test esi, esi
je 0x491593
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0xf0]
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x18]
mov al, 1
jmp 0x491595
cmp dword [esi + 0x54], 0
je 0x491593
xor eax, eax
push 7
pop ecx
lea edi, [ebp - 0x20]
rep stosd dword es:[edi], eax
mov ax, word [ebp + 0xc]
mov word [ebp - 0x10], ax
mov eax, dword [esi + 0x64]
mov dword [ebp - 0x18], eax
mov eax, dword [esi + 0x68]
mov dword [ebp - 0x24], 6
mov dword [ebp - 0x14], eax
call fcn.0048ea49
mov word [ebp - 0xe], ax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [esi + 0x54]
lea edx, [ebp - 0x24]
mov dword [ebp - 0x1c], eax
mov eax, dword [ecx]
push edx
call dword [eax + 0x108]
xor al, al
pop edi
pop esi
pop ebx
leave
ret 0x10
cmp dword [ebp + 0xc], 9
jne 0x491593
cmp dword [esi + 0x54], 0
je 0x4915eb
mov ecx, dword [esi + 0x54]
mov eax, dword [ecx]
call dword [eax + 0xc8]
test al, al
je 0x4915eb
mov ecx, dword [esi + 0x54]
mov eax, dword [ecx]
call dword [eax + 0xd4]
test al, al
je 0x4915eb
mov ecx, dword [esi + 0x54]
mov eax, dword [ecx]
push str.RichEditUI
call dword [eax + 0xc]
push eax
call fcn.004bafaa
pop ecx
pop ecx
test eax, eax
je 0x4915eb
mov ecx, dword [esi + 0x54]
call sym.Install.exe_public:_bool___thiscall_DuiLib::CRichEditUI::IsWantTab_void_
test al, al
jne 0x491593
push 0x10
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
setge al
movzx eax, al
push eax
mov ecx, esi
call sym.Install.exe_public:_bool___thiscall_DuiLib::CPaintManagerUI::SetNextTabControl_bool_
jmp 0x491543
Function at 0x4a3271
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
mov eax, dword [0x580ca0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, ecx
xor ebx, ebx
push edi
cmp byte [esi + 0x18], bl
je 0x4a32e2
cmp dword [esi + 0x10], ebx
je 0x4a32e2
push dword [esi + 4]
call dword [sym.imp.USER32.dll_GetWindowTextLengthW]
mov edi, eax
inc edi
lea eax, [edi + edi]
call fcn.004c41d0
mov dword [ebp - 8], esp
cmp esp, ebx
je 0x4a32e2
push edi
push dword [ebp - 8]
push dword [esi + 4]
call dword [sym.imp.USER32.dll_GetWindowTextW]
mov ecx, dword [esi + 0x10]
push dword [ebp - 8]
add ecx, 0x1b8
call fcn.0048dfc4
mov ecx, dword [esi + 0x10]
mov eax, dword [ecx]
push ebx
push ebx
push ebx
push str.textchanged
push ecx
call dword [eax + 0x1c]
mov ecx, eax
call sym.Install.exe_public:_void___thiscall_DuiLib::CPaintManagerUI::SendNotify_class_DuiLib::CControlUI___wchar_t_const___unsigned_int__long_int__bool_
xor eax, eax
lea esp, [ebp - 0x14]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004ba1db
leave
ret 0x10

Function at 0x4a78e9
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, ecx
xor ebx, ebx
cmp dword [esi + 0x4d4], ebx
je 0x4a7951
cmp dword [ebp + 8], 0x100
jne 0x4a7940
cmp word [ebp + 0xc], 0xd
jne 0x4a7940
cmp byte [esi + 0x4da], bl
je 0x4a7927
push 0x11
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
jge 0x4a7940
cmp byte [esi + 0x4db], bl
jne 0x4a7940
mov ecx, dword [esi + 0x40]
cmp ecx, ebx
je 0x4a793c
push ebx
push ebx
push ebx
push str.return
push esi
call sym.Install.exe_public:_void___thiscall_DuiLib::CPaintManagerUI::SendNotify_class_DuiLib::CControlUI___wchar_t_const___unsigned_int__long_int__bool_
xor eax, eax
jmp 0x4a7954
mov eax, dword [esi + 0x4d4]
mov ecx, dword [eax + 0xc]
mov eax, dword [ecx]
pop esi
pop ebx
pop ebp
jmp dword [eax + 0xc]
xor eax, eax
inc eax
pop esi
pop ebx
pop ebp
ret 0x10
Function at 0x4b044d
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
mov edx, dword [esp + 8]
test edx, edx
jne 0x4b0458
xor eax, eax
ret
mov eax, dword [esp + 4]
push esi
push edi
mov edi, dword [esp + 0x14]
not eax
mov ecx, 0xff
cmp edi, 8
jb 0x4b0513
mov esi, edi
shr esi, 3
push ebx
movzx ebx, byte [edx]
xor ebx, eax
and ebx, ecx
shr eax, 8
xor eax, dword [ebx*4 + 0x53cea0]
inc edx
movzx ebx, byte [edx]
xor ebx, eax
and ebx, ecx
shr eax, 8
xor eax, dword [ebx*4 + 0x53cea0]
inc edx
movzx ebx, byte [edx]
xor ebx, eax
and ebx, ecx
shr eax, 8
xor eax, dword [ebx*4 + 0x53cea0]
inc edx
movzx ebx, byte [edx]
xor ebx, eax
and ebx, ecx
shr eax, 8
xor eax, dword [ebx*4 + 0x53cea0]
inc edx
movzx ebx, byte [edx]
xor ebx, eax
and ebx, ecx
shr eax, 8
xor eax, dword [ebx*4 + 0x53cea0]
inc edx
movzx ebx, byte [edx]
xor ebx, eax
and ebx, ecx
shr eax, 8
xor eax, dword [ebx*4 + 0x53cea0]
inc edx
movzx ebx, byte [edx]
xor ebx, eax
and ebx, ecx
shr eax, 8
xor eax, dword [ebx*4 + 0x53cea0]
inc edx
movzx ebx, byte [edx]
xor ebx, eax
and ebx, ecx
shr eax, 8
xor eax, dword [ebx*4 + 0x53cea0]
inc edx
sub edi, 8
dec esi
jne 0x4b0478
pop ebx
test edi, edi
je 0x4b052c
movzx esi, byte [edx]
xor esi, eax
and esi, ecx
shr eax, 8
xor eax, dword [esi*4 + 0x53cea0]
inc edx
dec edi
jne 0x4b0517
pop edi
not eax
pop esi
ret

Function at 0x4b09c3
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0x14]
push edi
mov edi, dword [ebp + 0xc]
imul edi, dword [ebp + 0x10]
cmp byte [esi], 0
je 0x4b09f7
push 0
lea eax, [ebp + 0x10]
push eax
push edi
push dword [ebp + 8]
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4b09f2
mov byte [esi + 8], 1
mov eax, dword [ebp + 0x10]
jmp 0x4b0a1f
mov ecx, dword [esi + 0x18]
mov eax, dword [esi + 0x14]
lea edx, [ecx + edi]
cmp edx, eax
jbe 0x4b0a08
sub eax, ecx
mov edi, eax
mov eax, dword [esi + 0x10]
push edi
add eax, ecx
push eax
push dword [ebp + 8]
call fcn.004bf1d0
add esp, 0xc
add dword [esi + 0x18], edi
mov eax, edi
xor edx, edx
div dword [ebp + 0xc]
pop edi
pop esi
pop ebp
ret

Function at 0x4b17bc
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x580ca0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, dword [ebp + 0xc]
test esi, esi
je 0x4b1866
movzx ecx, word [esi]
test cx, cx
je 0x4b1866
mov eax, esi
mov edx, esi
movzx ecx, cx
cmp cx, 0x2f
je 0x4b17fa
cmp cx, 0x5c
jne 0x4b17fc
mov eax, edx
inc edx
inc edx
movzx ecx, word [edx]
test cx, cx
jne 0x4b17ee
cmp eax, esi
je 0x4b183a
push edi
sub eax, esi
mov edi, eax
sar edi, 1
push edi
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.004c16cc
xor eax, eax
mov word [ebp + edi*2 - 0x20c], ax
lea eax, [ebp - 0x20c]
push eax
push ebx
call fcn.004b17bc
add esp, 0x14
pop edi
lea eax, [ebp - 0x414]
push ebx
push eax
call fcn.004b9dbc
lea eax, [ebp - 0x414]
push esi
push eax
call fcn.004b9d8e
add esp, 0x10
push 0
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.004ba1db
leave
ret
Function at 0x4b2d97
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ecx
cmp dword [esi], 0
jne 0x4b2e12
cmp dword [esi + 4], 0xffffffff
jne 0x4b2e12
push edi
lea edi, [esi + 0x138]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push 0x551458
push edi
call fcn.004b9d8e
cmp dword [ebp + 0x10], 1
pop ecx
pop ecx
pop edi
jne 0x4b2de4
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 1
je 0x4b2de4
mov eax, 0x2000000
jmp 0x4b2e17
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004b07d9
add esp, 0x10
test eax, eax
jne 0x4b2e02
mov eax, dword [ebp + 0x10]
jmp 0x4b2e17
push eax
call fcn.004b2993
mov dword [esi], eax
mov eax, dword [0x586a18]
pop ecx
jmp 0x4b2e17
mov eax, 0x1000000
pop esi
pop ebp
ret 0xc
Function at 0x4b5cad
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, eax
mov eax, dword [esi + 8]
push edi
mov edi, eax
and edi, 7
je 0x4b5cd2
cmp eax, edi
jge 0x4b5cca
mov eax, esi
call fcn.004b5661
mov ecx, edi
shr dword [esi + 0xc], cl
sub dword [esi + 8], edi
xor ecx, ecx
cmp dword [esi + 8], ecx
jle 0x4b5cf4
mov al, byte [esi + 0xc]
shr dword [esi + 0xc], 8
add dword [esi + 8], 0xfffffff8
mov byte [ebp + ecx - 4], al
inc ecx
cmp dword [esi + 8], 0
jg 0x4b5cd9
cmp ecx, 4
jge 0x4b5d13
mov edi, dword [esi + 4]
mov eax, dword [esi]
cmp eax, edi
jb 0x4b5d01
xor eax, eax
jmp 0x4b5d09
mov dl, byte [eax]
inc eax
mov dword [esi], eax
movzx eax, dl
mov byte [ebp + ecx - 4], al
inc ecx
cmp ecx, 4
jl 0x4b5cf7
movzx edi, byte [ebp - 3]
movzx eax, byte [ebp - 4]
movzx ecx, byte [ebp - 2]
shl edi, 8
add edi, eax
movzx eax, byte [ebp - 1]
shl eax, 8
add eax, ecx
mov ecx, edi
xor ecx, 0xffff
cmp eax, ecx
je 0x4b5d45
mov eax, str.zlib_corrupt
call fcn.004b327e
jmp 0x4b5d80
mov eax, dword [esi]
add eax, edi
cmp eax, dword [esi + 4]
jbe 0x4b5d55
mov eax, str.read_past_buffer
jmp 0x4b5d3e
mov eax, dword [esi + 0x10]
add eax, edi
cmp eax, dword [esi + 0x18]
jbe 0x4b5d6a
mov ecx, edi
call fcn.004b568c
test eax, eax
je 0x4b5d80
push edi
push dword [esi]
push dword [esi + 0x10]
call fcn.004bf1d0
add dword [esi], edi
add dword [esi + 0x10], edi
xor eax, eax
add esp, 0xc
inc eax
pop edi
pop esi
leave
ret

Function at 0x4ba1db
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x580ca0]
jne 0x4ba1e5
repz ret
jmp fcn.004c612c

Function at 0x4bf5c3
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
xor esi, esi
cmp dword [ebp + 8], esi
jne 0x4bf5f4
call fcn.004c00d6
mov dword [eax], esi
call fcn.004c00c3
push esi
push esi
push esi
push esi
push esi
mov dword [eax], 0x16
call fcn.004bd0db
add esp, 0x14
push 0x16
pop eax
jmp 0x4bf649
test dword [ebp + 0xc], 0xfffffff9
jne 0x4bf5d0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x4bf621
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.004c00e9
pop ecx
call fcn.004c00c3
mov eax, dword [eax]
jmp 0x4bf649
test al, 0x10
jne 0x4bf647
test al, 1
je 0x4bf647
test byte [ebp + 0xc], 2
je 0x4bf647
call fcn.004c00d6
mov dword [eax], 5
call fcn.004c00c3
mov dword [eax], 0xd
jmp 0x4bf618
xor eax, eax
pop esi
pop ebp
ret
Function at 0x4d7912
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.004c5a6b
and dword [ebp - 4], 0
cmp dword [0x587724], 0
mov ebx, eax
jne 0x4d79c3
push 0x53fc88
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x4d7a74
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x53fc7c
push edi
call esi
test eax, eax
je 0x4d7a74
push eax
call fcn.004c59f9
mov dword [esp], str.GetActiveWindow
push edi
mov dword [0x587724], eax
call esi
push eax
call fcn.004c59f9
mov dword [esp], str.GetLastActivePopup
push edi
mov dword [0x587728], eax
call esi
push eax
call fcn.004c59f9
mov dword [esp], str.GetUserObjectInformationA
push edi
mov dword [0x58772c], eax
call esi
push eax
call fcn.004c59f9
pop ecx
mov dword [0x587734], eax
test eax, eax
je 0x4d79c3
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.004c59f9
pop ecx
mov dword [0x587730], eax
mov eax, dword [0x587730]
cmp eax, ebx
je 0x4d7a1b
cmp dword [0x587734], ebx
je 0x4d7a1b
push eax
call fcn.004c5a74
push dword [0x587734]
mov esi, eax
call fcn.004c5a74
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x4d7a1b
test edi, edi
je 0x4d7a1b
call esi
test eax, eax
je 0x4d7a12
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x4d7a12
test byte [ebp - 0xc], 1
jne 0x4d7a1b
or dword [ebp + 0x10], 0x200000
jmp 0x4d7a54
mov eax, dword [0x587728]
cmp eax, ebx
je 0x4d7a54
push eax
call fcn.004c5a74
pop ecx
test eax, eax
je 0x4d7a54
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x4d7a54
mov eax, dword [0x58772c]
cmp eax, ebx
je 0x4d7a54
push eax
call fcn.004c5a74
pop ecx
test eax, eax
je 0x4d7a54
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x587724]
call fcn.004c5a74
pop ecx
test eax, eax
je 0x4d7a74
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x4d7a76
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret

Function at 0x4ece60
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x194
mov eax, dword [0x580ca0]
xor eax, esp
mov dword [esp + 0x190], eax
lea eax, [esp]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x4eceb2
mov eax, dword [esp]
cmp al, 2
jne 0x4eceac
shr eax, 8
cmp al, 2
jne 0x4eceac
xor eax, eax
mov ecx, dword [esp + 0x190]
xor ecx, esp
call fcn.004ba1db
add esp, 0x194
ret
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov ecx, dword [esp + 0x190]
xor ecx, esp
mov eax, 2
call fcn.004ba1db
add esp, 0x194
ret
Function at 0x4ee8c0
Capabilities:
Read file on windows

Disassembly:
push edi
mov edi, eax
mov eax, dword [esi]
cmp dword [eax + 4], 2
jne 0x4ee8e2
mov ecx, dword [esi + 0xc]
test ecx, ecx
jne 0x4ee8d6
xor eax, eax
pop edi
ret
mov eax, dword [eax + 8]
push eax
push edi
push 1
push ebx
call ecx
jmp 0x4ee912
cmp dword [esi + 8], 0
jne 0x4ee905
mov ecx, dword [eax + 8]
push 0x551080
push ecx
call fcn.004c01d0
add esp, 8
mov dword [esi + 8], eax
test eax, eax
jne 0x4ee905
or eax, 0xffffffff
pop edi
ret
mov edx, dword [esi + 8]
push edx
push edi
push 1
push ebx
call fcn.004c04bb
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4ee934
mov eax, dword [esi + 8]
test eax, eax
je 0x4ee92e
push eax
call fcn.004bb34d
add esp, 4
mov dword [esi + 8], edi
mov eax, dword [esi]
mov ecx, dword [eax]
mov dword [esi], ecx
mov eax, edi
pop edi
ret
Function at 0x4f8e40
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
push 0
push eax
push ecx
push edx
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
jne 0x4f8e72
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
sub eax, 0x2733
neg eax
sbb eax, eax
and eax, 0xffffffe7
add eax, 0x51
ret
mov ecx, dword [esp + 0x10]
mov dword [ecx], eax
xor eax, eax
ret

Function at 0x4f8fb0
Capabilities:
Write file on windows

Disassembly:
mov ecx, dword [esi + 0x1a8]
test ecx, ecx
je 0x4f8fcb
mov edx, dword [esi + 0x134]
push edx
push edi
push ebx
push eax
push esi
call ecx
add esp, 0x14
ret
test eax, eax
jl 0x4f8fff
cmp eax, 2
jg 0x4f8fff
mov ecx, dword [esi + 0x130]
push ecx
push 1
lea edx, [eax + eax*2 + 0x5428c0]
push 2
push edx
call fcn.004bb52b
mov eax, dword [esi + 0x130]
push eax
push 1
push edi
push ebx
call fcn.004bb52b
add esp, 0x20
xor eax, eax
ret

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

Disassembly:
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
mov eax, dword [esp + 8]
push ebx
push esi
mov esi, dword [esp + 0xc]
mov eax, dword [esi + eax*4 + 0x154]
push edi
push 0
push ecx
push edx
push eax
call dword [sym.imp.WS2_32.dll_send]
mov ebx, dword [esp + 0x20]
mov edi, eax
mov dword [ebx], 0
cmp edi, 0xffffffff
jne 0x4f938d
push ebp
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebp, eax
cmp ebp, 0x2733
jne 0x4f9364
pop ebp
pop edi
pop esi
mov dword [ebx], 0x51
xor eax, eax
pop ebx
ret
push ebp
push esi
call fcn.004edba0
push eax
mov eax, dword [esi]
push str.Send_failure:__s
push eax
call fcn.004f9190
mov ecx, dword [esi]
add esp, 0x14
mov dword [ecx + 0x8614], ebp
mov dword [ebx], 0x37
mov eax, edi
pop ebp
pop edi
pop esi
pop ebx
ret

Function at 0x4fb0e0
Capabilities:
Set socket configuration

Disassembly:
sub esp, 0x14
xor eax, eax
cmp dword [esi + 0x470], eax
push 4
lea ecx, [esp + 4]
push ecx
setne al
push 8
push 0xffff
push edi
mov dword [esp + 0x14], eax
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jge 0x4fb11e
push edi
push str.Failed_to_set_SO_KEEPALIVE_on_fd__d_n
push esi
call fcn.004f9100
add esp, 0xc
add esp, 0x14
ret
mov edx, dword [esi + 0x474]
push edx
mov dword [esp + 0xc], 1
call fcn.00510af0
imul eax, eax, 0x3e8
mov dword [esp + 4], eax
mov dword [esp + 0x10], eax
mov eax, dword [esi + 0x478]
push eax
call fcn.00510af0
imul eax, eax, 0x3e8
add esp, 8
push 0
push 0
lea ecx, [esp + 0xc]
push ecx
push 0
push 0
push 0xc
lea edx, [esp + 0x20]
push edx
push 0x98000004
push edi
mov dword [esp + 0x24], eax
mov dword [esp + 0x34], eax
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x4fb197
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
push str.Failed_to_set_SIO_KEEPALIVE_VALS_on_fd__d:__d_n
push esi
call fcn.004f9100
add esp, 0x10
add esp, 0x14
ret
Function at 0x4fb790
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
sub esp, 0x10c
mov eax, dword [0x580ca0]
xor eax, esp
mov dword [esp + 0x108], eax
push ebp
mov ebp, dword [esp + 0x114]
cmp dword [ebp + 0x8c], 2
push edi
mov edi, dword [ebp]
mov dword [esp + 0xc], edi
je 0x4fb905
cmp dword [ebp + 0x1d8], 0
push ebx
push esi
jne 0x4fb8fa
mov esi, dword [esp + 0x124]
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x9c]
push ecx
mov ebx, 0x80
push esi
mov dword [esp + 0x1c], ebx
call dword [sym.imp.WS2_32.dll_getpeername]
test eax, eax
je 0x4fb81c
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
push esi
push ebp
call fcn.004edba0
push eax
push esi
push str.getpeername___failed_with_errno__d:__s
push edi
call fcn.004f9190
add esp, 0x18
jmp 0x4fb903
push ebx
lea edx, [esp + 0x1c]
push 0
push edx
mov dword [esp + 0x1c], ebx
call fcn.004ba280
add esp, 0xc
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x1c]
push ecx
push esi
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x4fb869
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
push esi
push ebp
call fcn.004edba0
push eax
push esi
push str.getsockname___failed_with_errno__d:__s
push edi
call fcn.004f9190
add esp, 0x18
jmp 0x4fb903
lea edi, [ebp + 0xb8]
lea ebx, [ebp + 0xe8]
lea esi, [esp + 0x98]
call fcn.004fb750
test eax, eax
jne 0x4fb8aa
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push ebp
call fcn.004edba0
mov edx, dword [esp + 0x1c]
push eax
push esi
push str.ssrem_inet_ntop___failed_with_errno__d:__s
push edx
call fcn.004f9190
add esp, 0x18
jmp 0x4fb903
lea edi, [ebp + 0x58]
mov ecx, 0xb
lea esi, [ebp + 0xb8]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
lea ebx, [ebp + 0x11c]
lea edi, [ebp + 0xec]
lea esi, [esp + 0x18]
call fcn.004fb750
test eax, eax
jne 0x4fb8fa
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push ebp
call fcn.004edba0
push eax
mov eax, dword [esp + 0x20]
push esi
push str.ssloc_inet_ntop___failed_with_errno__d:__s
push eax
call fcn.004f9190
add esp, 0x18
jmp 0x4fb903
push ebp
call fcn.004fb6f0
add esp, 4
pop esi
pop ebx
mov ecx, dword [esp + 0x110]
pop edi
pop ebp
xor ecx, esp
call fcn.004ba1db
add esp, 0x10c
ret

Function at 0x4fb920
Capabilities:
Set socket configuration

Disassembly:
push ecx
push esi
mov esi, dword [edi]
mov eax, dword [esi + 0x364]
push 4
lea ecx, [esp + 8]
push ecx
push 1
push 6
push edx
mov dword [esp + 0x18], eax
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jge 0x4fb963
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.004edba0
push eax
push str.Could_not_set_TCP_NODELAY:__s_n
push esi
call fcn.004f9100
add esp, 0x14
pop esi
pop ecx
ret
push str.TCP_NODELAY_set_n
push esi
call fcn.004f9100
add esp, 8
pop esi
pop ecx
ret
Function at 0x4fb980
Capabilities:
Set socket configuration

Disassembly:
sub esp, 0xac
mov eax, dword [0x580ca0]
xor eax, esp
mov dword [esp + 0xa8], eax
mov eax, dword [0x587980]
push esi
mov dword [esp + 4], 0x4020
mov dword [esp + 8], 0
mov dword [esp + 0xc], 4
test eax, eax
jne 0x4fba44
push 0x9c
push eax
lea eax, [esp + 0x18]
push eax
call fcn.004ba280
mov esi, dword [sym.imp.KERNEL32.dll_VerSetConditionMask]
add esp, 0xc
push 3
push 2
push 0
push 0
mov dword [esp + 0x20], 0x9c
mov dword [esp + 0x24], 6
call esi
push 3
push 1
push edx
push eax
call esi
push 3
push 0x20
push edx
push eax
call esi
push 3
push 0x10
push edx
push eax
call esi
push edx
push eax
push 0x33
lea ecx, [esp + 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_VerifyVersionInfoA]
test eax, eax
je 0x4fba38
mov dword [0x587980], 2
pop esi
mov ecx, dword [esp + 0xa8]
xor ecx, esp
call fcn.004ba1db
add esp, 0xac
ret
mov dword [0x587980], 1
jmp 0x4fba49
cmp eax, 2
je 0x4fba91
mov esi, dword [esp + 0xb4]
lea edx, [esp + 0xc]
push edx
lea eax, [esp + 0xc]
push eax
push 0x1001
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x4fba79
mov ecx, dword [esp + 8]
cmp ecx, dword [esp + 4]
jg 0x4fba91
push 4
lea edx, [esp + 8]
push edx
push 0x1001
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
mov ecx, dword [esp + 0xac]
pop esi
xor ecx, esp
call fcn.004ba1db
add esp, 0xac
ret

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

Disassembly:
sub esp, 8
push esi
push edi
mov edi, dword [esp + 0x14]
mov esi, dword [edi + 0x5d8]
test esi, esi
je 0x4fbb29
mov eax, dword [edi + 0x44]
test eax, eax
jne 0x4fbaef
cmp dword [edi + 0x40], eax
je 0x4fbb29
mov dword [esp + 8], esi
mov dword [esp + 0xc], 0
test eax, eax
jne 0x4fbb02
mov eax, dword [edi + 0x40]
push 0x4fbab0
lea ecx, [esp + 0xc]
add eax, 0x68
push ecx
push eax
call fcn.00516190
add esp, 0xc
cmp dword [esp + 0xc], 0
jne 0x4fbb32
mov dword [edi + 0x5d8], 0
pop edi
or eax, 0xffffffff
pop esi
add esp, 8
ret
mov eax, dword [esp + 0x18]
test eax, eax
je 0x4fbb3c
mov dword [eax], esi
cmp dword [esi + 0x17c], 0
mov edi, dword [esi + 0x154]
jne 0x4fbb29
push 2
push 1
lea edx, [esp + 0x1c]
push edx
push edi
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
je 0x4fbb29
mov eax, edi
pop edi
pop esi
add esp, 8
ret