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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push edi
push 0
push 0
push 0
push 0
push 0x5283c8
mov dword [ebp - 0x1c], 0
call dword [sym.imp.WININET.dll_InternetOpenW]
mov edi, eax
mov dword [ebp - 4], edi
test edi, edi
jne 0x48fbff
pop edi
mov esp, ebp
pop ebp
ret
push ebx
push esi
push 0
push 0x4000800
push 0
push 0
push dword [ebp + 8]
push edi
call dword [sym.imp.WININET.dll_InternetOpenUrlW]
mov ebx, eax
test ebx, ebx
jne 0x48fc3b
call dword [sym.imp.KERNEL32.DLL_GetLastError]
push edi
mov esi, eax
call dword [sym.imp.WININET.dll_InternetCloseHandle]
push esi
call dword [sym.imp.KERNEL32.DLL_SetLastError]
pop esi
pop ebx
xor eax, eax
pop edi
mov esp, ebp
pop ebp
ret
mov esi, dword [sym.imp.WININET.dll_HttpQueryInfoW]
lea eax, [ebp - 8]
push 0
push eax
lea eax, [ebp - 0x20]
mov dword [ebp - 8], 4
push eax
push 0x20000013
push ebx
call esi
test eax, eax
je 0x48fdd5
cmp dword [ebp - 0x20], 0xc8
je 0x48fc88
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
push ebx
call esi
push edi
call esi
push 2
call dword [sym.imp.KERNEL32.DLL_SetLastError]
pop esi
pop ebx
xor eax, eax
pop edi
mov esp, ebp
pop ebp
ret
push 0
lea eax, [ebp - 8]
mov dword [ebp - 8], 4
push eax
lea eax, [ebp - 0xc]
push eax
push 0x20000005
push ebx
call esi
test eax, eax
je 0x48fdd5
mov eax, dword [ebp - 0xc]
test eax, eax
je 0x48fdd5
push 0
push 0x80
push 2
push 0
push 3
push 0xc0000000
push dword [ebp + 0xc]
mov dword [0x579b90], eax
mov dword [0x579b94], 0
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
mov esi, eax
mov dword [ebp - 0x18], esi
cmp esi, 0xffffffff
je 0x48fdd5
push 0x1000
call fcn.004f1588
mov ecx, eax
add esp, 4
mov dword [ebp - 0x10], ecx
test ecx, ecx
jne 0x48fd20
call dword [sym.imp.KERNEL32.DLL_GetLastError]
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.KERNEL32.DLL_DeleteFileW]
jmp 0x48fddd
mov eax, dword [ebp - 0xc]
xor esi, esi
mov edx, 0x1000
jmp 0x48fd33
mov ecx, dword [ebp - 0x10]
sub eax, esi
cmp eax, 0x1000
cmova eax, edx
lea edx, [ebp - 0x14]
push edx
push eax
push ecx
push ebx
call dword [sym.imp.WININET.dll_InternetReadFile]
mov dword [ebp - 4], eax
test eax, eax
je 0x48fd89
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x48fd92
push 0
lea ecx, [ebp - 0x24]
push ecx
push eax
push dword [ebp - 0x10]
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.DLL_WriteFile]
mov dword [ebp - 4], eax
test eax, eax
je 0x48fd89
add esi, dword [ebp - 0x14]
mov edx, 0x1000
mov eax, dword [ebp - 0xc]
mov dword [0x579b94], esi
cmp esi, eax
jb 0x48fd30
jmp 0x48fd92
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov dword [ebp - 0x1c], eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
push ebx
call esi
push edi
call esi
push dword [ebp - 0x10]
call fcn.004ec0b7
mov esi, dword [ebp - 4]
add esp, 4
test esi, esi
jne 0x48fdcc
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.KERNEL32.DLL_DeleteFileW]
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.DLL_SetLastError]
mov eax, esi
pop esi
pop ebx
pop edi
mov esp, ebp
pop ebp
ret
call dword [sym.imp.KERNEL32.DLL_GetLastError]
mov edi, eax
mov esi, dword [sym.imp.WININET.dll_InternetCloseHandle]
push ebx
call esi
push dword [ebp - 4]
call esi
push edi
call dword [sym.imp.KERNEL32.DLL_SetLastError]
pop esi
pop ebx
xor eax, eax
pop edi
mov esp, ebp
pop ebp
ret