Function at 0x41f303
Capabilities:
Connect to http server
Create http request
Get http content length

Disassembly:
mov eax, 0x45cd10
call fcn.004485c4
sub esp, 0x8c4
push ebx
push esi
push edi
mov dword [ebp - 0x10], esp
push str.fs::OpenInetRequestWithStatusCheck_1423
mov esi, ecx
call fcn.004468a0
pop ecx
mov dword [ebp - 0x3c], eax
mov edi, dword [ebp + 8]
xor ebx, ebx
mov dword [ebp - 4], ebx
cmp dword [edi + 0x18], 0x10
mov eax, dword [edi + 0x30]
jb 0x41f33f
mov ecx, dword [edi + 4]
jmp 0x41f342
lea ecx, [edi + 4]
push eax
push ecx
push str.fs::OpenInetRequestWithStatusCheck_1423
push str.___s__url_s_len_post__d_
push ebx
call fcn.00437bbc
add esp, 0x14
push edi
lea eax, [ebp - 0xa4]
push eax
mov byte [ebp - 4], 1
call fcn.00401295
lea eax, [ebp - 0x30]
push eax
mov byte [ebp - 4], 2
call fcn.0041c5de
cmp dword [eax + 0x18], 0x10
pop ecx
jb 0x41f381
mov eax, dword [eax + 4]
jmp 0x41f384
add eax, 4
push ebx
push ebx
push ebx
push ebx
push eax
call dword [sym.imp.WININET.dll_InternetOpenA]
push ebx
push 1
lea ecx, [ebp - 0x30]
mov dword [esi], eax
call fcn.00417a85
mov eax, dword [esi]
cmp eax, ebx
jne 0x41f3d8
push 0x465cf2
lea ecx, [ebp - 0x30]
call fcn.00418739
lea eax, [ebp - 0x30]
push eax
push 1
lea ecx, [ebp - 0x58]
mov byte [ebp - 4], 3
call fcn.0041875b
mov esi, eax
mov byte [ebp - 4], 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Cant_open_internet:_err_d
jmp 0x41f6af
cmp dword [ebp - 0x8c], 0x10
mov ecx, dword [ebp - 0xa0]
jae 0x41f3ed
lea ecx, [ebp - 0xa0]
push ebx
push ebx
push 3
push ebx
push ebx
push dword [ebp - 0x6c]
push ecx
push eax
call dword [sym.imp.WININET.dll_InternetConnectA]
cmp eax, ebx
mov dword [esi + 4], eax
jne 0x41f43b
push 0x465cf2
lea ecx, [ebp - 0x30]
call fcn.00418739
lea eax, [ebp - 0x30]
push eax
push 1
lea ecx, [ebp - 0x58]
mov byte [ebp - 4], 5
call fcn.0041875b
mov esi, eax
mov byte [ebp - 4], 6
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Cant_connect_internet:_err_d
jmp 0x41f6af
cmp dword [edi + 0x30], ebx
mov edx, 0x466e30
je 0x41f44a
mov edx, str.POST
cmp dword [ebp - 0x70], 0x10
mov ecx, dword [ebp - 0x84]
jae 0x41f45c
lea ecx, [ebp - 0x84]
push ebx
push 0x84000900
push ebx
push ebx
push ebx
push ecx
push edx
push eax
call dword [sym.imp.WININET.dll_HttpOpenRequestA]
cmp eax, ebx
mov dword [esi + 8], eax
jne 0x41f4ab
push 0x465cf2
lea ecx, [ebp - 0x30]
call fcn.00418739
lea eax, [ebp - 0x30]
push eax
push 1
lea ecx, [ebp - 0x58]
mov byte [ebp - 4], 7
call fcn.0041875b
mov esi, eax
mov byte [ebp - 4], 8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Cant_open_request:_err_d
jmp 0x41f6af
push str.Connection:_Close_r_n
lea ecx, [ebp - 0x30]
call fcn.00418739
mov byte [ebp - 4], 9
cmp dword [edi + 0x30], ebx
je 0x41f4ce
push str.Content_Type:_application_x_www_form_urlencoded_r_n
lea ecx, [ebp - 0x30]
call fcn.00411ae1
lea eax, [ebp - 0xa4]
push ebx
push eax
call fcn.00425ec0
test al, al
pop ecx
pop ecx
je 0x41f510
push str._COOKIE_
lea ecx, [ebp - 0x64]
call fcn.00418739
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x64]
push eax
mov byte [ebp - 4], 0xa
call fcn.00425ef8
pop ecx
pop ecx
push ebx
push 1
lea ecx, [ebp - 0x64]
mov byte [ebp - 4], 9
call fcn.00417a85
cmp dword [esi + 0xc], ebx
jbe 0x41f5f1
cmp byte [edi + 0x80], bl
je 0x41f5f1
mov eax, dword [edi + 0x98]
cmp eax, ebx
ja 0x41f53f
cmp dword [edi + 0xb4], ebx
jbe 0x41f5f1
cmp eax, ebx
jbe 0x41f547
lea eax, [edi + 0x84]
jmp 0x41f54d
lea eax, [edi + 0xa0]
push eax
lea ecx, [ebp - 0x64]
call fcn.004188b1
mov byte [ebp - 4], 0xb
cmp dword [ebp - 0x4c], 0x10
mov eax, dword [ebp - 0x60]
jae 0x41f566
lea eax, [ebp - 0x60]
push eax
push dword [esi + 0xc]
push str.__request_range__lu__by__s
push ebx
call fcn.00437bbc
xor eax, eax
mov byte [ebp - 0x8d0], bl
mov ecx, 0xff
lea edi, [ebp - 0x8cf]
rep stosd dword es:[edi], eax
add esp, 0x10
push dword [esi + 0xc]
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 0x8d0]
push str.Range:_bytes_lu__r_n
push eax
call fcn.004475f5
add esp, 0xc
lea eax, [ebp - 0x8d0]
push eax
lea ecx, [ebp - 0x30]
call fcn.00411ae1
push str.If_Range:
lea ecx, [ebp - 0x30]
call fcn.00411ae1
push 0xffffffffffffffff
push ebx
lea eax, [ebp - 0x64]
push eax
lea ecx, [ebp - 0x30]
call fcn.0041754b
push 0x46ae58
lea ecx, [ebp - 0x30]
call fcn.00411ae1
push ebx
push 1
lea ecx, [ebp - 0x64]
mov byte [ebp - 4], 9
call fcn.00417a85
mov edi, dword [ebp + 8]
cmp dword [ebp - 0x18], 0x10
mov ecx, dword [ebp - 0x2c]
jae 0x41f5fd
lea ecx, [ebp - 0x2c]
mov eax, dword [esi + 8]
push 0x20000000
push dword [ebp - 0x1c]
push ecx
push eax
call dword [sym.imp.WININET.dll_HttpAddRequestHeadersA]
test eax, eax
jne 0x41f64d
push 0x465cf2
lea ecx, [ebp - 0xc0]
call fcn.00418739
lea eax, [ebp - 0xc0]
push eax
push 1
lea ecx, [ebp - 0x58]
mov byte [ebp - 4], 0xc
call fcn.0041875b
mov esi, eax
mov byte [ebp - 4], 0xd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Cant_add_request_headers:_err_d
jmp 0x41f6af
push ebx
push 1
lea ecx, [ebp - 0x30]
mov byte [ebp - 4], 2
call fcn.00417a85
mov eax, dword [esi + 8]
lea ecx, [ebp - 0x40]
push ecx
lea ecx, [edi + 0x1c]
push ecx
push eax
push edi
mov dword [ebp - 0x40], ebx
call fcn.0041f036
add esp, 0x10
cmp al, bl
jne 0x41f6bf
push 0x465cf2
lea ecx, [ebp - 0xc0]
call fcn.00418739
lea eax, [ebp - 0xc0]
push eax
push 1
lea ecx, [ebp - 0x58]
mov byte [ebp - 4], 0xe
call fcn.0041875b
mov esi, eax
mov byte [ebp - 4], 0xf
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Cant_send_request:_err_d
push esi
call fcn.004180c3
add esp, 0xc
mov ecx, eax
jmp fcn.00418793
mov eax, dword [esi + 8]
push ebx
lea ecx, [ebp - 0x14]
push ecx
lea edi, [esi + 0x10]
push edi
push 0x20000005
push eax
mov dword [edi], ebx
mov dword [ebp - 0x14], 4
call dword [sym.imp.WININET.dll_HttpQueryInfoA]
push dword [edi]
push str.__part_length:__d_bytes
push ebx
call fcn.00437bbc
xor eax, eax
mov byte [ebp - 0x4d0], bl
mov ecx, 0xff
lea edi, [ebp - 0x4cf]
rep stosd dword es:[edi], eax
add esp, 0xc
stosw word es:[edi], ax
push ebx
lea ecx, [ebp - 0x14]
push ecx
stosb byte es:[edi], al
mov eax, dword [ebp + 8]
mov edi, dword [sym.imp.WININET.dll_HttpQueryInfoA]
lea ecx, [ebp - 0x4d0]
push ecx
mov byte [eax + 0x80], 1
mov eax, dword [esi + 8]
push 0x36
push eax
mov dword [ebp - 0x14], 0x400
call edi
test eax, eax
je 0x41f74c
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x4d0]
push eax
add ecx, 0x84
call fcn.00418180
mov eax, dword [ebp + 8]
cmp dword [eax + 0x98], ebx
jne 0x41f78b
mov eax, dword [esi + 8]
push ebx
lea ecx, [ebp - 0x14]
push ecx
lea ecx, [ebp - 0x4d0]
push ecx
push 0xb
push eax
mov dword [ebp - 0x14], 0x400
call edi
test eax, eax
je 0x41f78b
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x4d0]
push eax
add ecx, 0xa0
call fcn.00418180
lea eax, [ebp - 0x4d0]
push str.X_OpenInstall_PackageType
push eax
mov dword [ebp - 0x14], 0x400
call fcn.00447770
mov eax, dword [esi + 8]
pop ecx
pop ecx
push ebx
lea ecx, [ebp - 0x14]
push ecx
lea ecx, [ebp - 0x4d0]
push ecx
push 0xffff
push eax
call edi
test eax, eax
je 0x41f7d5
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x4d0]
push eax
add ecx, 0xbc
call fcn.00418180
cmp dword [esi + 0xc], ebx
jbe 0x41f856
mov eax, dword [esi + 8]
push ebx
lea ecx, [ebp - 0x44]
push ecx
lea ecx, [ebp - 0x4d0]
push ecx
push 0x35
push eax
mov dword [esi + 0xc], ebx
mov dword [ebp - 0x44], 0x400
call edi
test eax, eax
je 0x41f845
lea eax, [ebp - 0x4d0]
push eax
push str.___s
push ebx
call fcn.00437bbc
add esp, 0xc
lea eax, [ebp - 0x38]
push eax
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x4d0]
push str.bytes__lu__lu__lu
push eax
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x38], ebx
call fcn.004475c1
add esp, 0x14
cmp eax, 3
jne 0x41f845
mov eax, dword [ebp - 0x34]
mov dword [esi + 0xc], eax
push dword [esi + 0xc]
push str.__part_start:__d_byte
push ebx
call fcn.00437bbc
add esp, 0xc
mov ecx, dword [esi + 0xc]
mov eax, dword [esi + 0x10]
add eax, ecx
mov ecx, dword [ebp + 8]
push eax
push str.__content_length:__d_bytes
push ebx
mov dword [ecx + 0x7c], eax
call fcn.00437bbc
add esp, 0xc
lea esi, [ebp - 0xa4]
call fcn.0040b6ed
or dword [ebp - 4], 0xffffffff
lea esi, [ebp - 0x3c]
call fcn.0041836d
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret