joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40c590
Capabilities:
Connect pipe
Create pipe
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_CreateNamedPipeW]
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [0x4b4fd8], 1
push 0
push 0
push 0x400
push 0x400
push 0xff
push 0
push 3
push str..pipe46A9CBD7_15C4_44D7_A660_DD80F2816DB6
call ebx
mov esi, eax
cmp esi, 0xffffffff
je 0x40c620
push 0
push esi
call dword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
test eax, eax
jne 0x40c601
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ecx, ecx
cmp eax, 0x217
sete cl
test ecx, ecx
jne 0x40c601
push esi
call edi
jmp 0x40c617
lea eax, [ebp - 8]
push eax
push 0
push esi
push 0x40c640
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp byte [0x4b4fd8], 0
jne 0x40c5b6
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret

Function at 0x40d260
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, edx
push edi
cmp dword [esi + 0x14], 8
mov edi, ecx
mov dword [ebp - 0xc], 0
jb 0x40d287
mov eax, dword [esi]
jmp 0x40d289
mov eax, esi
push 0
lea ecx, [ebp - 8]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
xor ecx, ecx
push ecx
dec eax
mov dword [edi + 0x14], 7
mov dword [edi + 0x10], 0
mov word [edi], cx
push eax
mov ecx, edi
call fcn.00403810
cmp dword [edi + 0x14], 8
mov ecx, dword [edi + 0x10]
jb 0x40d2c0
mov eax, dword [edi]
jmp 0x40d2c2
mov eax, edi
cmp dword [esi + 0x14], 8
jb 0x40d2ca
mov esi, dword [esi]
inc ecx
push ecx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
xor ecx, ebp
pop esi
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
Function at 0x40d2f0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x493ba6
mov eax, dword fs:[0]
push eax
sub esp, 0xa4
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0xb0], 0
mov dword [ebp - 0x94], 0
mov dword [ebp - 0x90], 0
mov dword [ebp - 0x8c], 0
lea eax, [ebp - 0x80]
push eax
push 0x20019
push 0
push str.SoftwareMicrosoftNET_Framework_SetupNDP
push reloc.WS2_32.dll_bind
mov dword [ebp - 4], 0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x40d387
mov dword [edi], 0
mov dword [edi + 4], 0
mov dword [edi + 8], 0
jmp 0x40d47b
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor esi, esi
nop
lea eax, [ebp - 0x84]
push eax
push 0x20019
push 0
push dword [esi + 0x4b1a34]
push dword [ebp - 0x80]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x40d450
lea eax, [ebp - 0x88]
push eax
lea eax, [ebp - 0x78]
push eax
lea eax, [ebp - 0x7c]
push eax
push 0
push str.Version
push dword [ebp - 0x84]
mov dword [ebp - 0x88], 0x64
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40d448
cmp dword [ebp - 0x7c], 1
jne 0x40d448
push dword [ebp - 0x88]
mov dword [ebp - 0x9c], eax
mov word [ebp - 0xac], ax
lea eax, [ebp - 0x78]
push eax
lea ecx, [ebp - 0xac]
mov dword [ebp - 0x98], 7
call fcn.00403710
lea eax, [ebp - 0xac]
push eax
lea ecx, [ebp - 0x94]
mov byte [ebp - 4], 1
call fcn.00403290
mov byte [ebp - 4], 0
cmp dword [ebp - 0x98], 8
jb 0x40d448
push dword [ebp - 0xac]
call fcn.0045b2a0
add esp, 4
push dword [ebp - 0x84]
call ebx
add esi, 4
cmp esi, 0x1c
jb 0x40d390
push dword [ebp - 0x80]
call ebx
mov eax, dword [ebp - 0x94]
mov dword [edi], eax
mov eax, dword [ebp - 0x90]
mov dword [edi + 4], eax
mov eax, dword [ebp - 0x8c]
mov dword [edi + 8], eax
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
Function at 0x40d680
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x493b28
mov eax, dword fs:[0]
push eax
sub esp, 0x24
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
lea eax, [ebp - 0x14]
push eax
push 0
mov dword [ebp - 0x30], 0
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
xor ecx, ecx
push 0x20
mov word [ebp - 0x2c], cx
push eax
lea ecx, [ebp - 0x2c]
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], 0
call fcn.00403810
mov dword [ebp - 4], 0
cmp dword [ebp - 0x18], 8
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
push ecx
lea edx, [ebp - 0x2c]
mov ecx, edi
call fcn.0040e430
add esp, 4
cmp dword [ebp - 0x18], 8
jb 0x40d718
push dword [ebp - 0x2c]
call fcn.0045b2a0
add esp, 4
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
Function at 0x40dc80
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
mov eax, ecx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
mov dword [ebp - 4], eax
mov esi, 5
mov ecx, eax
call fcn.004029f0
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
setne bl
test bl, bl
jne 0x40dcbb
push 0x3e8
call edi
mov eax, dword [ebp - 4]
dec esi
jne 0x40dc97
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x40dcd0
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
mov eax, edx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
mov dword [ebp - 8], eax
mov dword [ebp - 4], ecx
mov esi, 5
lea esp, [esp]
push 0
mov ecx, eax
call fcn.004029f0
mov ecx, dword [ebp - 4]
push eax
call fcn.004029f0
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
setne bl
test bl, bl
jne 0x40dd1f
push 0x3e8
call edi
mov eax, dword [ebp - 8]
dec esi
jne 0x40dcf0
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x40dd30
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
mov eax, edx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
mov dword [ebp - 8], eax
mov dword [ebp - 4], ecx
mov esi, 5
lea esp, [esp]
push 0xb
mov ecx, eax
call fcn.004029f0
mov ecx, dword [ebp - 4]
push eax
call fcn.004029f0
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
setne bl
test bl, bl
jne 0x40dd7f
push 0x3e8
call edi
mov eax, dword [ebp - 8]
dec esi
jne 0x40dd50
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x40de10
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push 0
mov ebx, ecx
push 0x100
lea ecx, [ebp - 0x1c]
mov esi, edx
mov dword [ebp - 8], 0xf
mov dword [ebp - 0xc], 0
mov byte [ebp - 0x1c], 0
call fcn.00404860
cmp dword [ebp - 8], 0x10
push 0x100
lea eax, [ebp - 0x1c]
cmovae eax, dword [ebp - 0x1c]
push 0
push eax
call fcn.0045eaa0
add esp, 0xc
cmp dword [ebp - 8], 0x10
lea eax, [ebp - 0x1c]
cmovae eax, dword [ebp - 0x1c]
mov dword [ebp - 0xc], 0x100
mov byte [eax + 0x100], 0
call fcn.0040f960
mov edi, eax
test edi, edi
je 0x40dec1
cmp dword [esi + 0x14], 8
jb 0x40de91
mov eax, dword [esi]
jmp 0x40de93
mov eax, esi
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp dword [esi + 0x14], 8
jb 0x40dea2
mov esi, dword [esi]
push 0x4a4c44
lea eax, [ebp - 0x20]
push esi
push eax
call fcn.0045c71b
add esp, 0xc
test eax, eax
je 0x40dee7
push edi
call fcn.0040f940
add esp, 4
xor bl, bl
cmp dword [ebp - 8], 0x10
jb 0x40ded4
push dword [ebp - 0x1c]
call fcn.0045b2a0
add esp, 4
mov ecx, dword [ebp - 4]
pop edi
pop esi
mov al, bl
xor ecx, ebp
pop ebx
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
cmp dword [ebx + 0x14], 0x10
jb 0x40deef
mov ebx, dword [ebx]
push ebx
push 0x2712
push edi
call fcn.0040f9c0
push 0x40de00
push 0x4e2b
push edi
call fcn.0040f9c0
push dword [ebp - 0x20]
push 0x2711
push edi
call fcn.0040f9c0
push 0x708
push 0xd
push edi
call fcn.0040f9c0
cmp dword [ebp - 8], 0x10
lea eax, [ebp - 0x1c]
cmovae eax, dword [ebp - 0x1c]
push eax
push 0x271a
push edi
call fcn.0040f9c0
push edi
call fcn.0040f9a0
add esp, 0x40
mov esi, eax
push edi
call fcn.0040f940
push dword [ebp - 0x20]
call fcn.0045bf73
add esp, 8
test esi, esi
jne 0x40dec1
mov bl, 1
jmp 0x40dec3

