Function at 0x5693d0
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x168
mov ecx, dword [ebp + 0x18]
push ebx
push esi
push edi
mov eax, dword [ecx + 0xd0]
xor edi, edi
mov esi, dword [ecx]
mov ebx, 0x493e0
mov dword [ebp - 8], eax
mov eax, dword [ebp + 0x14]
mov edx, dword [esi + 0x640]
mov eax, dword [ecx + eax*4 + 0x1a8]
mov ecx, dword [esi + 0x644]
mov dword [ebp + 0x14], eax
xor eax, eax
test edx, edx
setg al
test ecx, ecx
jle 0x569418
or eax, 2
sub eax, 1
je 0x569430
sub eax, 1
je 0x56942c
sub eax, 1
jne 0x569437
cmp edx, ecx
cmovl ecx, edx
mov eax, ecx
jmp 0x569432
mov eax, edx
cdq
mov ebx, eax
mov edi, edx
lea eax, [ebp - 0x128]
push eax
call fcn.00575cf0
movups xmm0, xmmword [esi + 0xb40]
sub esp, 0xc
mov ecx, esp
sub esp, 0x10
movups xmmword [ecx], xmm0
mov ecx, esp
movups xmm0, xmmword [eax]
movups xmmword [ecx], xmm0
call fcn.0057b020
add esp, 0x20
sub ebx, eax
mov eax, ebx
sbb edi, edx
or eax, edi
je 0x569963
test edi, edi
jl 0x569963
jg 0x569485
test ebx, ebx
jb 0x569963
mov ecx, dword [ebp + 0x18]
mov edx, 0x71376a
mov ebx, dword [ebp + 0x10]
mov edi, dword [ebp + 0xc]
test byte [ecx + 0x284], 0x20
je 0x5694ba
cmp dword [ebp - 8], 6
mov eax, 0x7533a4
push ebx
push edi
cmovne eax, edx
push eax
push str.SOCKS4_s:_connecting_to_HTTP_proxy__s_port__d_n
push dword [ecx]
call fcn.005738f0
add esp, 0x14
lea eax, [ebp - 4]
mov dword [ebp - 4], 0
push eax
push 0x8004667e
push dword [ebp + 0x14]
call dword [sym.imp.WS2_32.dll_ioctlsocket]
push ebx
push edi
push str.SOCKS4_communication_to__s:_d_n
push esi
call fcn.005738f0
mov eax, ebx
mov word [ebp - 0x118], 0x104
sar eax, 8
add esp, 0x10
cmp dword [ebp - 8], 6
mov byte [ebp - 0x116], al
mov byte [ebp - 0x115], bl
je 0x5695b7
lea eax, [ebp - 4]
push eax
push ebx
push edi
mov edi, dword [ebp + 0x18]
push edi
call fcn.00578be0
add esp, 0x10
cmp eax, 0xffffffff
jne 0x56952a
mov eax, 5
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp eax, 1
jne 0x56953c
lea eax, [ebp - 4]
push eax
push edi
call fcn.00579270
add esp, 8
mov edi, dword [ebp - 4]
test edi, edi
je 0x569617
mov ebx, dword [edi]
test ebx, ebx
je 0x569617
push 0x40
lea eax, [ebp - 0x168]
push eax
push ebx
call fcn.00578040
add esp, 0xc
cmp dword [ebx + 4], 2
jne 0x5695fb
mov ecx, dword [ebx + 0x18]
movzx eax, byte [ecx + 4]
mov byte [ebp - 0x114], al
movzx eax, byte [ecx + 5]
mov byte [ebp - 0x113], al
movzx eax, byte [ecx + 6]
mov byte [ebp - 0x112], al
movzx eax, byte [ecx + 7]
mov byte [ebp - 0x111], al
lea eax, [ebp - 0x168]
push eax
push str.SOCKS4_connect_to_IPv4__s__locally_resolved__n
push esi
call fcn.005738f0
push edi
push esi
call fcn.00579200
mov edi, dword [ebp + 0xc]
add esp, 0x14
mov edx, dword [ebp + 8]
mov byte [ebp - 0x110], 0
test edx, edx
je 0x569648
mov ecx, edx
lea ebx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x5695d0
sub ecx, ebx
cmp ecx, 0xfe
jb 0x569634
push str.Too_long_SOCKS_proxy_name__cant_use__n
push esi
call fcn.0056f390
mov eax, 7
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x168]
push eax
push str.SOCKS4_connection_to__s_not_supported_n
push esi
call fcn.0056f390
push edi
push esi
call fcn.00579200
add esp, 0x14
push dword [ebp + 0xc]
push str.Failed_to_resolve___s__for_SOCKS4_connect.
push esi
call fcn.0056f390
add esp, 0xc
mov eax, 6
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea eax, [ecx + 1]
push eax
push edx
lea eax, [ebp - 0x110]
push eax
call fcn.006c1de0
add esp, 0xc
lea ecx, [ebp - 0x110]
mov dword [ebp - 4], 0
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x569658
sub ecx, edx
cmp dword [ebp - 8], 6
lea edx, [ecx + 9]
mov dword [ebp - 0xc], edx
jne 0x5696bf
mov ecx, edi
mov dword [ebp - 0x114], 0x1000000
lea ebx, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x569680
sub ecx, ebx
lea eax, [ecx + 1]
mov dword [ebp - 4], eax
add eax, edx
cmp eax, 0x106
jg 0x5696b8
mov eax, edx
mov ecx, edi
sub eax, edi
lea edx, [ebp - 0x118]
add edx, eax
mov al, byte [ecx]
lea ecx, [ecx + 1]
mov byte [edx + ecx - 1], al
test al, al
jne 0x5696a6
mov edx, dword [ebp - 0xc]
jmp 0x5696bf
mov dword [ebp - 4], 0
mov ebx, dword [ebp + 0x18]
xor eax, eax
mov ecx, dword [ebp + 0x14]
cmp ecx, dword [ebx + 0x1ac]
mov ecx, dword [ebp - 4]
sete al
add ecx, edx
lea edx, [ebp - 0xc]
mov dword [ebp - 0x10], ecx
push edx
push ecx
lea ecx, [ebp - 0x118]
push ecx
push eax
push ebx
call fcn.005794c0
add esp, 0x14
mov dword [ebp + 0x18], eax
cmp dword [ebp - 0xc], 0
jne 0x569949
cmp eax, dword [ebp - 0x10]
jne 0x569949
cmp dword [ebp - 8], 6
jne 0x56974a
cmp dword [ebp - 4], 0
jne 0x56974a
mov ecx, edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x569715
sub ecx, edx
lea eax, [ecx + 1]
lea ecx, [ebp + 0x18]
mov dword [ebp - 0x10], eax
push ecx
push eax
push edi
push dword [ebp + 0x14]
push ebx
call fcn.0057b680
add esp, 0x14
test eax, eax
jne 0x569949
mov eax, dword [ebp - 0x10]
cmp dword [ebp + 0x18], eax
jne 0x569949
lea eax, [ebp + 0x18]
push eax
push 8
lea eax, [ebp - 0x118]
push eax
push dword [ebp + 0x14]
push ebx
call fcn.0056af80
add esp, 0x14
test eax, eax
jne 0x56992f
cmp dword [ebp + 0x18], 8
jne 0x56992f
cmp byte [ebp - 0x118], al
je 0x569797
push str.SOCKS4_reply_has_wrong_version__version_should_be_4.
push esi
call fcn.0056f390
mov eax, 7
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
movzx eax, byte [ebp - 0x117]
lea ecx, [eax - 0x5a]
cmp ecx, 3
ja case.default.0x5697aa
jmp dword [ecx*4 + 0x569980]
cmp dword [ebp - 8], 6
mov ecx, 0x71376a
mov eax, 0x7533a4
cmovne eax, ecx
push eax
push str.SOCKS4_s_request_granted._n
push esi
call fcn.005738f0
add esp, 0xc
mov dword [ebp + 0x18], 1
lea eax, [ebp + 0x18]
push eax
push 0x8004667e
push dword [ebp + 0x14]
call dword [sym.imp.WS2_32.dll_ioctlsocket]
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
movzx ecx, byte [ebp - 0x116]
push eax
movzx eax, byte [ebp - 0x115]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp - 0x111]
push ecx
push eax
movzx eax, byte [ebp - 0x112]
push eax
movzx eax, byte [ebp - 0x113]
push eax
movzx eax, byte [ebp - 0x114]
push eax
push str.Cant_complete_SOCKS4_connection_to__d._d._d._d:_d.___d___request_rejected_or_failed.
push esi
call fcn.0056f390
add esp, 0x20
mov eax, 7
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
movzx ecx, byte [ebp - 0x116]
push eax
movzx eax, byte [ebp - 0x115]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp - 0x111]
push ecx
push eax
movzx eax, byte [ebp - 0x112]
push eax
movzx eax, byte [ebp - 0x113]
push eax
movzx eax, byte [ebp - 0x114]
push eax
push str.Cant_complete_SOCKS4_connection_to__d._d._d._d:_d.___d___request_rejected_because_SOCKS_server_cannot_connect_to_identd_on_the_client.
push esi
call fcn.0056f390
add esp, 0x20
mov eax, 7
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
movzx ecx, byte [ebp - 0x116]
push eax
movzx eax, byte [ebp - 0x115]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp - 0x111]
push ecx
push eax
movzx eax, byte [ebp - 0x112]
push eax
movzx eax, byte [ebp - 0x113]
push eax
movzx eax, byte [ebp - 0x114]
push eax
push str.Cant_complete_SOCKS4_connection_to__d._d._d._d:_d.___d___request_rejected_because_the_client_program_and_identd_report_different_user_ids.
push esi
call fcn.0056f390
add esp, 0x20
mov eax, 7
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
movzx ecx, byte [ebp - 0x116]
push eax
movzx eax, byte [ebp - 0x115]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebp - 0x111]
push ecx
push eax
movzx eax, byte [ebp - 0x112]
push eax
movzx eax, byte [ebp - 0x113]
push eax
movzx eax, byte [ebp - 0x114]
push eax
push str.Cant_complete_SOCKS4_connection_to__d._d._d._d:_d.___d___Unknown.
push esi
call fcn.0056f390
add esp, 0x20
mov eax, 7
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.Failed_to_receive_SOCKS4_connect_request_ack.
push esi
call fcn.0056f390
mov eax, 7
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.Failed_to_send_SOCKS4_connect_request.
push esi
call fcn.0056f390
mov eax, 7
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.Connection_time_out
push esi
call fcn.0056f390
add esp, 8
mov eax, 0x1c
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret