Function at 0x41d8e0
Capabilities:
Check http status code
Create http request
Download and write a file
Read data from internet
Receive and write data from server to client
Receive data
Write file on windows

Disassembly:
mov eax, 0x103c
call fcn.00435740
mov eax, dword [0x46414c]
xor eax, esp
mov dword [esp + 0x1038], eax
mov eax, dword [esp + 0x104c]
push ebx
xor ebx, ebx
push esi
mov esi, dword [esp + 0x1048]
mov dword [esp + 0x18], edx
mov dword [esp + 0x14], ecx
mov dword [esp + 0x20], eax
mov dword [esp + 0xc], ebx
cmp eax, ebx
je 0x41d92b
cmp eax, 0xffffffff
je 0x41d92b
mov dword [esp + 0xc], 1
cmp dword [esp + 0x1050], ebx
je 0x41d97e
cmp dword [esp + 0xc], ebx
jne 0x41d93e
cmp edx, ebx
je 0x41d942
cmp ecx, ebx
jne 0x41d97e
mov eax, dword [esp + 0x1058]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41d965
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
pop esi
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x1038]
xor ecx, esp
call fcn.0042404d
add esp, 0x103c
ret
mov eax, dword [esp + 0x1058]
push edi
push ebx
push ebx
push ebx
push ebx
cmp dword [eax - 0xc], ebx
je 0x41d99e
push eax
call dword [sym.imp.WININET.dll_InternetOpenW]
mov edi, eax
mov dword [esp + 0x14], edi
jmp 0x41d9af
push str.CHM_MSDN
call dword [sym.imp.WININET.dll_InternetOpenW]
mov dword [esp + 0x14], eax
mov edi, eax
cmp edi, ebx
jne 0x41d9f0
mov eax, dword [esp + 0x105c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41d9d6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x1038]
xor ecx, esp
call fcn.0042404d
add esp, 0x103c
ret
mov eax, closesocket
cmp dword [esp + 0x1050], ebx
je 0x41da03
mov eax, 0x80200000
push ebp
push ebx
push eax
push ebx
push ebx
push esi
push edi
call dword [sym.imp.WININET.dll_InternetOpenUrlW]
mov ebp, eax
cmp ebp, ebx
jne 0x41da32
mov eax, dword [esp + 0x1060]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x41dc45
xor eax, eax
push ebx
lea edx, [esp + 0x30]
push edx
mov dword [esp + 0x3a], eax
mov dword [esp + 0x3e], eax
mov dword [esp + 0x42], eax
mov dword [esp + 0x46], eax
mov word [esp + 0x4a], ax
lea eax, [esp + 0x38]
push eax
push 0x13
xor ecx, ecx
push ebp
mov word [esp + 0x44], cx
mov dword [esp + 0x40], 0x14
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
test eax, eax
je 0x41dc22
lea ecx, [esp + 0x30]
push ecx
call fcn.004245c8
add esp, 4
cmp eax, 0xc8
je 0x41daa5
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
push ebp
call esi
push edi
call esi
lea ecx, [esp + 0x1060]
call fcn.00401460
jmp 0x41dc51
mov edi, 1
cmp dword [esp + 0x1058], ebx
je 0x41dbf2
push 0x1000
lea edx, [esp + 0x49]
push ebx
push edx
mov dword [esp + 0x1c], ebx
xor edi, edi
xor esi, esi
mov byte [esp + 0x50], bl
call fcn.00426020
add esp, 0xc
lea eax, [esp + 0x10]
push eax
push 0x1000
lea ecx, [esp + 0x4c]
push ecx
push ebp
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
je 0x41dbc1
mov eax, dword [esp + 0x10]
cmp eax, ebx
jbe 0x41dbb0
cmp dword [esp + 0x14], ebx
jne 0x41db60
cmp esi, ebx
jne 0x41db27
push 0x1001
call fcn.004267b3
push 0x1001
mov esi, eax
push ebx
push esi
call fcn.00426020
add esp, 0x10
jmp 0x41db48
lea edx, [edi + 0x1001]
push edx
push esi
call fcn.00426549
mov esi, eax
push 0x1001
lea eax, [esi + edi]
push ebx
push eax
call fcn.00426020
add esp, 0x14
mov ecx, dword [esp + 0x10]
push ecx
lea edx, [esp + 0x48]
push edx
lea eax, [esi + edi]
push eax
call fcn.00428630
add esp, 0xc
jmp 0x41db7b
push ebx
lea ecx, [esp + 0x28]
push ecx
push eax
mov eax, dword [esp + 0x34]
lea edx, [esp + 0x50]
push edx
push eax
mov dword [esp + 0x38], ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
add edi, dword [esp + 0x10]
push 0x1001
lea ecx, [esp + 0x48]
push ebx
push ecx
call fcn.00426020
add esp, 0xc
lea edx, [esp + 0x10]
push edx
push 0x1000
lea eax, [esp + 0x4c]
push eax
push ebp
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
jne 0x41daf4
cmp edi, ebx
ja 0x41dbd9
cmp esi, ebx
je 0x41dbc1
push esi
call fcn.00424dcf
add esp, 4
mov eax, dword [esp + 0x20]
cmp eax, ebx
je 0x41dbcb
mov dword [eax], ebx
mov eax, dword [esp + 0x1c]
cmp eax, ebx
je 0x41dbd5
mov dword [eax], ebx
xor edi, edi
jmp 0x41dbf2
mov eax, dword [esp + 0x20]
cmp eax, ebx
je 0x41dbe3
mov dword [eax], esi
mov eax, dword [esp + 0x1c]
cmp eax, ebx
je 0x41dbed
mov dword [eax], edi
mov edi, 1
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
push ebp
call esi
mov ecx, dword [esp + 0x18]
push ecx
call esi
lea ecx, [esp + 0x1060]
call fcn.00401460
cmp dword [esp + 0x1058], ebx
je 0x41dc1b
mov eax, edi
jmp 0x41dc53
mov eax, 1
jmp 0x41dc53
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
push ebp
call esi
push edi
call esi
mov eax, dword [esp + 0x1060]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x41dc51
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
mov ecx, dword [esp + 0x1048]
pop ebp
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0042404d
add esp, 0x103c
ret