Function at 0x100027e0
Capabilities:
Delete file
Get file size
Get socket status
Receive data
Receive data on socket
Set socket configuration

Disassembly:
sub esp, 0x534
cmp dword [esp + 0x544], 0
push ebx
push esi
push edi
push ebp
je 0x10002eb1
mov eax, dword [esp + 0x554]
cmp byte [eax], 0
je 0x10002eb1
push 0
push eax
call dword [sym.imp.KERNEL32.dll__lopen]
cmp eax, 0xffffffff
mov esi, eax
je 0x10002eb1
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push eax
mov edi, eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ebx, eax
test ebx, ebx
jne 0x10002842
push esi
call dword [sym.imp.KERNEL32.dll__lclose]
jmp 0x10002eb1
push edi
push ebx
push esi
call dword [sym.imp.KERNEL32.dll__lread]
push esi
call dword [sym.imp.KERNEL32.dll__lclose]
mov eax, dword [ebx]
mov ecx, dword [ebx + 4]
mov edx, dword [ebx + 8]
mov dword [esp + 0x30], eax
mov eax, dword [ebx + 0xc]
mov ebp, dword [ebx + 0x14]
lea edi, [esp + 0x144]
mov dword [esp + 0x34], ecx
mov ecx, pe_nt_image_headers32
mov dword [esp + 0x18], edx
mov edx, dword [ebx + 0x10]
mov dword [esp + 0x38], eax
mov eax, dword [ebx + 0x18]
mov dword [esp + 0x10], eax
xor eax, eax
rep stosd dword es:[edi], eax
lea edi, [esp + 0x344]
mov ecx, pe_nt_image_headers32
rep stosd dword es:[edi], eax
lea esi, [ebx + 0x1c]
lea edi, [esp + 0x144]
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x344]
lea esi, [ebx + edx + 0x1c]
mov ecx, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
add edx, ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea esi, [edx + ebx + 0x1c]
mov eax, dword [esp + 0x10]
shl eax, 3
sub eax, dword [esp + 0x10]
shl eax, 2
mov dword [esp + 0x2c], eax
push eax
mov dword [esp + 0x20], eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [esp + 0x14], eax
test eax, eax
je 0x10002eb1
mov edx, dword [esp + 0x1c]
mov edi, dword [esp + 0x14]
xor eax, eax
mov ecx, edx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov eax, dword [esp + 0x2c]
mov edi, dword [esp + 0x14]
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov ecx, dword [esp + 0x548]
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0x14]
test edx, edx
mov dword [ecx + 0x2440], edx
mov dword [ecx + 0x2444], eax
je 0x10002989
lea edi, [eax + 0x14]
mov esi, edx
xor ebx, ebx
push 0x2000
add edi, 0x1c
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x30]
mov dword [edi - 0x1c], eax
lea eax, [esp + 0x144]
push eax
mov dword [edi - 0x18], ebx
push ecx
lea eax, [edi - 0x30]
push edx
push eax
call fcn.10001990
dec esi
jne 0x10002955
xor esi, esi
cmp dword [esp + 0x10], esi
je 0x100029b9
mov edi, dword [esp + 0x14]
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x1e
call ebx
cmp dword [edi], 0
jne 0x100029b9
push edi
call fcn.10001a80
cmp dword [edi], 0
jne 0x100029b9
add edi, 0x1c
inc esi
cmp dword [esp + 0x10], esi
ja 0x1000299b
call dword [sym.imp.WINMM.dll_timeGetTime]
mov dword [esp + 0x20], 0
mov dword [esp + 0x28], eax
cmp dword [esp + 0x38], 0
je 0x100029f2
cmp dword [esp + 0x10], 0
je 0x100029f2
mov edi, dword [esp + 0x14]
mov esi, dword [esp + 0x10]
cmp dword [edi], 0
jne 0x100029ec
push edi
call fcn.10001a80
add edi, 0x1c
dec esi
jne 0x100029e1
mov dword [esp + 0x40], 0
cmp dword [esp + 0x10], 0
je 0x10002a4a
mov ecx, dword [esp + 0x14]
mov edi, dword [esp + 0x10]
xor ebx, ebx
mov ebp, 0x40
mov esi, dword [ecx]
test esi, esi
je 0x10002a44
xor edx, edx
cmp dword [esp + 0x40], ebx
jbe 0x10002a30
lea eax, [esp + 0x44]
cmp dword [eax], esi
je 0x10002a30
add eax, 4
inc edx
cmp edx, dword [esp + 0x40]
jb 0x10002a22
cmp dword [esp + 0x40], edx
jne 0x10002a44
cmp dword [esp + 0x40], ebp
jae 0x10002a44
mov dword [esp + edx*4 + 0x44], esi
inc dword [esp + 0x40]
add ecx, 0x1c
dec edi
jne 0x10002a10
lea eax, [esp + 0x40]
push 0
mov ecx, dword [esp + 0x14]
push 0
push 0
push eax
push ecx
call dword [sym.imp.WSOCK32.dll_select]
cmp eax, 0xffffffff
je 0x10002d21
test eax, eax
jle 0x10002d21
cmp dword [esp + 0x10], 0
je 0x10002c8b
mov ebx, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
add ebx, 8
mov dword [esp + 0x24], ecx
mov eax, dword [ebx - 8]
test eax, eax
je 0x10002c7e
lea ecx, [esp + 0x40]
push ecx
push eax
call sub.WSOCK32.dll___WSAFDIsSet
test eax, eax
je 0x10002c7e
mov dword [esp + 0x1c], 0
lea eax, [esp + 0x1c]
mov ecx, dword [ebx - 8]
push eax
push 0x4004667f
push ecx
call dword [sym.imp.WSOCK32.dll_ioctlsocket]
cmp eax, 0xffffffff
je 0x10002c68
cmp dword [esp + 0x1c], 0x2000
jbe 0x10002ae0
mov dword [esp + 0x1c], 0x2000
mov esi, dword [esp + 0x548]
push 0
add esi, 0x418
mov eax, dword [esp + 0x20]
push eax
mov ecx, dword [ebx - 8]
push esi
push ecx
call dword [sym.imp.WSOCK32.dll_recv]
cmp eax, 0xffffffff
jne 0x10002b0f
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
jmp 0x10002c68
test eax, eax
jne 0x10002b2c
cmp dword [esp + 0x18], 0
jne 0x10002c68
mov eax, dword [ebx]
mov dword [esp + 0x18], eax
mov dword [ebx + 4], eax
jmp 0x10002c68
mov ebp, eax
mov edi, dword [ebx + 0xc]
test edi, edi
je 0x10002c24
add edi, dword [ebx + 8]
mov ecx, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [ebx + 8]
add eax, ebp
push eax
mov dword [ebx + 8], eax
mov ecx, dword [ebx + 0xc]
push ecx
call fcn.10001740
mov dword [esp + 0x1c], eax
test eax, eax
je 0x10002c7e
push 0
mov ecx, dword [ebx + 0xc]
lea edx, [esp + 0x40]
push eax
mov eax, dword [esp + 0x550]
push ecx
push edx
push eax
call fcn.10001240
test eax, eax
je 0x10002c68
mov edx, dword [ebx]
mov edi, dword [ebx - 4]
add edi, edx
cmp edi, dword [esp + 0x3c]
je 0x10002bc6
mov eax, dword [esp + 0x54c]
cmp dword [ebx + 0x10], eax
jae 0x10002c68
lea eax, [esp + 0x144]
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x30]
push eax
push ecx
lea eax, [ebx - 8]
push edx
push eax
call fcn.10001c70
jmp 0x10002c7e
mov esi, dword [ebx + 8]
mov eax, dword [ebx + 4]
sub esi, dword [esp + 0x1c]
test eax, eax
je 0x10002bdf
lea ecx, [edx + esi]
cmp ecx, eax
jbe 0x10002bdf
mov esi, eax
sub esi, edx
push esi
mov eax, dword [ebx + 0xc]
add eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x554]
mov edx, dword [esp + 0x54c]
push eax
push edi
push ecx
push 0xffffffffffffffff
push edx
call fcn.10001690
mov ecx, dword [ebx]
add ecx, esi
mov dword [ebx], ecx
mov eax, dword [ebx + 4]
test eax, eax
je 0x10002c11
cmp ecx, eax
jae 0x10002c68
mov eax, dword [ebx + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebx + 0xc], 0
jmp 0x10002c76
mov edx, dword [ebx]
mov ecx, dword [ebx - 4]
add ecx, edx
mov eax, dword [ebx + 4]
test eax, eax
je 0x10002c3d
lea edi, [edx + ebp]
cmp edi, eax
jbe 0x10002c3d
mov ebp, eax
sub ebp, edx
mov eax, dword [esp + 0x550]
push ebp
push esi
push ecx
mov ecx, dword [esp + 0x554]
push eax
push 0xffffffffffffffff
push ecx
call fcn.10001690
mov ecx, dword [ebx]
add ecx, ebp
mov dword [ebx], ecx
mov eax, dword [ebx + 4]
test eax, eax
je 0x10002c7e
cmp ecx, eax
jb 0x10002c7e
mov eax, dword [esp + 0x18]
lea ecx, [ebx - 8]
push eax
push ecx
call fcn.10001bb0
mov dword [esp + 0x20], 1
add ebx, 0x1c
dec dword [esp + 0x24]
jne 0x10002a8b
cmp dword [esp + 0x20], 0
je 0x10002cd0
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
push eax
push ecx
call fcn.10001e10
add esp, 8
test eax, eax
je 0x10002cd0
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
push eax
push ecx
push edx
call fcn.10001ca0
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0x14]
push ecx
push edx
push eax
call fcn.10001b10
mov esi, 1
xor eax, eax
mov dword [esp + 0x20], 0
cmp dword [esp + 0x10], eax
je 0x10002cfc
mov ecx, dword [esp + 0x14]
cmp dword [ecx], 0
jne 0x10002cfa
add ecx, 0x1c
inc eax
cmp dword [esp + 0x10], eax
ja 0x10002ce9
jmp 0x10002cfc
xor esi, esi
call dword [sym.imp.WINMM.dll_timeGetTime]
sub eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x548]
cmp dword [ecx + 4], 0
mov dword [ecx + 0x2454], eax
jne 0x10002d21
test esi, esi
je 0x100029cb
cmp dword [esp + 0x10], 0
je 0x10002d41
mov esi, dword [esp + 0x14]
mov edi, dword [esp + 0x10]
mov eax, dword [esp + 0x18]
push eax
push esi
add esi, 0x1c
call fcn.10001bb0
dec edi
jne 0x10002d30
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
push eax
push ecx
push edx
call fcn.10001dd0
mov dword [esp + 0x28], eax
test eax, eax
je 0x10002d87
cmp dword [esp + 0x554], 0
je 0x10002e8f
mov eax, dword [esp + 0x554]
cmp byte [eax], 0
je 0x10002e8f
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
jmp 0x10002e8f
cmp dword [esp + 0x554], 0
je 0x10002e8f
mov eax, dword [esp + 0x554]
cmp byte [eax], 0
je 0x10002e8f
push 0
push eax
call dword [sym.imp.KERNEL32.dll__lcreat]
cmp eax, 0xffffffff
mov ebp, eax
je 0x10002e8f
lea eax, [esp + 0x144]
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
call esi
mov edi, eax
lea eax, [esp + 0x344]
push eax
call esi
mov esi, eax
mov ecx, dword [esp + 0x10]
inc ecx
mov eax, ecx
shl ecx, 3
sub ecx, eax
lea edx, [esi + ecx*4]
add edx, edi
mov dword [esp + 0x24], edx
push edx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ebx, eax
mov ecx, dword [esp + 0x30]
mov eax, dword [esp + 0x34]
mov edx, dword [esp + 0x18]
mov dword [ebx], ecx
mov ecx, dword [esp + 0x38]
mov dword [ebx + 4], eax
mov eax, dword [esp + 0x10]
mov dword [ebx + 8], edx
lea edx, [esp + 0x144]
push edx
mov dword [ebx + 0xc], ecx
lea ecx, [ebx + 0x1c]
mov dword [ebx + 0x10], edi
push ecx
mov dword [ebx + 0x14], esi
mov dword [ebx + 0x18], eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea ecx, [esp + 0x344]
lea eax, [ebx + edi]
push ecx
add eax, 0x1c
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
push ecx
add esi, edi
push edx
call fcn.10001b90
mov eax, dword [esp + 0x34]
add esp, 8
lea edi, [esi + ebx + 0x1c]
mov ecx, eax
shr ecx, 2
mov esi, dword [esp + 0x14]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x24]
push ecx
push ebx
push ebp
call dword [sym.imp.KERNEL32.dll__lwrite]
push ebp
call dword [sym.imp.KERNEL32.dll__lclose]
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov ecx, dword [esp + 0x548]
mov eax, dword [esp + 0x14]
push eax
mov dword [ecx + 0x2444], 0
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [esp + 0x28]
jmp 0x10002eb3
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x534
ret 0x10