Function at 0x40df70
Capabilities:
Get file attributes
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ecx
push edi
cmp dword [esi + 0x14], 8
mov edi, edx
jb 0x40df83
mov eax, dword [esi]
jmp 0x40df85
mov eax, esi
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp dword [esi + 0x14], 8
mov ecx, eax
jb 0x40df96
mov esi, dword [esi]
mov eax, dword [ebp + 8]
or ecx, edi
not eax
and ecx, eax
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
pop edi
pop esi
pop ebp
ret
Function at 0x40dfb0
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x493a2b
mov eax, dword fs:[0]
push eax
sub esp, 0x834
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
cmp dword [ecx + 0x14], 8
jb 0x40dfe4
mov ecx, dword [ecx]
push 0x100
lea eax, [ebp - 0x228]
push eax
push 0x100
lea eax, [ebp - 0x428]
push eax
push 0x100
lea eax, [ebp - 0x628]
push eax
push 0x100
lea eax, [ebp - 0x828]
push eax
push ecx
call fcn.0045cb0a
xor eax, eax
add esp, 0x24
mov dword [ebp - 0x82c], 7
mov dword [ebp - 0x830], 0
mov word [ebp - 0x840], ax
cmp word [ebp - 0x828], ax
jne 0x40e047
xor ecx, ecx
jmp 0x40e05f
lea ecx, [ebp - 0x828]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40e050
sub ecx, edx
sar ecx, 1
push ecx
lea eax, [ebp - 0x828]
push eax
lea ecx, [ebp - 0x840]
call fcn.00403710
lea eax, [ebp - 0x628]
push eax
lea edx, [ebp - 0x840]
lea ecx, [ebp - 0x28]
mov dword [ebp - 4], 0
call fcn.00409ee0
add esp, 4
cmp dword [ebp - 0x82c], 8
jb 0x40e0a8
push dword [ebp - 0x840]
call fcn.0045b2a0
add esp, 4
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push 0
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
test eax, eax
je 0x40e0d2
cmp eax, 0x50
je 0x40e0d2
cmp eax, 0xb7
je 0x40e0d2
xor bl, bl
jmp 0x40e0d4
mov bl, 1
cmp dword [ebp - 0x14], 8
jb 0x40e0e5
push dword [ebp - 0x28]
call fcn.0045b2a0
add esp, 4
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
Function at 0x40e110
Capabilities:
Read file on windows
Read pipe

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x493c38
mov eax, dword fs:[0]
push eax
sub esp, 0x38
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x3c], edx
mov dword [ebp - 0x38], ecx
mov ebx, dword [ebp + 8]
mov edi, dword [ebp - 0x38]
xor eax, eax
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x18], eax
mov esi, edx
test ebx, ebx
je 0x40e180
push 0
lea eax, [ebp - 0x34]
push eax
push 0
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_PeekNamedPipe]
push 0x64
mov edi, eax
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [ebp - 0x34]
test eax, eax
je 0x40e158
mov esi, dword [ebp - 0x38]
test edi, edi
je 0x40e234
test eax, eax
je 0x40e234
push 0
push eax
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x1c], 0xf
mov dword [ebp - 0x20], 0
mov byte [ebp - 0x30], 0
call fcn.00407380
mov edx, dword [ebp - 0x3c]
push 0
mov dword [ebp - 4], 0
cmp dword [ebp - 0x1c], 0x10
lea ecx, [ebp - 0x18]
push ecx
push dword [ebp - 0x34]
lea eax, [ebp - 0x30]
cmovae eax, dword [ebp - 0x30]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40e223
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x20]
cmp ecx, eax
ja 0x40e1f8
cmp dword [ebp - 0x1c], 0x10
lea eax, [ebp - 0x30]
cmovae eax, dword [ebp - 0x30]
mov dword [ebp - 0x20], ecx
mov byte [eax + ecx], 0
jmp 0x40e205
sub ecx, eax
push 0
push ecx
lea ecx, [ebp - 0x30]
call fcn.00406d20
lea eax, [ebp - 0x30]
push eax
mov ecx, esi
call fcn.0040b840
cmp dword [ebp - 0x1c], 0x10
jb 0x40e245
push dword [ebp - 0x30]
call fcn.0045b2a0
add esp, 4
jmp 0x40e245
cmp dword [ebp - 0x1c], 0x10
jb 0x40e234
push dword [ebp - 0x30]
call fcn.0045b2a0
add esp, 4
mov dword [esi + 0x14], 0xf
mov dword [esi + 0x10], 0
mov byte [esi], 0
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret

