Function at 0x4dd5f0
Capabilities:
Check for time delay via gettickcount
Connect to http server
Create http request
Download and write a file
Get http content length
Read data from internet
Receive and write data from server to client
Receive data
Send data
Send http request
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x538487
mov eax, dword fs:[0]
push eax
sub esp, 0x6c
push ebx
push esi
push edi
mov eax, dword [0x59a0a0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, edx
mov edx, ecx
mov dword [ebp - 0x1c], edx
mov dword [ebp - 4], 0
xor ebx, ebx
mov dword [ebp - 0x58], ebx
mov dword [ebp - 0x54], ebx
mov byte [ebp - 4], 3
mov edi, dword [ebp + 0x1c]
mov dword [ebp - 0x24], ebx
test edi, edi
je 0x4dd660
mov eax, dword [edi]
push ebx
push ebx
mov eax, dword [eax]
cmp eax, method.ATL::CComObjectStackEx_class_GameDownload::CMainUISpecial_.1.virtual_0
jne 0x4dd655
mov eax, dword [edi - 0xc]
lea ecx, [edi - 0xc]
push edx
call dword [eax + 0xc]
jmp 0x4dd660
push 4
push 0
push 0
push edx
mov ecx, edi
call eax
push 0
push 0x80
push 2
push 0
push 1
push 0x40000000
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
jne 0x4dd6b4
call fcn.004054a0
test eax, eax
jns 0x4dd6b7
test esi, esi
je 0x4dd693
mov dword [esi], 0x18
push eax
push dword [ebp + 0x10]
push 0x55c934
push str.__s__Create_File__s__Fail_Err_0x_08x_
call fcn.004e78a0
push eax
call fcn.004e76a0
add esp, 0x14
jmp 0x4ddaf8
mov dword [ebp - 0x58], eax
push 0
push 0
push 0
push dword [ebp + 0x18]
push 0
call dword [sym.imp.WININET.dll_InternetOpenW]
mov dword [ebp - 0x44], eax
test eax, eax
jne 0x4dd6fd
call dword [sym.imp.KERNEL32.dll_GetLastError]
test esi, esi
je 0x4dd6df
mov dword [esi], 0x19
push eax
push 0x55c9fc
push 0x55ca7c
call fcn.004e78a0
push eax
call fcn.004e76a0
add esp, 0x10
jmp 0x4ddaea
push 0
push 0
push 3
push 0
push 0
push 0x50
push dword [ebp + 8]
push eax
call dword [sym.imp.WININET.dll_InternetConnectW]
mov dword [ebp - 0x48], eax
test eax, eax
jne 0x4dd74e
call dword [sym.imp.KERNEL32.dll_GetLastError]
test esi, esi
je 0x4dd72a
mov dword [esi], 0x1a
push eax
push 0x55cabc
push 0x55caf0
call fcn.004e78a0
push eax
call fcn.004e76a0
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
add esp, 0x10
jmp 0x4ddadb
push 0
push 0x84000200
push 0
push 0
push 0
push dword [ebp + 0xc]
push 0
push eax
call dword [sym.imp.WININET.dll_HttpOpenRequestW]
mov dword [ebp - 0x14], eax
test eax, eax
jne 0x4dd7a2
call dword [sym.imp.KERNEL32.dll_GetLastError]
test esi, esi
je 0x4dd77e
mov dword [esi], 0x1b
push eax
push 0x55cb34
push 0x55cb68
call fcn.004e78a0
push eax
call fcn.004e76a0
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
add esp, 0x10
jmp 0x4ddadb
push 0x55cbe0
lea ecx, [ebp - 0x10]
call fcn.00401ff0
mov byte [ebp - 4], 4
mov eax, dword [ebp - 0x10]
push 0x10000000
push dword [eax - 0xc]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.WININET.dll_HttpAddRequestHeadersW]
test eax, eax
jne 0x4dd7f9
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0
push 0x55cbac
push 0x55ccb0
call fcn.004e78a0
push eax
call fcn.004e76a0
add esp, 0x10
lea ecx, [ebp - 0x10]
call fcn.00402ed0
jmp 0x4ddad0
push 0
push 0
push 0
push 0
push dword [ebp - 0x14]
call dword [sym.imp.WININET.dll_HttpSendRequestW]
test eax, eax
jne 0x4dd82b
call dword [sym.imp.KERNEL32.dll_GetLastError]
test esi, esi
je 0x4dd81e
mov dword [esi], 0x1c
push eax
push str.QueryHttpNetworkData2File
push 0x55cd00
jmp 0x4dd7de
mov esi, dword [ebp - 0x14]
lea eax, [ebp - 0x38]
push eax
lea eax, [ebp - 0x3c]
mov dword [ebp - 0x3c], 8
push eax
lea eax, [ebp - 0x60]
mov dword [ebp - 0x38], 0
push eax
push 0x20000005
xorps xmm0, xmm0
push esi
movlpd qword [ebp - 0x60], xmm0
call dword [sym.imp.WININET.dll_HttpQueryInfoW]
test eax, eax
je 0x4dd880
mov dword [ebp - 0x24], 1
test edi, edi
je 0x4dd880
push dword [ebp - 0x60]
mov eax, dword [edi]
mov ecx, edi
push dword [ebp - 0x1c]
call dword [eax + 4]
test eax, eax
jne 0x4dd7ec
mov dword [ebp - 0x74], 0
mov dword [ebp - 0x70], 0
mov dword [ebp - 0x6c], 0
push 0x10000
lea ecx, [ebp - 0x74]
mov byte [ebp - 4], 5
call fcn.00405210
xorps xmm0, xmm0
mov dword [ebp + 0x1c], 0
movlpd qword [ebp - 0x50], xmm0
movlpd qword [ebp - 0x30], xmm0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ebx, dword [ebp - 0x74]
push 0x10000
push 0
push ebx
mov dword [ebp - 0x40], eax
mov dword [ebp + 0x1c], 0
call fcn.0049e130
add esp, 0xc
lea eax, [ebp + 0x1c]
push eax
push 0x10000
push ebx
push esi
call dword [sym.imp.WININET.dll_InternetReadFile]
mov eax, dword [ebp + 0x1c]
mov esi, dword [ebp - 0x50]
test eax, eax
je 0x4dda0d
mov edx, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x4c]
mov dword [ebp - 0x20], edx
add esi, eax
mov dword [ebp - 0x18], esi
adc ecx, 0
cmp dword [ebp - 0x24], 0
mov dword [ebp - 0x34], ecx
je 0x4dd9b7
test edi, edi
je 0x4dd9b7
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov esi, eax
sub esi, dword [ebp - 0x40]
je 0x4dd955
push 0
push 0x3e8
push dword [ebp - 0x34]
push dword [ebp - 0x18]
call fcn.0049ba40
push 0
push esi
push edx
push eax
call fcn.0049bc30
mov ecx, eax
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x20], ecx
jmp 0x4dd958
mov ecx, dword [ebp - 0x20]
mov eax, dword [edi]
mov esi, dword [ebp - 0x18]
mov eax, dword [eax]
cmp eax, method.ATL::CComObjectStackEx_class_GameDownload::CMainUISpecial_.1.virtual_0
jne 0x4dd9a4
mov ecx, dword [ebp - 0x60]
xorps xmm0, xmm0
movlpd qword [ebp - 0x68], xmm0
test ecx, ecx
je 0x4dd98a
mov eax, esi
mov edx, 0x3e8
mul edx
push 0
push ecx
push edx
push eax
call fcn.0049bc30
jmp 0x4dd98d
mov eax, dword [ebp - 0x68]
mov edx, dword [ebp - 0x20]
lea ecx, [edi - 0xc]
mov dword [ebp - 0x2c], eax
mov eax, dword [ecx]
push edx
push dword [ebp - 0x2c]
push dword [ebp - 0x1c]
call dword [eax + 0xc]
jmp 0x4dd9b4
push 0
push ecx
push 5
push dword [ebp - 0x60]
mov ecx, edi
push esi
push dword [ebp - 0x1c]
call eax
mov eax, dword [ebp + 0x1c]
push 0
lea ecx, [ebp - 0x4c]
push ecx
push eax
push ebx
push dword [ebp - 0x58]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4dd9d5
call fcn.004054a0
test eax, eax
js 0x4dda0d
push 0x10000
push 0
push ebx
mov dword [ebp + 0x1c], 0
call fcn.0049e130
add esp, 0xc
lea eax, [ebp + 0x1c]
push eax
push 0x10000
push ebx
push dword [ebp - 0x14]
call dword [sym.imp.WININET.dll_InternetReadFile]
mov eax, dword [ebp + 0x1c]
mov ecx, dword [ebp - 0x34]
test eax, eax
jne 0x4dd905
mov eax, dword [ebp - 0x58]
test eax, eax
je 0x4dda20
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov dword [ebp - 0x58], eax
test edi, edi
je 0x4dda37
mov eax, dword [edi]
mov ecx, edi
push 0
push 0
push 6
push dword [ebp - 0x60]
push esi
push dword [ebp - 0x1c]
call dword [eax]
mov dword [ebp - 0x40], 1
mov byte [ebp - 4], 4
test ebx, ebx
je 0x4dda93
mov eax, dword [ebp - 0x6c]
sub eax, ebx
cmp eax, 0xffffffff
jbe 0x4dda55
call fcn.004a4e3e
cmp eax, 0x1000
jb 0x4dda8a
test bl, 0x1f
je 0x4dda66
call fcn.004a4e3e
mov eax, dword [ebx - 4]
cmp eax, ebx
jb 0x4dda72
call fcn.004a4e3e
sub ebx, eax
cmp ebx, 4
jae 0x4dda7e
call fcn.004a4e3e
cmp ebx, 0x23
jbe 0x4dda88
call fcn.004a4e3e
mov ebx, eax
push ebx
call fcn.0049aa1d
add esp, 4
mov byte [ebp - 4], 3
or eax, 0xffffffff
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x4ddacd
mov edx, dword [ecx]
push ecx
mov eax, dword [edx]
mov esi, dword [eax + 4]
cmp eax, vtable.ATL::CAtlStringMgr.0
jne 0x4ddac9
mov eax, dword [edx + 4]
push 0
push dword [eax + 4]
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x4ddacd
mov ecx, edx
call esi
mov ebx, dword [ebp - 0x40]
push dword [ebp - 0x14]
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
call esi
push dword [ebp - 0x44]
call esi
mov eax, dword [ebp - 0x48]
test eax, eax
je 0x4ddaea
push eax
call esi
mov eax, dword [ebp - 0x58]
test eax, eax
je 0x4ddaf8
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [ebp - 4], 1
or edi, 0xffffffff
mov ecx, dword [ebp + 8]
mov eax, edi
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x4ddb34
mov edx, dword [ecx]
push ecx
mov eax, dword [edx]
mov esi, dword [eax + 4]
cmp eax, vtable.ATL::CAtlStringMgr.0
jne 0x4ddb30
mov eax, dword [edx + 4]
push 0
push dword [eax + 4]
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x4ddb34
mov ecx, edx
call esi
mov byte [ebp - 4], 0
mov eax, edi
mov ecx, dword [ebp + 0xc]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x4ddb6d
mov edx, dword [ecx]
push ecx
mov eax, dword [edx]
mov esi, dword [eax + 4]
cmp eax, vtable.ATL::CAtlStringMgr.0
jne 0x4ddb69
mov eax, dword [edx + 4]
push 0
push dword [eax + 4]
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x4ddb6d
mov ecx, edx
call esi
mov dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp + 0x10]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], edi
dec edi
test edi, edi
jg 0x4ddbb9
mov edx, dword [ecx]
push ecx
mov eax, dword [edx]
mov esi, dword [eax + 4]
cmp eax, vtable.ATL::CAtlStringMgr.0
jne 0x4ddbb5
mov eax, dword [edx + 4]
push 0
push dword [eax + 4]
call dword [sym.imp.KERNEL32.dll_HeapFree]
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
mov ecx, edx
call esi
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