Function at 0x404970
Capabilities:
Check http status code
Connect to http server
Create http request
Send data
Send http request

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x428300
mov eax, dword fs:[0]
push eax
sub esp, 0x54
push ebx
push esi
push edi
mov eax, dword [0x430080]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor edi, edi
push 0x42c54c
mov dword [ebp - 4], edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov esi, dword [ebp + 0xc]
push 0x42c54c
mov ebx, eax
call fcn.00401440
mov eax, dword [0x4312c8]
mov dword [ebp - 0x60], vtable.CUrlParser.0
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x54], eax
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x30], edi
mov dword [ebp - 0x24], eax
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x60]
push ecx
mov byte [ebp - 4], 1
call fcn.00405140
movzx ebx, al
cmp ebx, edi
je 0x404c44
cmp dword [ebp - 0x2c], 3
jne 0x404c44
lea ecx, [ebp - 0x54]
lea eax, [ebp - 0x14]
call fcn.00401000
lea edx, [ebp - 0x48]
push edx
lea eax, [ebp - 0x10]
push eax
lea edx, [ebp - 0x44]
mov byte [ebp - 4], 2
call fcn.00404c90
push edi
push edi
push edi
push edi
mov byte [ebp - 4], 3
push str.HttpDownload
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x1c], 4
call dword [sym.imp.WININET.dll_InternetOpenW]
mov esi, eax
cmp esi, edi
je 0x404bb3
mov ebx, dword [sym.imp.WININET.dll_InternetSetOptionW]
push 4
lea ecx, [ebp + 0x10]
push ecx
push 2
push esi
call ebx
test eax, eax
jne 0x404aa3
push esi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
lea esi, [ebp - 0x10]
call fcn.00401370
lea esi, [ebp - 0x14]
call fcn.00401370
lea ecx, [ebp - 0x60]
call fcn.00404fc0
lea esi, [ebp + 8]
call fcn.00401370
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 4
lea edx, [ebp + 0x10]
push edx
push 5
push esi
call ebx
test eax, eax
je 0x404a68
push 4
lea eax, [ebp + 0x10]
push eax
push 5
push esi
call ebx
test eax, eax
je 0x404a68
push 4
lea ecx, [ebp + 0x10]
push ecx
push 6
push esi
mov dword [ebp + 0x10], edi
call ebx
test eax, eax
je 0x404a68
push 4
lea edx, [ebp + 0x10]
push edx
push 6
push esi
call ebx
mov ebx, eax
cmp ebx, edi
je 0x404a68
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x14]
push edi
push edi
push 3
push edi
push edi
push eax
push ecx
push esi
call dword [sym.imp.WININET.dll_InternetConnectW]
mov dword [ebp - 0x20], eax
cmp eax, edi
je 0x404bac
push edi
cmp dword [ebp + 0x14], edi
je 0x404b14
mov edx, dword [ebp - 0x10]
push edi
push edi
push edi
push edi
push edx
jmp 0x404b20
mov ecx, dword [ebp - 0x10]
push 0x44000000
push edi
push edi
push edi
push ecx
push 0x42c544
push eax
call dword [sym.imp.WININET.dll_HttpOpenRequestW]
mov edi, eax
test edi, edi
jne 0x404b3a
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x404ba2
push 0
push 0
push 0
push 0
push edi
call dword [sym.imp.WININET.dll_HttpSendRequestW]
mov ebx, eax
test ebx, ebx
jne 0x404b57
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x404b9b
push 0
lea edx, [ebp - 0x1c]
push edx
lea eax, [ebp - 0x18]
push eax
push 0x20000013
push edi
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
mov ebx, eax
test ebx, ebx
je 0x404b9b
mov eax, dword [ebp - 0x18]
cmp eax, 0xc8
je 0x404b84
cmp eax, 0x130
jne 0x404b9b
mov eax, dword [ebp + 0xc]
push edi
call fcn.004048c0
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x404b9b
mov ebx, 1
push edi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov ecx, dword [ebp - 0x20]
push ecx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
push esi
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov eax, dword [ebp - 0x10]
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
lea edx, [eax - 0xc]
cmp edx, 0x4312b8
je 0x404be0
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x404be0
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff4
push eax
call fcn.0040eabb
add esp, 4
mov eax, dword [ebp - 0x14]
lea ecx, [eax - 0xc]
cmp ecx, 0x4312b8
je 0x404c01
lea esi, [eax - 0xc]
push esi
call edi
test eax, eax
jg 0x404c01
push esi
call fcn.0040eabb
add esp, 4
lea ecx, [ebp - 0x60]
call fcn.00404fc0
mov eax, dword [ebp + 8]
lea edx, [eax - 0xc]
cmp edx, 0x4312b8
je 0x404c30
add eax, 0xfffffff4
push eax
call edi
test eax, eax
jg 0x404c30
mov eax, dword [ebp + 8]
add eax, 0xfffffff4
push eax
call fcn.0040eabb
add esp, 4
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea ecx, [ebp - 0x60]
call fcn.00404fc0
mov eax, dword [ebp + 8]
lea ecx, [eax - 0xc]
cmp ecx, 0x4312b8
je 0x404c77
add eax, 0xfffffff4
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x404c77
mov edx, dword [ebp + 8]
add edx, 0xfffffff4
push edx
call fcn.0040eabb
add esp, 4
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret