Function at 0x472980
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov byte [ebp - 1], 0
mov eax, dword [esi + 0x98]
or eax, dword [esi + 0x9c]
jne 0x4729b7
mov eax, dword [esi + 0xa0]
or eax, dword [esi + 0xa4]
jne 0x4729b7
push 7
push esi
call fcn.004730b0
add esp, 8
mov ebx, dword [ebp + 0x10]
mov edi, dword [ebp + 0xc]
or dword [ebx], 2
cmp dword [esi + 0x130], 0
jne 0x472bc3
cmp dword [esi + 0xd30], 0
jne 0x4729f3
push dword [esi + 0x928]
call dword [0x5be010]
add esp, 4
mov dword [esi + 0xd30], eax
test eax, eax
je 0x472afb
cmp byte [esi + 0x586], 0
mov eax, dword [esi + 0xd30]
mov dword [esi + 0x134], eax
jne 0x472cd0
cmp dword [esi + 0x108], 2
mov ecx, dword [esi + 0x138]
jne 0x472a68
cmp dword [ecx + 0x1b0], 2
jne 0x472a68
and dword [esi + 0x124], 0xfffffffd
lea eax, [ebp - 0x18]
push eax
mov dword [esi + 0x108], 1
call fcn.0046ae50
push 0
movups xmm0, xmmword [eax]
movups xmmword [esi + 0xf8], xmm0
and dword [ebx], 0xfffffffd
mov eax, dword [esi + 0xaf4]
cdq
push edx
push eax
push esi
call fcn.004589e0
add esp, 0x14
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0x548]
test dword [eax + 0x40], 0x40003
je 0x472a82
cmp dword [ecx + 0x1b0], 1
sete byte [ebp - 1]
lea eax, [ebp + 8]
push eax
push dword [esi + 0x928]
push edi
call fcn.00471050
add esp, 0xc
test eax, eax
jne 0x472d65
mov ebx, dword [ebp + 8]
test ebx, ebx
je 0x472cd0
jle 0x472cdd
mov dword [esi + 0x130], ebx
cmp byte [ebp - 1], al
jne 0x472ba2
cmp byte [esi + 0xb2a], al
je 0x472ba2
cmp dword [esi + 0xd90], eax
jne 0x472b07
mov eax, dword [esi + 0x928]
add eax, eax
push eax
call dword [0x5be010]
add esp, 4
mov dword [esi + 0xd90], eax
test eax, eax
jne 0x472b07
push str.Failed_to_alloc_scratch_buffer_
push esi
call fcn.00466670
add esp, 8
pop edi
pop esi
mov eax, 0x1b
pop ebx
mov esp, ebp
pop ebp
ret
xor ecx, ecx
xor edx, edx
test ebx, ebx
jle 0x472b8a
mov edi, dword [ebp + 8]
nop dword [eax]
nop word [eax + eax]
mov eax, dword [esi + 0x134]
mov bl, byte [edx + eax]
mov eax, dword [esi + 0xd90]
cmp bl, 0xa
jne 0x472b7b
mov byte [ecx + eax], 0xd
inc ecx
mov eax, dword [esi + 0xd90]
mov byte [ecx + eax], bl
cmp byte [esi + 0xb2a], 0
jne 0x472b7e
mov eax, dword [esi + 0x1084]
mov ebx, dword [esi + 0x1080]
mov dword [ebp + 0x10], eax
mov eax, ebx
and eax, dword [ebp + 0x10]
cmp eax, 0xffffffff
je 0x472b7e
mov eax, dword [ebp + 0x10]
add ebx, 1
mov dword [esi + 0x1080], ebx
adc eax, 0
mov dword [esi + 0x1084], eax
jmp 0x472b7e
mov byte [ecx + eax], bl
inc edx
inc ecx
cmp edx, edi
jl 0x472b20
mov edi, dword [ebp + 0xc]
mov ebx, dword [ebp + 8]
cmp ecx, ebx
je 0x472ba2
mov eax, dword [esi + 0xd90]
mov ebx, ecx
mov dword [esi + 0x134], eax
mov dword [esi + 0x130], ecx
mov eax, dword [edi + 0x548]
test dword [eax + 0x40], 0x30000
je 0x472bc3
push ebx
push edi
call fcn.00477f70
add esp, 8
test eax, eax
jne 0x472d65
lea eax, [ebp - 8]
push eax
push dword [esi + 0x130]
push dword [esi + 0x134]
push dword [edi + 0x570]
push edi
call fcn.00466bd0
add esp, 0x14
test eax, eax
jne 0x472d65
mov ebx, dword [edi + 0x570]
push eax
push eax
lea eax, [ebp + 0x10]
push eax
push 4
lea eax, [ebp + 8]
push eax
push 0
push 0
push 0x4004747b
push ebx
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
jne 0x472c27
push 4
lea eax, [ebp + 8]
push eax
push 0x1001
push 0xffff
push ebx
call dword [sym.imp.WS2_32.dll_setsockopt]
cmp byte [esi + 0xb42], 0
je 0x472c44
push dword [ebp - 8]
push dword [esi + 0x134]
push 4
push esi
call fcn.004665f0
add esp, 0x10
mov eax, dword [ebp - 8]
cdq
add dword [esi + 0xa0], eax
adc dword [esi + 0xa4], edx
push dword [esi + 0xa4]
push dword [esi + 0xa0]
push esi
call fcn.00472f80
add esp, 0xc
cmp byte [esi + 0x58a], 0
je 0x472c7b
cmp byte [esi + 0x58c], 0
je 0x472cac
mov eax, dword [esi + 0xa0]
cmp eax, dword [esi + 0x1080]
jne 0x472cac
mov eax, dword [esi + 0xa4]
cmp eax, dword [esi + 0x1084]
jne 0x472cac
push str.We_are_completely_uploaded_and_fine_n
push esi
mov byte [esi + 0x586], 1
call fcn.00466750
add esp, 8
mov eax, dword [esi + 0x130]
mov ecx, dword [ebp - 8]
cmp eax, ecx
je 0x472d01
add dword [esi + 0x134], ecx
sub eax, ecx
pop edi
mov dword [esi + 0x130], eax
xor eax, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
test byte [esi + 0x124], 0x20
jne 0x472d63
and dword [esi + 0x124], 0xfffffffd
cmp byte [edi + 0x50e], 0
je 0x472d63
push edi
call fcn.004719c0
add esp, 4
test eax, eax
je 0x472d63
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp dword [esi + 0xd30], 0
jne 0x472d27
push dword [esi + 0x928]
call dword [0x5be010]
add esp, 4
mov dword [esi + 0xd30], eax
test eax, eax
je 0x472afb
cmp byte [esi + 0x586], 0
mov eax, dword [esi + 0xd30]
mov dword [esi + 0x134], eax
mov dword [esi + 0x130], 0
je 0x472d63
and dword [esi + 0x124], 0xfffffffd
cmp byte [edi + 0x50e], 0
je 0x472d63
push edi
call fcn.004719c0
add esp, 4
test eax, eax
jne 0x472d65
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret