Function at 0x5c42f0
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [ebp + 0x10]
push ebx
push esi
mov esi, dword [ebp + 8]
or dword [eax], 2
push edi
xor edi, edi
mov byte [ebp + 0xb], 0
mov ebx, dword [esi + 0x114]
test ebx, ebx
je 0x5c4372
mov eax, dword [esi + 0x494]
shr eax, 5
cmp ebx, eax
jge 0x5c4577
cmp byte [esi + 0x144], 0
jne 0x5c4577
cmp byte [esi + 0x13f], 0
jne 0x5c4577
mov ecx, dword [esi + 0xa0]
mov eax, ebx
sub ecx, dword [esi + 0xa8]
mov edi, dword [esi + 0xa4]
sbb edi, dword [esi + 0xac]
cdq
add ecx, eax
adc edi, edx
cmp ecx, dword [esi + 0xc28]
jne 0x5c4370
cmp edi, dword [esi + 0xc2c]
je 0x5c4577
mov edi, ebx
mov eax, dword [esi + 0x870]
test eax, eax
jne 0x5c4399
push dword [esi + 0x494]
call dword [0x8f7f4c]
add esp, 4
mov dword [esi + 0x870], eax
test eax, eax
je 0x5c44d8
mov ecx, eax
test edi, edi
je 0x5c43ba
mov edx, dword [esi + 0x118]
cmp edx, eax
je 0x5c43ba
push edi
push edx
push eax
call fcn.00704c30
mov ecx, dword [esi + 0x870]
add esp, 0xc
cmp byte [esi + 0x13f], 0
mov dword [esi + 0x118], ecx
jne 0x5c477a
cmp dword [esi + 0xf0], 2
mov edx, dword [esi + 0x11c]
jne 0x5c4429
cmp dword [edx + 0x30], 2
jne 0x5c4429
and dword [esi + 0xdc], 0xfffffffd
lea eax, [ebp - 0x14]
push eax
mov dword [esi + 0xf0], 1
call fcn.005aec80
push 0
movups xmm0, xmmword [eax]
mov eax, dword [ebp + 0x10]
movups xmmword [esi + 0xe0], xmm0
and dword [eax], 0xfffffffd
mov eax, dword [esi + 0x630]
cdq
push edx
push eax
push esi
call fcn.005a99c0
add esp, 0x14
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 0x1c4]
test dword [eax + 0x44], 0x40003
je 0x5c4444
cmp dword [edx + 0x30], 1
sete bl
jmp 0x5c4447
mov bl, byte [ebp + 0xb]
lea eax, [ecx + edi]
mov dword [esi + 0x118], eax
lea eax, [ebp + 0x10]
push eax
mov eax, dword [esi + 0x494]
sub eax, edi
push eax
push esi
call fcn.005c2dc0
sub dword [esi + 0x118], edi
add esp, 0xc
test eax, eax
jne 0x5c4795
mov eax, dword [ebp + 0x10]
add eax, edi
mov dword [ebp + 0x10], eax
je 0x5c477a
test eax, eax
jle 0x5c4783
mov dword [esi + 0x114], eax
test bl, bl
jne 0x5c4577
cmp byte [esi + 0x662], bl
je 0x5c4577
mov eax, dword [esi + 0x8e8]
test eax, eax
jne 0x5c44e4
mov eax, dword [esi + 0x494]
add eax, eax
push eax
call dword [0x8f7f4c]
add esp, 4
mov dword [esi + 0x8e8], eax
test eax, eax
jne 0x5c44e4
push str.Failed_to_alloc_scratch_buffer
push esi
call fcn.005bada0
add esp, 8
mov eax, 0x1b
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
test edi, edi
je 0x5c44f8
push edi
push dword [esi + 0x118]
push eax
call fcn.00704c30
add esp, 0xc
mov eax, dword [ebp + 0x10]
mov ecx, edi
cmp edi, eax
jge 0x5c4561
mov eax, dword [esi + 0x118]
mov dl, byte [edi + eax]
mov eax, dword [esi + 0x8e8]
cmp dl, 0xa
jne 0x5c4555
mov byte [eax + ecx], 0xd
inc ecx
mov eax, dword [esi + 0x8e8]
mov byte [ecx + eax], dl
cmp byte [esi + 0x662], 0
jne 0x5c4558
mov edx, dword [esi + 0xc28]
mov eax, edx
mov ebx, dword [esi + 0xc2c]
and eax, ebx
cmp eax, 0xffffffff
je 0x5c4558
add edx, 1
mov dword [esi + 0xc28], edx
adc ebx, 0
mov dword [esi + 0xc2c], ebx
jmp 0x5c4558
mov byte [eax + ecx], dl
mov eax, dword [ebp + 0x10]
inc edi
inc ecx
cmp edi, eax
jl 0x5c4501
cmp ecx, eax
je 0x5c4577
mov eax, dword [esi + 0x8e8]
mov dword [esi + 0x118], eax
mov dword [esi + 0x114], ecx
mov ebx, dword [ebp + 0xc]
lea eax, [ebp - 4]
push eax
push dword [esi + 0x114]
push dword [esi + 0x118]
push dword [ebx + 0x1e4]
push esi
call fcn.005bb4f0
add esp, 0x14
test eax, eax
jne 0x5c4795
lea eax, [ebp - 0x24]
push eax
call fcn.005aec80
mov edx, eax
sub esp, 0xc
mov ecx, esp
sub esp, 0x10
mov eax, esp
movups xmm0, xmmword [edx]
movups xmmword [ebp - 0x14], xmm0
movups xmm0, xmmword [esi + 0x128]
movups xmmword [ecx], xmm0
movups xmm0, xmmword [edx]
movups xmmword [eax], xmm0
call fcn.005aed30
add esp, 0x20
test edx, edx
jl 0x5c462c
jg 0x5c45e2
cmp eax, 0x3e8
jbe 0x5c462c
mov edi, dword [ebx + 0x1e4]
lea eax, [ebp + 8]
push 0
push 0
push eax
push 4
lea eax, [ebp + 0x10]
push eax
push 0
push 0
push 0x4004747b
push edi
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
jne 0x5c4621
push 4
lea eax, [ebp + 0x10]
push eax
push 0x1001
push 0xffff
push edi
call dword [sym.imp.WS2_32.dll_setsockopt]
movups xmm0, xmmword [ebp - 0x14]
movups xmmword [esi + 0x128], xmm0
mov ebx, dword [esi + 0xa8]
mov eax, ebx
mov edi, dword [esi + 0xac]
or eax, edi
mov dword [ebp + 0x10], edi
je 0x5c4681
mov eax, dword [ebp - 4]
cdq
cmp edi, edx
jg 0x5c464f
jl 0x5c4656
cmp ebx, eax
jb 0x5c4656
mov ebx, eax
mov dword [ebp + 0x10], edx
mov edi, edx
push ebx
push dword [esi + 0x118]
push 2
push esi
call fcn.005bad00
add esp, 0x10
sub dword [esi + 0xa8], ebx
sbb dword [esi + 0xac], edi
mov edi, dword [ebp - 4]
mov eax, edi
cdq
sub eax, ebx
sbb edx, dword [ebp + 0x10]
jmp 0x5c4687
mov edi, dword [ebp - 4]
mov eax, edi
cdq
mov ecx, eax
mov dword [ebp + 0x10], edx
or ecx, edx
mov dword [ebp + 8], eax
je 0x5c46d1
mov ebx, dword [ebp + 8]
push eax
mov eax, dword [esi + 0x118]
sub eax, ebx
add eax, edi
push eax
push 4
push esi
call fcn.005bad00
add dword [esi + 0xa0], ebx
mov eax, dword [ebp + 0x10]
adc dword [esi + 0xa4], eax
push dword [esi + 0xa4]
push dword [esi + 0xa0]
push esi
call fcn.005ca1c0
mov edi, dword [ebp - 4]
add esp, 0x1c
cmp byte [esi + 0x144], 0
je 0x5c46e3
cmp byte [esi + 0x146], 0
je 0x5c4717
mov eax, dword [esi + 0xa0]
cmp eax, dword [esi + 0xc28]
jne 0x5c4717
mov eax, dword [esi + 0xa4]
cmp eax, dword [esi + 0xc2c]
jne 0x5c4717
push str.We_are_completely_uploaded_and_fine
push esi
mov byte [esi + 0x13f], 1
call fcn.005bae40
mov edi, dword [ebp - 4]
add esp, 8
mov eax, dword [esi + 0x114]
cmp eax, edi
je 0x5c4738
add dword [esi + 0x118], edi
sub eax, edi
mov dword [esi + 0x114], eax
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esi + 0x870]
test eax, eax
jne 0x5c475f
push dword [esi + 0x494]
call dword [0x8f7f4c]
add esp, 4
mov dword [esi + 0x870], eax
test eax, eax
je 0x5c44d8
cmp byte [esi + 0x13f], 0
mov dword [esi + 0x118], eax
mov dword [esi + 0x114], 0
je 0x5c4793
jmp 0x5c4783
test byte [esi + 0xdc], 0x20
jne 0x5c4793
and dword [esi + 0xdc], 0xfffffffd
push esi
call fcn.005ba740
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret