Function at 0x438f40
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x2d0
mov ebx, edx
mov dword [esp + 0x14], ecx
mov edi, dword [ecx + 8]
lea eax, [esp + 0xc0]
push eax
call fcn.0041c2b0
add esp, 4
movups xmm0, xmmword [esp + 0xc0]
movups xmmword [edi + 0x100], xmm0
lea esi, [edi + 8]
cmp dword [ebx + 0x1a4], 0
mov dword [esp + 0xc], esi
je 0x438fbd
push 1
push ebx
call fcn.00411e00
add esp, 8
push esi
push 0
push dword [ebx + 0x1a8]
call dword [ebx + 0x1a4]
add esp, 0xc
mov dword [edi + 0x98], eax
push 0
push ebx
call fcn.00411e00
add esp, 8
mov eax, dword [edi + 0x98]
jmp 0x438fde
push str.cf_socket.c
push 0x16e
push dword [edi + 0x10]
push dword [edi + 0xc]
push dword [edi + 8]
call fcn.00405fd0
add esp, 0x14
mov dword [edi + 0x98], eax
mov ecx, 7
cmp eax, 0xffffffff
mov dword [esp + 0x10], edi
mov esi, dword [esp + 0x14]
je 0x4390d5
mov eax, dword [ebx + 0x18]
mov eax, dword [eax + 0x3d8]
test eax, eax
je 0x43900d
mov ecx, dword [esp + 0xc]
cmp dword [ecx], 0x17
jne 0x43900d
mov dword [edi + 0x30], eax
mov esi, dword [esi + 8]
lea eax, [esi + 0x18]
lea ecx, [esi + 0x9c]
lea edx, [esi + 0xf8]
push edx
push ecx
push dword [esi + 0x14]
push eax
call fcn.0043d920
add esp, 0x10
test al, al
je 0x43908b
mov esi, ebx
mov ebx, dword [esp + 0xc]
cmp dword [ebx], 0x17
jne 0x4391a3
mov eax, dword [edi + 0x98]
mov dword [esp + 0xc0], 0
lea ecx, [esp + 0xc0]
push 4
push ecx
push 0x1b
push 0x29
push eax
call dword [sym.imp.WS2_32.dll_setsockopt]
test byte [esi + 0x6eb], 0x20
je 0x4391d8
mov ecx, dword [esi + 0xd20]
mov eax, str.__Trying___s_:_d...
test ecx, ecx
jne 0x4391bb
jmp 0x4391c1
mov edi, dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
call edi
mov eax, dword [eax]
mov dword [esi + 0x144], eax
call edi
mov esi, dword [eax]
call edi
mov edi, dword [esp + 0x10]
push 0x100
lea ecx, [esp + 0xc4]
push ecx
push dword [eax]
call fcn.0041ba80
add esp, 0xc
push eax
push esi
push str.sa_addr_inet_ntop___failed_with_errno__d:__s
push ebx
call fcn.00443930
add esp, 0x10
mov ecx, 2
mov esi, dword [esp + 0x14]
mov edi, dword [edi + 0x98]
cmp edi, 0xffffffff
je 0x439150
mov dword [esp + 0xc], ecx
mov esi, dword [esi + 0xc]
test esi, esi
je 0x439125
mov eax, dword [esi + 0x10]
mov dword [esp + 0x28], eax
push edi
push ebx
call fcn.004113f0
add esp, 8
cmp dword [esp + 0x28], 0
je 0x439125
push 1
push ebx
call fcn.00411e00
add esp, 8
push edi
push dword [esi + 0x14]
call dword [esi + 0x10]
add esp, 8
push 0
push ebx
call fcn.00411e00
add esp, 8
jmp 0x439138
push str.cf_socket.c
push 0x1aa
push edi
call fcn.004062a0
add esp, 0xc
mov edi, dword [esp + 0x10]
mov dword [edi + 0x98], 0xffffffff
mov esi, dword [esp + 0x14]
mov ecx, dword [esp + 0xc]
jmp 0x439154
mov edi, dword [esp + 0x10]
test byte [ebx + 0x6eb], 0x20
je 0x439199
mov eax, dword [ebx + 0xd20]
test eax, eax
je 0x439173
test esi, esi
je 0x439199
cmp dword [eax + 4], 0
jg 0x439177
jmp 0x439199
test esi, esi
je 0x439199
mov eax, dword [esi]
cmp dword [eax + 8], 0
jle 0x439199
push dword [edi + 0x98]
push ecx
push str.cf_socket_open_______d__fd_d
push esi
push ebx
mov esi, ecx
call fcn.00443a90
mov ecx, esi
add esp, 0x14
mov eax, ecx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
test byte [esi + 0x6eb], 0x20
je 0x4391d8
mov ecx, dword [esi + 0xd20]
mov eax, str.__Trying__s:_d...
test ecx, ecx
je 0x4391c1
cmp dword [ecx + 4], 0
jle 0x4391d8
lea ecx, [edi + 0x9c]
push dword [edi + 0xf8]
push ecx
push eax
push esi
call fcn.004439c0
add esp, 0x10
mov eax, dword [ebx]
cmp eax, 0x17
je 0x4391e8
cmp eax, 2
jne 0x4392de
cmp dword [edi + 0xc], 1
jne 0x4392de
mov ebx, esi
test byte [esi + 0x6ec], 2
mov esi, dword [esp + 0x14]
je 0x43926f
mov eax, dword [edi + 0x98]
mov dword [esp + 0x1cc], 1
lea ecx, [esp + 0x1cc]
push 4
push ecx
push 1
push 6
push eax
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x43926f
test byte [ebx + 0x6eb], 0x20
je 0x43926f
mov eax, dword [ebx + 0xd20]
test eax, eax
je 0x439244
cmp dword [eax + 4], 0
jle 0x43926f
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
lea ecx, [esp + 0xc0]
push 0x100
push ecx
push eax
call fcn.0041ba80
add esp, 0xc
push eax
push str.Could_not_set_TCP_NODELAY:__s
push ebx
call fcn.004439c0
add esp, 0xc
mov edi, dword [edi + 0x98]
mov dword [esp + 0xc0], 0x4020
mov dword [esp + 0x1cc], 0
mov dword [esp + 0x40], 4
mov eax, dword [0xa96158]
cmp eax, 2
je 0x43965a
test eax, eax
jne 0x439610
sub esp, 0x14
movaps xmm0, xmmword [0x9573e0]
movups xmmword [esp], xmm0
mov dword [esp + 0x10], 3
call fcn.00426010
add esp, 0x14
test al, al
je 0x439606
mov dword [0xa96158], 2
jmp 0x43965a
mov edi, dword [edi + 0x98]
mov dword [esp + 0xc0], 0x4020
mov dword [esp + 0x1cc], 0
mov dword [esp + 0x40], 4
mov eax, dword [0xa96158]
cmp eax, 2
mov ebx, esi
mov esi, dword [esp + 0x14]
je 0x43939c
test eax, eax
jne 0x439352
sub esp, 0x14
movaps xmm0, xmmword [0x9573e0]
movups xmmword [esp], xmm0
mov dword [esp + 0x10], 3
call fcn.00426010
add esp, 0x14
test al, al
je 0x439348
mov dword [0xa96158], 2
jmp 0x43939c
mov dword [0xa96158], 1
lea eax, [esp + 0x40]
lea ecx, [esp + 0x1cc]
push eax
push ecx
push 0x1001
push 0xffff
push edi
call dword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x439381
cmp dword [esp + 0x1cc], 0x4020
jg 0x43939c
push 4
lea eax, [esp + 0xc4]
push eax
push 0x1001
push 0xffff
push edi
call dword [sym.imp.WS2_32.dll_setsockopt]
mov edi, dword [esp + 0x10]
cmp dword [ebx + 0x19c], 0
je 0x439403
push 1
push ebx
call fcn.00411e00
add esp, 8
push 0
push dword [edi + 0x98]
push dword [ebx + 0x1a0]
call dword [ebx + 0x19c]
add esp, 0xc
mov edi, eax
push 0
push ebx
call fcn.00411e00
add esp, 8
cmp edi, 2
je 0x439418
mov ecx, 0x2a
test edi, edi
mov edi, dword [esp + 0x10]
mov eax, dword [esp + 0xc]
jne 0x4390d5
mov dword [esp + 0x34], 0
mov eax, dword [eax]
cmp eax, 0x17
jne 0x43942d
jmp 0x439436
mov dword [esp + 0x34], 0
mov eax, dword [esp + 0xc]
mov eax, dword [eax]
cmp eax, 0x17
jne 0x43942d
jmp 0x439436
mov al, 1
mov dword [esp + 0x34], eax
mov edi, dword [esp + 0x10]
mov eax, dword [esp + 0xc]
mov eax, dword [eax]
cmp eax, 0x17
je 0x439436
cmp eax, 2
jne 0x439939
mov dword [esp + 0x18], eax
mov eax, dword [esi + 0xc]
mov dword [esp + 0x30], eax
mov eax, dword [edi + 0x98]
mov dword [esp + 0x28], eax
lea eax, [edi + 0x18]
push eax
call fcn.00460030
add esp, 4
mov dword [esp + 0x2c], 0
mov edi, dword [ebx + 0x570]
mov esi, dword [ebx + 0x574]
mov edx, dword [ebx + 0x578]
test esi, esi
mov dword [esp + 0x20], esi
cmove esi, edi
mov ecx, esi
mov dword [esp + 0x1c], edx
or ecx, edx
mov dword [esp + 0x24], edi
or ecx, edi
setne cl
movzx edi, word [ebx + 0x178]
test di, di
setne dl
or dl, cl
cmp dl, 1
jne 0x439931
mov ecx, ebx
mov dword [esp + 0x38], edi
movzx ebx, di
mov dword [esp + 0xc], ecx
movzx ecx, word [ecx + 0x17a]
mov dword [esp + 0x3c], ecx
xorps xmm0, xmm0
movaps xmmword [esp + 0xb0], xmm0
movaps xmmword [esp + 0xa0], xmm0
movaps xmmword [esp + 0x90], xmm0
movaps xmmword [esp + 0x80], xmm0
movaps xmmword [esp + 0x70], xmm0
movaps xmmword [esp + 0x60], xmm0
movaps xmmword [esp + 0x50], xmm0
movaps xmmword [esp + 0x40], xmm0
test esi, esi
je 0x4395d1
mov edi, esi
push esi
mov esi, eax
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
add esp, 4
cmp eax, 0xfe
ja 0x4395d1
mov ecx, esi
mov esi, edi
xorps xmm0, xmm0
movaps xmmword [esp + 0x1b0], xmm0
movaps xmmword [esp + 0x1a0], xmm0
movaps xmmword [esp + 0x190], xmm0
movaps xmmword [esp + 0x180], xmm0
movaps xmmword [esp + 0x170], xmm0
movaps xmmword [esp + 0x160], xmm0
movaps xmmword [esp + 0x150], xmm0
movaps xmmword [esp + 0x140], xmm0
movaps xmmword [esp + 0x130], xmm0
movaps xmmword [esp + 0x120], xmm0
movaps xmmword [esp + 0x110], xmm0
movaps xmmword [esp + 0x100], xmm0
movaps xmmword [esp + 0xf0], xmm0
movaps xmmword [esp + 0xe0], xmm0
movaps xmmword [esp + 0xd0], xmm0
movaps xmmword [esp + 0xc0], xmm0
mov edi, dword [esp + 0x1c]
test edi, edi
mov edx, dword [esp + 0x18]
je 0x43967d
mov esi, dword [esp + 0x30]
movzx eax, byte [esi + 0x3e3]
mov byte [esp + 0x1c], al
cmp edx, 2
je 0x439704
cmp edx, 0x17
jne 0x43970c
mov al, 2
jmp 0x439706
mov eax, dword [esp + 0x18]
cmp eax, 2
je 0x4398c3
xor edi, edi
cmp eax, 0x17
jne 0x4398db
mov word [esp + 0x40], 0x17
push ebx
call dword [sym.imp.WS2_32.dll_htons]
mov word [esp + 0x42], ax
mov edi, 0x1c
jmp 0x4398db
mov dword [0xa96158], 1
lea eax, [esp + 0x40]
lea ecx, [esp + 0x1cc]
push eax
push ecx
push 0x1001
push 0xffff
push edi
call dword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x43963f
cmp dword [esp + 0x1cc], 0x4020
jg 0x43965a
lea eax, [esp + 0xc0]
push 4
push eax
push 0x1001
push 0xffff
push edi
call dword [sym.imp.WS2_32.dll_setsockopt]
test byte [ebx + 0x6ec], 0x80
mov edi, dword [esp + 0x10]
je 0x4393a0
mov edx, dword [edi + 0x98]
mov ecx, ebx
call fcn.00439bd0
jmp 0x4393a0
push 0x100
lea eax, [esp + 0xc4]
push eax
push esi
mov eax, dword [esp + 0x3c]
push dword [eax + 0x3d8]
push ecx
push edx
call fcn.00460100
add esp, 0x18
cmp eax, 2
je 0x439822
cmp eax, 1
mov edx, dword [esp + 0x18]
je 0x4397c4
test eax, eax
jne 0x439a8c
mov edi, dword [esp + 0x24]
cmp dword [esp + 0x20], 0
je 0x4395a9
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
mov ebx, dword [esp + 0xc]
mov dword [ebx + 0x8f0], eax
lea eax, [esp + 0x1cc]
push 0x100
push eax
push edi
call fcn.0041ba80
add esp, 0xc
push eax
push edi
push dword [esp + 0x28]
push str.Couldnt_bind_to_interface__s_with_errno__d:__s
jmp 0x439814
mov al, 1
mov byte [esi + 0x3e3], al
lea eax, [esp + 0x2c]
push eax
push 0
push 0x50
push edi
push dword [esp + 0x1c]
call fcn.004512a0
add esp, 0x14
cmp eax, 1
jne 0x439738
lea eax, [esp + 0x2c]
push eax
push dword [esp + 0x10]
call fcn.004355d0
add esp, 8
movzx eax, byte [esp + 0x1c]
mov byte [esi + 0x3e3], al
mov eax, dword [esp + 0x2c]
test eax, eax
je 0x4397d6
mov dword [esp + 0x1c], edi
mov eax, dword [eax]
mov edi, dword [eax + 4]
lea ecx, [esp + 0xc0]
push 0x100
push ecx
push eax
call fcn.00450ac0
add esp, 0xc
mov esi, dword [esp + 0xc]
test byte [esi + 0x6eb], 0x20
je 0x4397aa
mov eax, dword [esi + 0xd20]
test eax, eax
je 0x43978b
cmp dword [eax + 4], 0
jle 0x4397aa
push edi
lea eax, [esp + 0xc4]
push eax
push dword [esp + 0x20]
push dword [esp + 0x28]
push str.Name__s_family__i_resolved_to__s_family__i
push esi
call fcn.004439c0
add esp, 0x18
lea eax, [esp + 0x2c]
push eax
push esi
call fcn.00451a20
add esp, 8
mov edx, dword [esp + 0x18]
cmp edi, edx
je 0x439877
mov ecx, 7
mov ebx, dword [esp + 0xc]
mov edi, dword [esp + 0x10]
jmp 0x4390d1
mov dword [esp + 0x24], edi
mov ebx, dword [esp + 0xc]
and byte [ebx + 0xd60], 0xf7
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
mov dword [ebx + 0x8f0], eax
lea eax, [esp + 0x1cc]
push 0x100
push eax
push edi
call fcn.0041ba80
add esp, 0xc
push eax
push edi
push dword [esp + 0x2c]
push str.Couldnt_bind_to__s_with_errno__d:__s
push ebx
call fcn.00443930
add esp, 0x14
jmp 0x439a7e
mov eax, dword [esp + 0xc]
test byte [eax + 0x6eb], 0x20
je 0x439861
mov eax, dword [esp + 0xc]
mov eax, dword [eax + 0xd20]
test eax, eax
je 0x439843
cmp dword [eax + 4], 0
jle 0x439861
push dword [esp + 0x18]
lea eax, [esp + 0xc4]
push eax
push esi
push str.Local_Interface__s_is_ip__s_using_address_family__i
push dword [esp + 0x1c]
call fcn.004439c0
add esp, 0x14
lea edi, [esp + 0xc0]
cmp dword [esp + 0x20], 0
mov edx, dword [esp + 0x18]
je 0x4395a9
xor edi, edi
cmp edx, 2
je 0x4398a8
cmp edx, 0x17
jne 0x4398db
lea esi, [esp + 0xc0]
push 0x25
push esi
call sub.api_ms_win_crt_private_l1_1_0.dll_strchr
add esp, 8
test eax, eax
je 0x439aa0
mov edi, eax
inc edi
mov byte [eax], 0
jmp 0x439aa2
lea eax, [esp + 0x44]
lea ecx, [esp + 0xc0]
push eax
push ecx
push 2
call fcn.00462fb0
add esp, 0xc
test eax, eax
jle 0x4398db
mov word [esp + 0x40], 2
push ebx
call dword [sym.imp.WS2_32.dll_htons]
mov word [esp + 0x42], ax
mov edi, 0x10
lea eax, [esp + 0x40]
push edi
push eax
push dword [esp + 0x30]
call dword [sym.imp.WS2_32.dll_bind]
test eax, eax
js 0x4399bf
mov edi, dword [esp + 0x38]
mov ebx, dword [esp + 0xc]
test byte [ebx + 0x6eb], 0x20
je 0x439926
mov eax, dword [ebx + 0xd20]
test eax, eax
je 0x439914
cmp dword [eax + 4], 0
jle 0x439926
movzx eax, di
push eax
push str.Local_port:__hu
push ebx
call fcn.004439c0
add esp, 0xc
mov eax, dword [esp + 0x30]
or byte [eax + 0x2a2], 0x10
mov edi, dword [esp + 0x10]
mov esi, dword [esp + 0x14]
push 1
push dword [edi + 0x98]
call fcn.004651d0
add esp, 8
test eax, eax
js 0x4399a9
mov eax, dword [edi + 0x148]
xor ecx, ecx
cmp dword [edi + 0xc], 2
setne cl
and eax, 0xfffffff7
lea eax, [eax + ecx*8]
mov dword [edi + 0x148], eax
xor ecx, ecx
cmp byte [esp + 0x34], 0
je 0x439154
mov ecx, dword [esi + 8]
mov edx, ebx
call fcn.00438b40
lea eax, [esp + 0xc0]
push eax
call fcn.0041c2b0
xor ecx, ecx
add esp, 4
movups xmm0, xmmword [esp + 0xc0]
movups xmmword [edi + 0x110], xmm0
or byte [esi + 0x14], 1
jmp 0x439154
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [edi + 0x144], eax
mov ecx, 1
jmp 0x4390d5
mov dword [esp + 0x18], edi
mov ecx, ebx
inc ecx
mov edi, dword [esp + 0x38]
mov ebx, dword [esp + 0x3c]
jmp 0x439a17
movzx eax, cx
dec eax
push eax
push str.Bind_to_local_port__d_failed__trying_next
push dword [esp + 0x14]
call fcn.004439c0
mov ecx, esi
add esp, 0xc
movzx eax, cx
push eax
call dword [sym.imp.WS2_32.dll_ntohs]
mov word [esp + 0x42], ax
push dword [esp + 0x18]
lea eax, [esp + 0x44]
push eax
push dword [esp + 0x30]
call dword [sym.imp.WS2_32.dll_bind]
mov ecx, esi
inc ecx
inc edi
dec ebx
test eax, eax
jns 0x4398f7
cmp ebx, 2
jl 0x439a46
test cx, cx
je 0x439a46
mov eax, dword [esp + 0xc]
test byte [eax + 0x6eb], 0x20
mov esi, ecx
je 0x4399e8
mov eax, dword [esp + 0xc]
mov eax, dword [eax + 0xd20]
test eax, eax
je 0x4399d0
cmp dword [eax + 4], 0
jg 0x4399d0
jmp 0x4399e8
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
mov ebx, dword [esp + 0xc]
mov dword [ebx + 0x8f0], eax
push 0x100
lea eax, [esp + 0xc4]
push eax
push edi
call fcn.0041ba80
add esp, 0xc
push eax
push edi
push str.bind_failed_with_errno__d:__s
push ebx
call fcn.00443930
add esp, 0x10
mov ecx, 0x2d
mov edi, dword [esp + 0x10]
jmp 0x4390d1
mov edi, dword [esp + 0x24]
cmp dword [esp + 0x20], 0
jne 0x4397da
jmp 0x4395a9
xor edi, edi
lea eax, [esp + 0x48]
push eax
push esi
push 0x17
call fcn.00462fb0
add esp, 0xc
test eax, eax
jle 0x4395fc
mov word [esp + 0x40], 0x17
push ebx
call dword [sym.imp.WS2_32.dll_htons]
mov word [esp + 0x42], ax
test edi, edi
je 0x4395fc
push 0xa
push 0
push edi
call sub.api_ms_win_crt_convert_l1_1_0.dll_strtoul
add esp, 0xc
mov dword [esp + 0x58], eax
jmp 0x4395fc