Function at 0x484b20
Capabilities:
Connect socket
Get hostname
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
sub esp, 0x224
mov al, byte [0x475414]
mov byte [esp + 0x58], al
push ebx
push esi
xor eax, eax
push edi
mov ecx, 0x18
lea edi, [esp + 0x65]
push ebp
mov ebp, 1
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
cmp dword [esp + 0x240], eax
jne 0x484b61
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
mov eax, dword [esp + 0x240]
mov byte [eax], 0
call fcn.0047c420
cmp eax, 1
jne 0x484b77
xor ebp, ebp
lea edi, [esp + 0xcc]
xor eax, eax
mov ecx, 0x19
rep stosd dword es:[edi], eax
mov ebx, dword [esp + 0x23c]
mov ecx, 0xffffffff
sub eax, eax
lea edi, [ebx + 2]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
shr ecx, 2
mov esi, edi
lea edi, [esp + 0xcc]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push 0x4761d4
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0xd0]
mov esi, dword [sym.imp.MSVCRT.dll__stricmp]
push ecx
call esi
add esp, 8
test eax, eax
jne 0x484bf9
cmp ebp, 1
jne 0x484bf9
mov eax, dword [esp + 0x240]
mov esi, dword [esp + 0x238]
push eax
push esi
call fcn.00486eb0
add esp, 8
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
lea eax, [esp + 0xcc]
push 0x4761d4
push eax
call esi
add esp, 8
test eax, eax
jne 0x484c47
test ebp, ebp
jne 0x484c47
lea eax, [esp + 0x68]
push 0x64
push eax
call sub.WSOCK32.dll_gethostname
cmp eax, 0xffffffff
jne 0x484c6f
mov eax, dword [0x475494]
mov ebp, dword [0x475498]
mov ecx, 0x475494
lea edx, [esp + 0x68]
mov cx, word [ecx + 8]
mov dword [edx], eax
mov dword [edx + 4], ebp
mov word [edx + 8], cx
jmp 0x484c6f
lea edi, [esp + 0xcc]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
shr ecx, 2
mov esi, edi
lea edi, [esp + 0x68]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.0047cae0
xor ecx, ecx
mov cx, word [ebx + 0x74]
dec ecx
cmp ecx, 7
ja case.0x484c88.5
xor edx, edx
mov dl, byte [ecx + 0x485370]
jmp dword [edx*4 + 0x48535c]
test al, 1
je 0x484c9d
mov dword [esp + 0x10], 1
jmp 0x484d17
test al, 2
jne 0x484d0f
mov eax, 0x4c
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
test al, 1
je 0x484cbf
mov dword [esp + 0x10], 1
jmp 0x484d17
mov eax, 0x4c
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
test al, 2
jne 0x484d0f
mov eax, 0x4c
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
mov eax, dword [esp + 0x240]
mov esi, dword [esp + 0x238]
push eax
push ebx
push esi
call fcn.00485430
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
test al, 2
je 0x48534c
mov dword [esp + 0x10], 2
lea eax, [esp + 0x68]
push eax
call fcn.0047cb40
add esp, 4
test eax, eax
jne 0x484d37
test byte [esp + 0x10], 2
je 0x484d37
mov dword [esp + 0x10], 2
push ebx
call fcn.00483d00
add esp, 4
cmp eax, 0xffffffff
jne 0x484d84
cmp dword [esp + 0x10], 2
jne 0x484d57
push 0x3e8
push 2
push 6
jmp 0x484d5d
push 0x11
push 2
push 2
call fcn.004826f0
add esp, 0xc
cmp eax, 0xffffffff
jne 0x484d7a
mov eax, 0x3f
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
push eax
push ebx
call fcn.00483d20
add esp, 8
lea eax, [esp + 0x38]
push 0
lea ecx, [esp + 0x6c]
push eax
cmp dword [esp + 0x18], 2
push ecx
jne 0x484db3
call fcn.0047cc60
add esp, 0xc
test eax, eax
je 0x484dcf
mov eax, 0x3d
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
call fcn.0047c850
add esp, 0xc
test eax, eax
je 0x484dcf
mov eax, 0x3d
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
cmp dword [0x476680], 0
je 0x484df0
call fcn.00485380
push eax
call fcn.0047ec80
mov dword [0x476680], 0
add esp, 4
call sub.MSVCRT.dll__getpid
mov dword [0x4776fc], eax
call fcn.00485380
cmp dword [eax], 0
je 0x484e68
mov esi, dword [sym.imp.KERNEL32.dll_GetVersion]
call esi
cmp eax, 0x80000000
jb 0x484e68
call esi
cmp eax, 0x80000000
jb 0x484e22
call esi
cmp al, 4
jb 0x484e68
cmp dword [esp + 0x10], 2
jne 0x484e68
push ebx
call fcn.00483d00
add esp, 4
push eax
call sub.WSOCK32.dll_closesocket
push 0x3e8
push 2
push 6
call fcn.004826f0
add esp, 0xc
cmp eax, 0xffffffff
jne 0x484e5e
mov eax, 0x3f
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
push eax
push ebx
call fcn.00483d20
add esp, 8
lea eax, [esp + 0x38]
push eax
call fcn.00485380
mov eax, dword [eax]
push eax
call fcn.00485390
add esp, 8
mov ebp, eax
test ebp, ebp
jne 0x484f7e
push 0x58
call dword [sym.imp.MSVCRT.dll_malloc]
add esp, 4
mov ebp, eax
test ebp, ebp
jne 0x484ea8
mov eax, 0x40
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
cmp dword [esp + 0x10], 2
jne 0x484ef8
lea esi, [ebp + 8]
xor eax, eax
mov dword [esi], eax
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov dword [esi + 0xc], eax
mov word [esi], 6
call fcn.00483d60
push eax
call fcn.00482820
mov word [esi + 0xc], ax
add esp, 4
lea eax, [esp + 0x38]
push esi
push eax
call fcn.0047cbe0
add esp, 8
test eax, eax
jne 0x484f44
mov eax, 0x3d
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
lea eax, [ebp + 8]
xor ecx, ecx
mov dword [eax], ecx
mov dword [eax + 4], ecx
mov dword [eax + 8], ecx
mov dword [eax + 0xc], ecx
mov word [eax], 2
call fcn.00483d60
push eax
call fcn.00482820
mov word [ebp + 0xa], ax
lea ecx, [esp + 0x3c]
add esp, 4
push ecx
call fcn.00482690
add esp, 4
mov dword [ebp + 0xc], eax
cmp eax, 0xffffffff
jne 0x484f44
mov eax, 0x3d
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
lea edi, [esp + 0x38]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
shr ecx, 2
mov esi, edi
lea edi, [ebp + 0x18]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov dword [ebp], 1
call fcn.00485380
push eax
call fcn.0047ec90
add esp, 8
mov dword [0x4776f0], 0x3f
mov eax, dword [ebp]
mov esi, dword [esp + 0x238]
and eax, 0x1fff
mov edi, esi
mov ecx, 0xffffffff
mov dword [0x4776f4], eax
mov dword [0x4776f8], 0
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
mov edx, ecx
mov edi, 0x477700
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x477548
xor eax, eax
mov ecx, 0x68
rep stosd dword es:[edi], eax
lea eax, [esp + 0x2c]
mov edi, 0x477898
push eax
call fcn.00484b00
xor eax, eax
mov ecx, 0x68
mov dword [esp + 0x20], 0
mov dword [esp + 0x18], 1
add esp, 4
rep stosd dword es:[edi], eax
mov ecx, dword [0x4776f0]
push ecx
call fcn.00482850
add esp, 4
mov ecx, dword [0x4776f4]
mov dword [0x477898], eax
push ecx
call fcn.00482850
add esp, 4
mov ecx, dword [0x4776f8]
mov dword [0x47789c], eax
push ecx
call fcn.00482850
add esp, 4
mov ecx, dword [0x4776fc]
mov edi, 0x477700
mov dword [0x4778a0], eax
push ecx
call fcn.00482850
add esp, 4
mov ecx, 0xffffffff
mov dword [0x4778a4], eax
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
shr ecx, 2
mov esi, edi
mov edi, 0x4778a8
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea eax, [esp + 0x2c]
mov dword [esp + 0x18], eax
lea eax, [esp + 0x38]
cmp dword [esp + 0x18], eax
jae 0x4852dc
cmp dword [esp + 0x10], 2
jne 0x4850e6
push 0x10
lea eax, [ebp + 8]
push eax
push ebx
call fcn.00483d00
add esp, 4
push eax
call sub.WSOCK32.dll_connect
cmp dword [esp + 0x14], 0
je 0x48511c
push 0
push 0x1a0
push 0x477898
push ebx
call fcn.00483d00
add esp, 4
push eax
call sub.WSOCK32.dll_send
cmp eax, 0x1a0
je 0x48511c
call sub.WSOCK32.dll_WSAGetLastError
mov eax, 0x3e
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
cmp dword [esp + 0x14], 0
je 0x48511c
push 0x10
lea eax, [ebp + 8]
push eax
push 0
push 0x1a0
push 0x477898
push ebx
call fcn.00483d00
add esp, 4
push eax
call fcn.004827a0
add esp, 0x18
cmp eax, 0x1a0
jne 0x4852f3
mov dword [esp + 0x14], 0
mov dword [esp + 0x130], 0
push ebx
call fcn.00483d00
mov dword [esp + 0x138], eax
add esp, 4
mov eax, dword [esp + 0x18]
inc dword [esp + 0x130]
mov dword [esp + 0x28], 0
mov ecx, dword [eax]
lea eax, [esp + 0x130]
mov dword [esp + 0x24], ecx
lea ecx, [esp + 0x24]
push ecx
push 0
push 0
push eax
push ebx
call fcn.00483d00
add esp, 4
inc eax
push eax
call fcn.00482720
add esp, 0x14
cmp eax, 0xffffffff
je 0x4852ad
test eax, eax
je 0x4852c4
mov edi, 0x477898
xor eax, eax
mov dword [esp + 0x20], 0x10
mov ecx, 0x68
rep stosd dword es:[edi], eax
cmp dword [esp + 0x10], 2
jne 0x4851db
push eax
push 0x1a0
push 0x477898
push ebx
call fcn.00483d00
add esp, 4
push eax
call sub.WSOCK32.dll_recv
cmp eax, 0x1a0
je 0x48520c
mov eax, 0x6c
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
lea eax, [esp + 0x20]
lea ecx, [esp + 0x58]
push eax
push ecx
push 0
push 0x1a0
push 0x477898
push ebx
call fcn.00483d00
add esp, 4
push eax
call fcn.004827e0
add esp, 0x18
cmp eax, 0xffffffff
je 0x485303
mov eax, dword [0x477898]
mov edi, 0x4778a8
push eax
call fcn.00482850
add esp, 4
mov dword [0x477548], eax
mov eax, dword [0x47789c]
push eax
call fcn.00482850
add esp, 4
mov dword [0x47754c], eax
mov eax, dword [0x4778a0]
push eax
call fcn.00482850
add esp, 4
mov dword [0x477550], eax
mov eax, dword [0x4778a4]
push eax
call fcn.00482850
add esp, 4
mov ecx, 0xffffffff
mov dword [0x477554], eax
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
shr ecx, 2
mov esi, edi
mov edi, 0x477558
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
cmp dword [esp + 0x10], 1
jne 0x485296
lea esi, [ebp + 0xc]
lea edi, [esp + 0x5c]
mov ecx, 4
repe cmpsb byte [esi], byte es:[edi]
jne 0x4852d1
mov eax, dword [0x47754c]
cmp dword [0x4776f4], eax
jne 0x4852d1
mov dword [esp + 0x1c], 1
jmp 0x4852d1
cmp eax, 0x2714
je 0x4852d1
mov eax, 0x6d
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
mov dword [esp + 0x14], 1
add dword [esp + 0x18], 4
cmp dword [esp + 0x1c], 0
je 0x48507e
cmp dword [esp + 0x1c], 1
je 0x485313
mov eax, 0x3c
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
mov eax, 0x3e
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
mov eax, 0x6c
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret
mov edi, 0x477558
mov ecx, 0xffffffff
inc dword [ebp]
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
shr ecx, 2
mov esi, edi
mov edi, dword [esp + 0x240]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
pop ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor eax, eax
pop edi
pop esi
pop ebx
add esp, 0x224
ret
mov eax, 0x4c
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x224
ret