Function at 0x40e270
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [edx + 0x14], 8
mov eax, dword [edx + 0x10]
push ebx
push esi
mov esi, ecx
jb 0x40e28f
mov edx, dword [edx]
add eax, eax
push eax
push edx
lea ecx, [ebp - 0x20]
mov dword [ebp - 0xc], 0xf
mov dword [ebp - 0x10], 0
mov byte [ebp - 0x20], 0
call fcn.00403c50
cmp dword [ebp - 0xc], 0x10
push 0
lea ecx, [ebp - 8]
push ecx
push dword [ebp - 0x10]
lea eax, [ebp - 0x20]
cmovae eax, dword [ebp - 0x20]
push eax
push esi
mov dword [ebp - 8], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40e2e0
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 0x10]
jne 0x40e2e0
mov bl, 1
jmp 0x40e2e2
xor bl, bl
cmp dword [ebp - 0xc], 0x10
jb 0x40e2f3
push dword [ebp - 0x20]
call fcn.0045b2a0
add esp, 4
mov ecx, dword [ebp - 4]
pop esi
mov al, bl
xor ecx, ebp
pop ebx
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
Function at 0x40fc60
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x194
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 4], eax
lea eax, [ebp - 0x194]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x40fcb0
mov eax, dword [ebp - 0x194]
cmp al, 2
jne 0x40fcaa
shr eax, 8
cmp al, 2
jne 0x40fcaa
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov ecx, dword [ebp - 4]
xor ecx, ebp
mov eax, 2
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
Function at 0x41b9b0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 8]
push ebx
push edi
push 0
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ecx + eax*4 + 0x154]
call dword [sym.imp.WS2_32.dll_send]
mov ebx, dword [ebp + 0x18]
mov edi, eax
mov dword [ebx], 0
cmp edi, 0xffffffff
jne 0x41ba2e
push esi
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
cmp esi, 0x2733
jne 0x41b9fe
pop esi
pop edi
mov dword [ebx], 0x51
xor eax, eax
pop ebx
pop ebp
ret
push esi
push dword [ebp + 8]
call fcn.004274c0
push eax
mov eax, dword [ebp + 8]
push str.Send_failure:__s
push dword [eax]
call fcn.0041b6a0
mov eax, dword [ebp + 8]
add esp, 0x14
mov eax, dword [eax]
mov dword [eax + 0x85fc], esi
mov dword [ebx], 0x37
mov eax, edi
pop esi
pop edi
pop ebx
pop ebp
ret

