Function at 0x477f10
Capabilities:
Initialize winsock library

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x48c701
push eax
mov dword fs:[0], esp
sub esp, 0x5b8
push ebx
push ebp
push esi
push edi
push 0
call fcn.0042c4df
push 0x4c8db8
mov dword [0x4c8db8], eax
call fcn.0042e5b0
mov ebx, dword [esp + 0x5e0]
mov ecx, 0x24
xor eax, eax
mov edi, ebx
mov dword [0x4c8dbc], 0
add esp, 8
rep stosd dword es:[edi], eax
mov eax, dword [0x4c8db8]
lea ecx, [ebx + 0x6c]
push ecx
mov dword [ebx], eax
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea eax, [ebx + 0x20]
mov esi, 0x4a8588
mov dword [ebx + 0x24], eax
mov dword [eax], eax
lea eax, [ebx + 0x28]
mov dword [ebx + 0x2c], eax
mov dword [eax], eax
mov eax, dword [0x4a8588]
test eax, eax
je 0x477fc2
mov eax, dword [esi + 0x18]
test eax, eax
je 0x477fb8
push eax
call fcn.00478680
mov ecx, dword [esp + 0x5ec]
mov edx, esi
sub edx, 0x4a8588
add esp, 4
sar edx, 5
mov dword [ecx + edx*4], eax
mov eax, dword [esi + 0x20]
add esi, 0x20
test eax, eax
jne 0x477f93
lea edx, [esp + 0x38]
mov ecx, pe_nt_image_headers32
xor eax, eax
lea edi, [esp + 0x38]
push 0x39c
push edx
rep stosd dword es:[edi], eax
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [esp + 0x38]
push 0x5c
push eax
call fcn.004346d0
add esp, 8
test eax, eax
jne 0x478019
mov edi, 0x49f190
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x38]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
jmp 0x47801c
mov byte [eax], 0
mov ebp, dword [esp + 0x5dc]
test ebp, ebp
je 0x4782e3
push 0x3a
push ebp
call fcn.00432820
add esp, 8
lea edx, [esp + 0x38]
test eax, eax
jne 0x47808e
mov edi, 0x4b0b48
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x38]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, ebp
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
jmp 0x4780a8
mov edi, ebp
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
xor eax, eax
rep movsb byte es:[edi], byte [esi]
mov cl, byte [esp + 0x13]
mov dword [esp + 0x18], eax
mov byte [esp + 0x14], cl
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], eax
lea edi, [esp + 0x38]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov dl, byte [esp + 0x13]
push 1
not ecx
dec ecx
mov dword [esp + 0x5d4], eax
mov ebp, ecx
lea ecx, [esp + 0x28]
push ebp
mov byte [esp + 0x2c], dl
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], eax
call fcn.00401850
test al, al
je 0x47811e
mov edi, dword [esp + 0x28]
mov ecx, ebp
mov eax, ecx
lea esi, [esp + 0x38]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x28]
call fcn.004099d0
lea ecx, [esp + 0x14]
lea edx, [esp + 0x24]
push ecx
push edx
mov byte [esp + 0x5d8], 1
call fcn.0044a6b0
mov bl, al
mov eax, dword [esp + 0x30]
add esp, 8
mov byte [esp + 0x5d0], 0
test eax, eax
je 0x478167
lea ecx, [eax - 1]
mov al, byte [eax - 1]
test al, al
je 0x47815e
cmp al, 0xff
je 0x47815e
dec al
mov byte [ecx], al
jmp 0x478167
push ecx
call fcn.00485078
add esp, 4
test bl, bl
je 0x4781e5
xor edi, edi
xor ebp, ebp
mov esi, dword [esp + 0x18]
test esi, esi
je 0x4781e9
mov eax, dword [esp + 0x1c]
sub eax, esi
sar eax, 5
cmp edi, eax
jae 0x4781e9
mov esi, dword [esi + ebp + 4]
test esi, esi
jne 0x478191
mov esi, 0x48d810
push esi
push str.listen_port
call fcn.0042c2c0
add esp, 8
test eax, eax
je 0x4781a9
inc edi
add ebp, 0x20
jmp 0x47816f
push str.listen_port
push 0
call fcn.004784e0
add esp, 8
test eax, eax
je 0x4781e5
mov ecx, dword [esp + 0x18]
shl edi, 5
lea ecx, [edi + ecx + 0x10]
mov ecx, dword [ecx + 4]
test ecx, ecx
jne 0x4781d3
mov ecx, 0x48d810
mov edx, dword [esp + 0x5e8]
push edx
push ecx
push eax
call fcn.00478530
add esp, 0xc
mov esi, dword [esp + 0x18]
mov ebx, dword [esp + 0x1c]
mov dword [esp + 0x5d0], 0xffffffff
cmp esi, ebx
mov dword [esp + 0x34], esi
je 0x4782d3
mov ebp, 2
xor ecx, ecx
mov eax, dword [esi + 0x14]
lea edi, [esi + 0x10]
cmp eax, ecx
mov dword [esp + 0x5d0], ebp
je 0x47825a
push eax
mov ecx, edi
call fcn.00452f40
cmp byte [eax], 0
je 0x478248
mov eax, dword [edi + 4]
mov ecx, edi
push eax
call fcn.00452f40
cmp byte [eax], 0xff
je 0x478248
mov ecx, dword [edi + 4]
push ecx
mov ecx, edi
call fcn.00452f40
dec byte [eax]
jmp 0x47825a
mov edx, dword [edi + 0xc]
mov eax, dword [edi + 4]
add edx, ebp
dec eax
push edx
push eax
mov ecx, edi
call fcn.00452f50
xor ecx, ecx
mov dword [esp + 0x5d0], 0xffffffff
mov dword [edi + 4], ecx
mov dword [edi + 8], ecx
mov dword [edi + 0xc], ecx
mov eax, dword [esi + 4]
cmp eax, ecx
je 0x4782b5
push eax
mov ecx, esi
call fcn.00452f40
cmp byte [eax], 0
je 0x4782a3
mov ecx, dword [esi + 4]
push ecx
mov ecx, esi
call fcn.00452f40
cmp byte [eax], 0xff
je 0x4782a3
mov edx, dword [esi + 4]
mov ecx, esi
push edx
call fcn.00452f40
dec byte [eax]
jmp 0x4782b5
mov eax, dword [esi + 0xc]
mov ecx, dword [esi + 4]
add eax, ebp
dec ecx
push eax
push ecx
mov ecx, esi
call fcn.00452f50
xor ecx, ecx
mov dword [esi + 4], ecx
mov dword [esi + 8], ecx
mov dword [esi + 0xc], ecx
add esi, 0x20
cmp esi, ebx
mov dword [esp + 0x34], esi
jne 0x47820b
mov esi, dword [esp + 0x18]
push esi
call fcn.00485078
mov ebx, dword [esp + 0x5dc]
add esp, 4
mov eax, dword [esp + 0x5e0]
mov ebp, 1
cmp eax, ebp
jbe 0x478386
mov edx, dword [esp + 0x5e4]
lea esi, [edx + 4]
mov eax, dword [esi]
cmp byte [eax], 0x2d
jne 0x478386
movsx eax, byte [eax + 1]
push 0
push eax
call fcn.004784e0
mov ebx, eax
add esp, 8
test ebx, ebx
je 0x47835a
mov eax, dword [esi]
lea edi, [eax + 2]
mov al, byte [eax + 2]
test al, al
jne 0x478330
mov edi, dword [esi + 4]
inc ebp
add esi, 4
test edi, edi
jne 0x478346
mov ecx, dword [esp + 0x5e4]
mov edx, dword [ecx]
push edx
call fcn.00477e50
add esp, 4
mov eax, dword [esp + 0x5e8]
push eax
push edi
push ebx
call fcn.00478530
add esp, 0xc
jmp 0x47836c
mov ecx, dword [esp + 0x5e4]
mov edx, dword [ecx]
push edx
call fcn.00477e50
add esp, 4
mov eax, dword [esp + 0x5e0]
mov ebx, dword [esp + 0x5d8]
inc ebp
add esi, 4
cmp ebp, eax
jb 0x478301
mov edi, dword [esp + 0x5e8]
mov esi, 0x4a8598
mov eax, dword [edi]
test eax, eax
je 0x4783ad
push eax
mov eax, dword [esi]
add eax, ebx
push eax
push ebx
call dword [esi - 4]
mov ecx, dword [edi]
push ecx
call fcn.0042cf56
add esp, 0x10
add esi, 0x20
add edi, 4
cmp esi, 0x4a8758
jb 0x478392
lea edx, [esp + 0x38]
mov ecx, pe_nt_image_headers32
xor eax, eax
lea edi, [esp + 0x38]
push 0x39c
push edx
rep stosd dword es:[edi], eax
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [esp + 0x38]
push 0x5c
push eax
call fcn.004346d0
add esp, 8
test eax, eax
jne 0x478412
mov edi, 0x49f190
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x38]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
jmp 0x478415
mov byte [eax], 0
mov eax, dword [ebx + 0x3c]
test eax, eax
jne 0x47842b
lea ecx, [esp + 0x38]
push ecx
call fcn.00478680
add esp, 4
jmp 0x4784a5
push 0x3a
push eax
call fcn.00432820
add esp, 8
test eax, eax
jne 0x4784a8
mov edi, 0x4b0b48
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x38]
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
mov edx, dword [ebx + 0x3c]
and ecx, 3
lea ebp, [esp + 0x38]
rep movsb byte es:[edi], byte [esi]
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push edx
mov esi, edi
mov edi, ebp
mov ebp, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.0042cf56
lea eax, [esp + 0x3c]
push eax
call fcn.00478680
add esp, 8
mov dword [ebx + 0x3c], eax
lea ecx, [esp + 0x438]
push ecx
push 0x202
call dword [sym.imp.WSOCK32.dll_WSAStartup]
mov ecx, dword [esp + 0x5c8]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x5c4
ret