Function at 0x57d8f8
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Parse url
Resolve dns
Resolve function by parsing pe exports
Set socket configuration

Disassembly:
push edi
push esi
push ebp
push ebx
push ecx
mov eax, 0x12c
call fcn.00696350
mov ecx, dword [esp + 0x12c]
mov ebp, ecx
push 0x6c4af8
mov ecx, dword [0x7bc000]
call fcn.004fedb4
mov word [esp + 0x12c], ax
lea eax, [esp + 0x12c]
push eax
mov ecx, dword [0x6ffbec]
call fcn.004ede5c
mov ebx, eax
test ebx, ebx
je 0x57e20d
push 0xa
lea ecx, [esp + 0x124]
call fcn.0050a9a0
lea eax, [esp + 0x120]
push 1
push eax
mov ecx, ebx
call fcn.00502a8c
mov eax, dword [esp + 0x120]
cmp dword [eax], 2
jne 0x57d977
mov ebx, 1
jmp 0x57d979
xor ebx, ebx
lea ecx, [esp + 0x120]
call fcn.0050aa58
cmp ebx, 1
je 0x57dda0
xor esi, esi
xor edi, edi
mov eax, dword [esp + 0x144]
mov dword [eax], 0xffffffff
xor edx, edx
mov dword [esp + 0x100], edx
mov dword [esp + 0x104], edx
mov dword [esp + 0x108], edx
mov dword [esp + 0x10c], edx
mov eax, 2
mov word [esp + 0x100], ax
cmp ebx, 1
je 0x57d9d7
movzx edi, word [esp + 0x14c]
push edi
call sub.WSOCK32.dll_htons
mov word [esp + 0x102], ax
lea ecx, [esp + 0x110]
call fcn.004e5620
cmp ebx, 1
je 0x57dd8e
mov eax, dword [esp + 0x148]
push eax
lea ecx, [esp + 0x114]
call fcn.004e5334
lea ecx, [esp + 0x110]
call fcn.004e5330
push eax
call sub.WSOCK32.dll_inet_addr
cmp eax, 0xffffffff
jne 0x57da46
lea ecx, [esp + 0x110]
call fcn.004e5330
push eax
call sub.WSOCK32.dll_gethostbyname
test eax, eax
je 0x57dd70
mov eax, dword [eax + 0xc]
mov edx, dword [eax]
mov eax, dword [edx]
mov dword [esp + 0x104], eax
test ebx, ebx
je 0x57dcf8
push 0x6c4b10
mov ecx, dword [0x7bc000]
call fcn.004fedb4
mov word [esp + 0xf8], ax
lea eax, [esp + 0xf8]
push eax
mov ecx, dword [0x6ffbec]
call fcn.004ede5c
mov ebx, eax
test ebx, ebx
je 0x57daca
push 0xa
lea ecx, [esp + 0xc4]
call fcn.0050a9a0
lea eax, [esp + 0xc0]
push 1
push eax
mov ecx, ebx
call fcn.00502a8c
mov eax, dword [esp + 0xc0]
cmp dword [eax], 2
jne 0x57dab8
mov ebx, 1
jmp 0x57daba
xor ebx, ebx
lea ecx, [esp + 0xc0]
call fcn.0050aa58
test ebx, ebx
jne 0x57dad1
xor ebx, ebx
jmp 0x57db83
mov ecx, dword [ebp + 0xe]
test ecx, ecx
je 0x57dadd
call fcn.004db418
mov dword [ebp + 0xe], 0
push 0x6c4b20
mov ecx, dword [0x7bc000]
call fcn.004fedb4
mov word [esp + 0xe0], ax
lea eax, [esp + 0xe0]
push eax
mov ecx, dword [0x6ffbec]
call fcn.004ede5c
mov ebx, eax
test ebx, ebx
je 0x57dd48
push 1
lea ecx, [esp + 0x94]
call fcn.0050a9a0
lea eax, [esp + 0x90]
push 1
push eax
mov ecx, ebx
call fcn.00502a8c
mov ecx, dword [esp + 0x90]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x57db56
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x57db41
dec eax
inc eax
mov ecx, eax
call fcn.004dbd48
mov dword [ebp + 0xe], eax
mov esi, eax
mov edi, dword [esp + 0x90]
mov dl, byte [edi]
inc edi
mov byte [esi], dl
inc esi
test dl, dl
jne 0x57db6a
mov ebx, dword [ebp + 0xe]
lea ecx, [esp + 0x90]
call fcn.0050aa58
push 0x6c4b10
mov ecx, dword [0x7bc000]
call fcn.004fedb4
mov word [esp + 0xfc], ax
lea eax, [esp + 0xfc]
push eax
mov ecx, dword [0x6ffbec]
call fcn.004ede5c
mov esi, eax
test esi, esi
je 0x57dbf8
push 0xa
lea ecx, [esp + 0xd0]
call fcn.0050a9a0
lea eax, [esp + 0xcc]
push 1
push eax
mov ecx, esi
call fcn.00502a8c
mov eax, dword [esp + 0xcc]
cmp dword [eax], 2
jne 0x57dbe6
mov esi, 1
jmp 0x57dbe8
xor esi, esi
lea ecx, [esp + 0xcc]
call fcn.0050aa58
test esi, esi
jne 0x57dbff
xor esi, esi
jmp 0x57dcb1
mov ecx, dword [ebp + 0x12]
test ecx, ecx
je 0x57dc0b
call fcn.004db418
mov dword [ebp + 0x12], 0
push 0x6c4b30
mov ecx, dword [0x7bc000]
call fcn.004fedb4
mov word [esp + 0xe4], ax
lea eax, [esp + 0xe4]
push eax
mov ecx, dword [0x6ffbec]
call fcn.004ede5c
mov esi, eax
test esi, esi
je 0x57dd3e
push 1
lea ecx, [esp + 0xa0]
call fcn.0050a9a0
lea eax, [esp + 0x9c]
push 1
push eax
mov ecx, esi
call fcn.00502a8c
mov ecx, dword [esp + 0x9c]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x57dc84
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x57dc6f
dec eax
inc eax
mov ecx, eax
call fcn.004dbd48
mov dword [ebp + 0x12], eax
mov esi, eax
mov edi, dword [esp + 0x9c]
mov dl, byte [edi]
inc edi
mov byte [esi], dl
inc esi
test dl, dl
jne 0x57dc98
mov esi, dword [ebp + 0x12]
lea ecx, [esp + 0x9c]
call fcn.0050aa58
lea edx, [esp + 0x100]
push esi
push ebx
movzx ebx, word [esp + 0x154]
push ebx
mov eax, dword [esp + 0x154]
push eax
push edx
mov esi, dword [esp + 0x158]
push esi
mov ecx, ebp
call fcn.0057e214
mov ebx, eax
lea ecx, [esp + 0x110]
call fcn.004e55bc
mov eax, ebx
add esp, 0x130
pop ebx
pop ebp
pop esi
pop edi
ret 0xc
push 6
push 1
push 2
call sub.WSOCK32.dll_socket
mov ebx, eax
lea eax, [esp + 0x100]
push 0x10
push eax
push ebx
call sub.WSOCK32.dll_connect
cmp eax, 0xffffffff
je 0x57dd52
mov eax, dword [esp + 0x144]
mov dword [eax], ebx
lea ecx, [esp + 0x110]
call fcn.004e55bc
xor eax, eax
add esp, 0x130
pop ebx
pop ebp
pop esi
pop edi
ret 0xc
mov esi, 0x6c41ec
jmp 0x57dcb1
mov ebx, 0x6c41ec
jmp 0x57db83
lea ecx, [esp + 0x110]
call fcn.004e55bc
mov eax, 1
add esp, 0x130
pop ebx
pop ebp
pop esi
pop edi
ret 0xc
lea ecx, [esp + 0x110]
call fcn.004e55bc
mov eax, 1
add esp, 0x130
pop ebx
pop ebp
pop esi
pop edi
ret 0xc
push esi
lea ecx, [esp + 0x114]
call fcn.004e5334
jmp 0x57da0e
mov ecx, dword [ebp + 4]
test ecx, ecx
je 0x57ddac
call fcn.004db418
mov dword [ebp + 4], 0
push 0x6c4b04
mov ecx, dword [0x7bc000]
call fcn.004fedb4
mov word [esp + 0xe8], ax
lea eax, [esp + 0xe8]
push eax
mov ecx, dword [0x6ffbec]
call fcn.004ede5c
mov esi, eax
test esi, esi
je 0x57de4f
push 1
lea ecx, [esp + 0xac]
call fcn.0050a9a0
lea eax, [esp + 0xa8]
push 1
push eax
mov ecx, esi
call fcn.00502a8c
mov ecx, dword [esp + 0xa8]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x57de21
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x57de0c
dec eax
add eax, 0xa
mov ecx, eax
call fcn.004dbd48
mov dword [ebp + 4], eax
push dword [esp + 0xa8]
push str.http:___s
push eax
call fcn.006964d6
add esp, 0xc
lea ecx, [esp + 0xa8]
call fcn.0050aa58
mov esi, dword [ebp + 4]
mov dword [esp], 0x7f1058
mov dword [esp + 0xd8], 1
xor eax, eax
mov dword [esp + 4], eax
mov dword [esp + 8], eax
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], eax
mov dword [esp + 4], 0x3c
xor edx, edx
mov dword [esp + 8], edx
mov dword [esp + 0x14], edx
mov dword [esp + 0x20], edx
mov dword [esp + 0x28], edx
mov dword [esp + 0x30], edx
mov dword [esp + 0x38], edx
mov eax, 1
mov dword [esp + 0xc], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x2c], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x3c], eax
lea edi, [esp + 0xf0]
lea ecx, [esp + 0xd8]
push edx
push ecx
push edi
push esi
call dword [sym.imp.WININET.dll_InternetCanonicalizeUrlA]
mov dword [esp + 0x44], 1
mov ecx, dword [esp + 0xd8]
inc ecx
call fcn.004dbd48
mov dword [esp + 0x40], eax
lea edx, [esp + 0xd8]
push 0
push edx
push eax
push esi
call dword [sym.imp.WININET.dll_InternetCanonicalizeUrlA]
mov esi, dword [esp + 0x40]
mov edx, dword [esp + 0xd8]
xor eax, eax
mov byte [edx + esi], al
mov ecx, dword [esp + 0x40]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x57df4f
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x57df3a
dec eax
lea esi, [esp + 4]
push esi
xor edx, edx
push edx
push eax
push ecx
call dword [sym.imp.WININET.dll_InternetCrackUrlA]
test eax, eax
jne 0x57df6d
mov dword [esp + 0x44], 0
jmp 0x57df79
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
mov byte [eax + edx], 0
cmp dword [esp + 0x44], 0
jne 0x57df9b
mov dword [esp], 0x7f1058
mov ecx, dword [esp + 0x40]
test ecx, ecx
je 0x57df94
call fcn.004db418
mov esi, 0x6c41ec
jmp 0x57dff2
mov edi, dword [esp + 0x14]
mov ecx, dword [ebp + 8]
test ecx, ecx
je 0x57dfab
call fcn.004db418
mov ecx, edi
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x57dfc4
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x57dfaf
dec eax
inc eax
mov ecx, eax
call fcn.004dbd48
mov dword [ebp + 8], eax
mov esi, eax
mov dl, byte [edi]
inc edi
mov byte [esi], dl
inc esi
test dl, dl
jne 0x57dfd1
mov esi, dword [ebp + 8]
mov dword [esp], 0x7f1058
mov ecx, dword [esp + 0x40]
test ecx, ecx
je 0x57dff2
call fcn.004db418
mov ecx, dword [ebp + 4]
test ecx, ecx
je 0x57dffe
call fcn.004db418
mov dword [ebp + 4], 0
push 0x6c4b04
mov ecx, dword [0x7bc000]
call fcn.004fedb4
mov word [esp + 0xec], ax
lea eax, [esp + 0xec]
push eax
mov ecx, dword [0x6ffbec]
call fcn.004ede5c
mov edi, eax
test edi, edi
je 0x57e0a1
push 1
lea ecx, [esp + 0xb8]
call fcn.0050a9a0
lea eax, [esp + 0xb4]
push 1
push eax
mov ecx, edi
call fcn.00502a8c
mov ecx, dword [esp + 0xb4]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x57e073
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x57e05e
dec eax
add eax, 0xa
mov ecx, eax
call fcn.004dbd48
mov dword [ebp + 4], eax
push dword [esp + 0xb4]
push str.http:___s
push eax
call fcn.006964d6
add esp, 0xc
lea ecx, [esp + 0xb4]
call fcn.0050aa58
mov edi, dword [ebp + 4]
mov dword [esp + 0x48], 0x7f1058
mov dword [esp + 0xdc], 1
xor eax, eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], eax
mov dword [esp + 0x68], eax
mov dword [esp + 0x6c], eax
mov dword [esp + 0x70], eax
mov dword [esp + 0x74], eax
mov dword [esp + 0x78], eax
mov dword [esp + 0x7c], eax
mov dword [esp + 0x80], eax
mov dword [esp + 0x84], eax
mov dword [esp + 0x4c], 0x3c
xor eax, eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x5c], eax
mov dword [esp + 0x68], eax
mov dword [esp + 0x70], eax
mov dword [esp + 0x78], eax
mov dword [esp + 0x80], eax
mov edx, 1
mov dword [esp + 0x54], edx
mov dword [esp + 0x60], edx
mov dword [esp + 0x6c], edx
mov dword [esp + 0x74], edx
mov dword [esp + 0x7c], edx
mov dword [esp + 0x84], edx
lea edx, [esp + 0xf4]
lea ecx, [esp + 0xdc]
push eax
push ecx
push edx
push edi
call dword [sym.imp.WININET.dll_InternetCanonicalizeUrlA]
mov dword [esp + 0x8c], 1
mov ecx, dword [esp + 0xdc]
inc ecx
call fcn.004dbd48
mov dword [esp + 0x88], eax
lea edx, [esp + 0xdc]
push 0
push edx
push eax
push edi
call dword [sym.imp.WININET.dll_InternetCanonicalizeUrlA]
mov edi, dword [esp + 0x88]
mov edx, dword [esp + 0xdc]
xor eax, eax
mov byte [edx + edi], al
mov ecx, dword [esp + 0x88]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x57e1ba
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x57e1a5
dec eax
lea edi, [esp + 0x4c]
push edi
xor edx, edx
push edx
push eax
push ecx
call dword [sym.imp.WININET.dll_InternetCrackUrlA]
test eax, eax
jne 0x57e1db
mov dword [esp + 0x8c], 0
jmp 0x57e1e7
mov edx, dword [esp + 0x5c]
mov eax, dword [esp + 0x60]
mov byte [eax + edx], 0
movzx edi, word [esp + 0x64]
mov dword [esp + 0x48], 0x7f1058
mov ecx, dword [esp + 0x88]
test ecx, ecx
je 0x57d992
call fcn.004db418
jmp 0x57d992
xor ebx, ebx
jmp 0x57d98e