Function at 0x41bc10
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
mov eax, dword [esi + 0x1a8]
test eax, eax
je 0x41bc39
push dword [esi + 0x134]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push esi
call eax
add esp, 0x14
pop esi
pop ebp
ret
mov eax, dword [ebp + 0xc]
cmp eax, 2
ja 0x41bc6f
push dword [esi + 0x130]
lea eax, [eax + eax*2]
push 1
add eax, 0x495078
push 2
push eax
call fcn.0045be89
push dword [esi + 0x130]
push 1
push dword [ebp + 0x14]
push dword [ebp + 0x10]
call fcn.0045be89
add esp, 0x20
xor eax, eax
pop esi
pop ebp
ret

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push esi
push edi
mov edi, dword [ebp + 8]
mov esi, dword [edi + 0x5c0]
test esi, esi
je 0x41be1a
mov eax, dword [edi + 0x44]
test eax, eax
je 0x41be1a
push 0x41cb40
lea ecx, [ebp - 8]
push ecx
mov dword [ebp - 8], esi
mov dword [ebp - 4], 0
push dword [eax + 0x34]
call fcn.00424920
add esp, 0xc
cmp dword [ebp - 4], 0
jne 0x41be23
mov dword [edi + 0x5c0], 0
pop edi
or eax, 0xffffffff
pop esi
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x41be2c
mov dword [eax], esi
cmp dword [esi + 0x17c], 0
mov edi, dword [esi + 0x154]
jne 0x41be1a
push 2
push 1
lea eax, [ebp + 0xb]
push eax
push edi
call dword [sym.imp.WS2_32.dll_recv]
or ecx, 0xffffffff
test eax, eax
cmove edi, ecx
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x41c210
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xac
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [0x4b1ad0]
mov dword [ebp - 0xa4], 0x4020
mov dword [ebp - 0xa8], 0
mov dword [ebp - 0xac], 4
test eax, eax
jne 0x41c2ba
push 0x9c
push eax
lea eax, [ebp - 0xa0]
push eax
call fcn.0045eaa0
add esp, 0xc
mov dword [ebp - 0xa0], 0x9c
push 3
push 2
push 0
push 0
mov dword [ebp - 0x9c], 6
call dword [sym.imp.KERNEL32.dll_VerSetConditionMask]
push edx
push eax
push 2
lea eax, [ebp - 0xa0]
push eax
call dword [sym.imp.KERNEL32.dll_VerifyVersionInfoA]
test eax, eax
je 0x41c2ae
mov dword [0x4b1ad0], 2
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
mov dword [0x4b1ad0], 1
jmp 0x41c2bf
cmp eax, 2
je 0x41c30e
lea eax, [ebp - 0xac]
push eax
lea eax, [ebp - 0xa8]
push eax
push 0x1001
push 0xffff
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x41c2f2
mov eax, dword [ebp - 0xa8]
cmp eax, dword [ebp - 0xa4]
jg 0x41c30e
push 4
lea eax, [ebp - 0xa4]
push eax
push 0x1001
push 0xffff
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_setsockopt]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
Function at 0x41c4b0
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push edi
cmp dword [ebx + 0x8c], 2
mov edi, dword [ebx]
mov dword [ebp - 0x10c], edi
je 0x41c667
cmp dword [ebx + 0x1d0], 0
push esi
jne 0x41c65d
mov esi, dword [ebp + 0xc]
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x104]
push eax
push esi
mov dword [ebp - 0x108], 0x80
call dword [sym.imp.WS2_32.dll_getpeername]
test eax, eax
je 0x41c541
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
push esi
push ebx
call fcn.004274c0
push eax
push esi
push str.getpeername___failed_with_errno__d:__s
push edi
call fcn.0041b6a0
add esp, 0x18
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
push 0x80
lea eax, [ebp - 0x84]
push 0
push eax
mov dword [ebp - 0x108], 0x80
call fcn.0045eaa0
add esp, 0xc
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x84]
push eax
push esi
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x41c5aa
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
push esi
push ebx
call fcn.004274c0
push eax
push esi
push str.getsockname___failed_with_errno__d:__s
push edi
call fcn.0041b6a0
add esp, 0x18
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
lea eax, [ebx + 0xe8]
push eax
lea esi, [ebx + 0xb8]
lea eax, [ebp - 0x104]
push esi
push eax
call fcn.0041cb60
add esp, 0xc
test eax, eax
jne 0x41c5fb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push ebx
call fcn.004274c0
push eax
push esi
push str.ssrem_inet_ntop___failed_with_errno__d:__s
push edi
call fcn.0041b6a0
add esp, 0x18
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
lea edi, [ebx + 0x58]
mov ecx, 0xb
rep movsd dword es:[edi], dword [esi]
lea eax, [ebx + 0x11c]
push eax
lea eax, [ebx + 0xec]
push eax
lea eax, [ebp - 0x84]
push eax
movsw word es:[edi], word [esi]
call fcn.0041cb60
add esp, 0xc
test eax, eax
jne 0x41c65d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push ebx
call fcn.004274c0
push eax
push esi
push str.ssloc_inet_ntop___failed_with_errno__d:__s
push dword [ebp - 0x10c]
call fcn.0041b6a0
add esp, 0x18
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
push ebx
call fcn.0041c1b0
add esp, 4
pop esi
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
Function at 0x41cef0
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x4aeea0]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
xor eax, eax
cmp dword [esi + 0x464], eax
push edi
mov edi, dword [ebp + 0xc]
setne al
push 4
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x14]
push eax
push 8
push 0xffff
push edi
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x41cf4d
push edi
push str.Failed_to_set_SO_KEEPALIVE_on_fd__d_n
push esi
call fcn.0041b740
add esp, 0xc
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret
push dword [esi + 0x468]
mov dword [ebp - 0x10], 1
call fcn.00424660
imul eax, eax, 0x3e8
push dword [esi + 0x46c]
mov dword [ebp - 0x14], eax
mov dword [ebp - 0xc], eax
call fcn.00424660
imul eax, eax, 0x3e8
add esp, 8
mov dword [ebp - 0x14], eax
push 0
push 0
mov dword [ebp - 8], eax
lea eax, [ebp - 0x18]
push eax
push 0
push 0
push 0xc
lea eax, [ebp - 0x10]
push eax
push 0x98000004
push edi
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x41cfbd
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.0041b740
add esp, 0x10
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0045a8cf
mov esp, ebp
pop ebp
ret

Function at 0x41cfd0
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
mov edi, dword [ebp + 8]
push 4
mov esi, dword [edi]
mov eax, dword [esi + 0x35c]
mov dword [ebp + 8], eax
lea eax, [ebp + 8]
push eax
push 1
push 6
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x41d01a
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push edi
call fcn.004274c0
push eax
push str.Could_not_set_TCP_NODELAY:__s_n
push esi
call fcn.0041b740
add esp, 0x14
pop edi
pop esi
pop ebp
ret
push str.TCP_NODELAY_set_n
push esi
call fcn.0041b740
add esp, 8
pop edi
pop esi
pop ebp
ret