Function at 0x4168a0
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x5c4
mov eax, dword [0x4ff004]
xor eax, esp
mov dword [esp + 0x5c0], eax
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0x14]
push edi
mov dword [esp + 0x24], eax
mov eax, dword [ebp + 0xc]
push 0x200
mov dword [esp + 0x38], edx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x34], eax
mov dword [esp + 0x10], esi
call fcn.00449be3
mov ecx, dword [esp + 0x1c]
add esp, 4
mov ebx, eax
mov dword [esp + 0x20], 0x200
mov edx, esi
mov dword [esp + 0x14], ebx
xor edi, edi
call fcn.00415fa0
mov dword [esp + 0x10], eax
test eax, eax
je 0x416945
call fcn.00408c40
mov ecx, edx
mov edx, dword [ebp + 0x10]
add eax, edx
push esi
push edi
adc ecx, edi
mov dword [esp + 0x30], eax
push edx
push dword [esp + 0x40]
mov edx, dword [esp + 0x20]
mov dword [esp + 0x3c], ecx
lea ecx, [esp + 0x20]
call fcn.004161d0
add esp, 0x10
test eax, eax
jns 0x416968
push dword [esp + 0x10]
call dword [sym.imp.WS2_32.dll_closesocket]
push ebx
call fcn.004460f9
add esp, 4
mov eax, 0xfffffff8
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x5c0]
xor ecx, esp
call fcn.004423fe
mov esp, ebp
pop ebp
ret
push dword [esp + 0x18]
lea eax, [esp + 0x1cc]
push dword [esp + 0x28]
push str.GET__s_HTTP_1.1_r_nHost:__s_r_nConnection:_close_r_nAccept_Encoding:_r_nUser_Agent:_Yoctopuce_r_n_r_n
push 0x200
push eax
call fcn.0041c830
mov ecx, dword [esp + 0x24]
lea edx, [esp + 0x1dc]
add esp, 0x14
push esi
push eax
call fcn.00416570
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
js 0x416bc2
call fcn.00408c40
mov ecx, dword [esp + 0x28]
sub ecx, eax
mov eax, dword [esp + 0x2c]
sbb eax, edx
mov dword [esp + 0x3c], eax
jne 0x4169ca
test ecx, ecx
je 0x416b16
mov eax, dword [esp + 0x10]
inc eax
mov dword [esp + 0x24], eax
call fcn.00408c40
mov esi, dword [esp + 0x28]
mov ecx, dword [esp + 0x2c]
sub esi, eax
mov eax, 0x10624dd3
sbb ecx, edx
imul esi
push 0
sar edx, 6
mov eax, edx
push 0x3e8
shr eax, 0x1f
push ecx
add eax, edx
push esi
mov dword [esp + 0x48], eax
call fcn.0045f970
imul eax, eax, 0x3e8
mov dword [esp + 0x40], 1
sub esi, eax
imul eax, esi, 0x3e8
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0x10]
mov dword [esp + 0x44], eax
lea eax, [esp + 0x38]
push eax
push 0
push 0
lea eax, [esp + 0x4c]
push eax
push dword [esp + 0x34]
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
js 0x416b92
mov esi, dword [esp + 0x20]
lea eax, [edi + 0x100]
cmp eax, esi
jl 0x416a8c
add esi, esi
push esi
mov dword [esp + 0x24], esi
call fcn.00449be3
add esp, 4
mov dword [esp + 0x14], eax
test ebx, ebx
je 0x416a86
push edi
push ebx
push eax
call fcn.00444290
add esp, 0xc
push ebx
call fcn.004460f9
mov eax, dword [esp + 0x18]
add esp, 4
mov ebx, eax
mov dword [esp + 0x14], ebx
push 0
mov eax, esi
sub eax, edi
push eax
lea eax, [edi + ebx]
push eax
push dword [esp + 0x1c]
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
je 0x416b53
jns 0x416ae3
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x416abc
xor eax, eax
jmp 0x416aed
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, dword [esp + 0xc]
test esi, esi
jne 0x416acf
lea eax, [esi - 8]
jmp 0x416ae3
push esi
push eax
mov edx, 0x2dc
mov ecx, str.ytcp
call fcn.00415bd0
add esp, 8
mov ecx, eax
test eax, eax
js 0x416b84
add edi, eax
call fcn.00408c40
mov ecx, dword [esp + 0x28]
sub ecx, eax
mov eax, dword [esp + 0x2c]
sbb eax, edx
mov dword [esp + 0x1c], eax
jne 0x4169d3
test ecx, ecx
jne 0x4169d3
mov esi, dword [esp + 0xc]
test esi, esi
jne 0x416b27
mov dword [esp + 0x18], 0xfffffff9
jmp 0x416bc2
push 0x375
push str.ytcp
push str.Timeout
push str._s___s:_d_
push 0x100
push esi
call fcn.0041c830
add esp, 0x18
mov dword [esp + 0x18], 0xfffffff9
jmp 0x416bc2
mov esi, dword [esp + 0xc]
test esi, esi
je 0x416b7d
push 0x2d1
push str.ytcp
push str.No_more_data
push str._s___s:_d_
push 0x100
push esi
call fcn.0041c830
add esp, 0x18
mov eax, 0xfffffff7
mov ecx, eax
cmp eax, 0xfffffff7
mov edx, edi
cmovne edx, ecx
mov dword [esp + 0x18], edx
jmp 0x416bc2
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, dword [esp + 0xc]
test esi, esi
jne 0x416baa
mov dword [esp + 0x18], 0xfffffff8
jmp 0x416bc2
push esi
push eax
mov edx, 0x359
mov ecx, str.ytcp
call fcn.00415bd0
add esp, 8
mov dword [esp + 0x18], eax
push dword [esp + 0x10]
call dword [sym.imp.WS2_32.dll_closesocket]
mov esi, dword [esp + 0x18]
test esi, esi
jns 0x416bf6
push ebx
call fcn.004460f9
add esp, 4
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x5c0]
xor ecx, esp
call fcn.004423fe
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x30]
push 0xc
push str.HTTP_1.1_200
push ebx
mov dword [eax], ebx
call fcn.00445e80
add esp, 0xc
test eax, eax
jne 0x416df7
push 4
push str._r_n_r_n
mov edx, esi
mov ecx, ebx
call fcn.0041ca80
add esp, 8
mov dword [esp + 0xc], eax
test eax, eax
jle 0x416bdd
lea edi, [eax + ebx]
mov esi, ebx
xor bl, bl
cmp dword [esp + 0x14], edi
jae 0x416bdd
nop dword [eax]
lea eax, [esp + 0x148]
nop word [eax + eax]
lea ecx, [esp + 0x1c8]
cmp eax, ecx
jae 0x416c92
mov bl, byte [esi]
inc esi
cmp bl, 0x3a
je 0x416c92
cmp bl, 0xd
je 0x416c92
cmp bl, 0xa
je 0x416c92
cmp bl, 0x20
je 0x416c75
mov byte [eax], bl
inc eax
cmp esi, edi
jb 0x416c50
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x5c0]
xor ecx, esp
call fcn.004423fe
mov esp, ebp
pop ebp
ret
cmp esi, edi
jae 0x416bdd
mov byte [eax], 0
cmp bl, 0x3a
jne 0x416d16
lea eax, [esp + 0x148]
inc esi
push str.Transfer_Encoding
push eax
call fcn.00445fc4
add esp, 8
mov ecx, 0
test eax, eax
mov eax, 1
cmove ecx, eax
lea eax, [esp + 0x148]
cmp esi, edi
jae 0x416cf6
lea edx, [esp + 0x1c8]
cmp eax, edx
jae 0x416cf6
mov bl, byte [esi]
inc esi
cmp bl, 0xd
je 0x416cf6
cmp bl, 0xa
je 0x416cf6
cmp bl, 0x20
je 0x416cf2
mov byte [eax], bl
inc eax
cmp esi, edi
jb 0x416cd2
mov byte [eax], 0
test ecx, ecx
je 0x416d16
lea eax, [esp + 0x148]
push str.chunked
push eax
call fcn.00445fc4
add esp, 8
test eax, eax
je 0x416d37
cmp esi, edi
jb 0x416c40
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x5c0]
xor ecx, esp
call fcn.004423fe
mov esp, ebp
pop ebp
ret
mov edi, dword [esp + 0x18]
push edi
call fcn.00449be3
mov ebx, dword [esp + 0x18]
mov esi, eax
mov eax, dword [esp + 0x10]
add esp, 4
add eax, 4
mov dword [esp + 0x20], esi
mov dword [esp + 0xc], eax
push eax
push ebx
push esi
call fcn.00444290
mov ecx, dword [esp + 0x18]
add esp, 0xc
lea esi, [ecx + ebx]
add ebx, edi
nop dword [eax]
xor edx, edx
lea edi, [esp + 0x148]
cmp esi, ebx
jae 0x416db6
nop dword [eax]
lea eax, [esp + 0x1c8]
cmp edi, eax
jae 0x416db6
mov cl, byte [esi]
inc esi
cmp cl, 0xa
je 0x416db6
cmp cl, 0x30
jl 0x416d9d
cmp cl, 0x39
jle 0x416dae
cmp cl, 0x41
jl 0x416da7
cmp cl, 0x46
jle 0x416dae
lea eax, [ecx - 0x61]
cmp al, 5
ja 0x416db2
mov byte [edi], cl
inc edi
inc edx
cmp esi, ebx
jb 0x416d80
lea ecx, [esp + 0x148]
mov byte [edi], 0
call fcn.0040f9c0
mov edi, eax
test edi, edi
je 0x416de4
mov ecx, dword [esp + 0x20]
mov eax, dword [esp + 0xc]
push edi
add eax, ecx
push esi
push eax
call fcn.00444290
add esp, 0xc
add esi, edi
jmp 0x416d70
mov ecx, dword [esp + 0x30]
mov eax, dword [esp + 0x20]
push dword [esp + 0x14]
mov dword [ecx], eax
jmp 0x416bd5
cmp edi, 0xc
jle 0x416bdd
push 0xb
push str.HTTP_1.1_30
push ebx
call fcn.00445e80
add esp, 0xc
test eax, eax
jne 0x416bdd
push 4
push str._r_n_r_n
mov edx, esi
mov ecx, ebx
call fcn.0041ca80
push 9
push 0x4f8c80
mov edx, esi
mov dword [esp + 0x34], eax
mov ecx, ebx
call fcn.0041ca80
mov ecx, eax
add esp, 0x10
test ecx, ecx
jle 0x416bdd
mov eax, dword [esp + 0x24]
test eax, eax
jle 0x416bdd
cmp ecx, edi
jge 0x416bdd
cmp eax, edi
jge 0x416bdd
cmp ecx, eax
jge 0x416bdd
lea edi, [ecx + 9]
sub eax, edi
lea esi, [edi + ebx]
push 2
push 0x4f8c8c
mov edx, eax
mov ecx, esi
call fcn.0041ca80
add esp, 8
test eax, eax
jle 0x416bdd
add edi, eax
lea edx, [esp + 0x3c8]
mov al, byte [esi]
add edi, ebx
cmp al, 0x20
jne 0x416eb5
cmp esi, edi
jae 0x416eaf
mov al, byte [esi + 1]
inc esi
cmp al, 0x20
je 0x416ea1
jmp 0x416eb5
mov al, byte [esi]
cmp al, 0x20
je 0x416ed7
mov ecx, esi
sub ecx, edi
nop dword [eax]
cmp esi, edi
jae 0x416ed7
cmp ecx, 0x1ff
jge 0x416ed7
inc esi
mov byte [edx], al
inc edx
inc ecx
mov al, byte [esi]
cmp al, 0x20
jne 0x416ec0
push dword [esp + 0xc]
lea ecx, [esp + 0x3cc]
mov byte [edx], 0
push dword [ebp + 0x10]
push dword [esp + 0x38]
push dword [esp + 0x40]
call fcn.00416700
mov ecx, dword [esp + 0x5dc]
add esp, 0x10
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004423fe
mov esp, ebp
pop ebp
ret