Function at 0x410790
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x437408
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, 0x1934
call fcn.00435550
push ebx
push esi
push edi
xor esi, esi
mov dword [ebp - 0x10], esp
push esi
push esi
push esi
mov ebx, ecx
push esi
push 1
push esi
lea ecx, [ebp - 0x40]
call sub.MFC42.DLL_CInternetSession::CInternetSession
xor edi, edi
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], esi
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x24], esi
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CString::CString
push edi
lea eax, [ebp - 0x20]
push 4
push eax
push 2
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 2
mov dword [ebp - 0x20], 0x7d0
call sub.MFC42.DLL_CInternetSession::SetOption
push edi
lea ecx, [ebp - 0x20]
push 4
push ecx
push 3
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x20], 1
call sub.MFC42.DLL_CInternetSession::SetOption
mov eax, dword [ebx + 0xb4]
mov byte [ebp - 0x20], 0
test eax, eax
mov byte [ebp - 4], 3
jne 0x410882
mov edx, dword [ebp + 8]
lea ecx, [ebp - 0x28]
push ecx
lea ecx, [ebp - 0x14]
mov eax, dword [edx]
lea edx, [ebp - 0x18]
push edx
lea edx, [ebp - 0x48]
push ecx
push edx
push eax
call sub.MFC42.DLL_AfxParseURL
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x14]
push edi
push edi
push eax
push ecx
lea ecx, [ebp - 0x40]
call sub.MFC42.DLL_CInternetSession::GetHttpConnection_1
mov edx, dword [ebp - 0x18]
push 0x20000000
push edi
push edi
push 1
push edi
mov ecx, eax
push edx
push 1
mov dword [ebp - 0x1c], ecx
call sub.MFC42.DLL_CHttpConnection::OpenRequest
mov esi, eax
mov dword [ebp - 0x24], esi
jmp 0x4109f8
cmp eax, 1
je 0x410890
cmp eax, 2
jne 0x4109fb
mov ecx, 0x100
xor eax, eax
lea edi, [ebp - 0x45c]
lea edx, [ebp - 0x45c]
rep stosd dword es:[edi], eax
or ecx, 0xffffffff
lea edi, [ebx + 0xe8]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov dword [ebp - 0x58], 3
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [ebp - 0x45c]
and ecx, 3
mov dword [ebp - 0x50], 0
rep movsb byte es:[edi], byte [esi]
mov edi, 0x44b6d8
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [ebp - 0x45c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [ebx + 0x100]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [ebp - 0x45c]
and ecx, 3
mov dword [ebp - 0x54], eax
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp + 8]
lea edx, [ebp - 0x28]
push edx
lea edx, [ebp - 0x14]
mov eax, dword [ecx]
lea ecx, [ebp - 0x18]
push ecx
lea ecx, [ebp - 0x48]
push edx
push ecx
push eax
call sub.MFC42.DLL_AfxParseURL
push 0
lea edx, [ebp - 0x58]
push 0xc
push edx
push 0x26
lea ecx, [ebp - 0x40]
call sub.MFC42.DLL_CInternetSession::SetOption
test eax, eax
je 0x410a62
mov eax, dword [ebp - 0x14]
push 0
push 0
push 0x50
push 0x200000
push eax
lea ecx, [ebp - 0x40]
call sub.MFC42.DLL_CInternetSession::GetHttpConnection
mov edx, dword [ebp - 0x18]
push 0x20000000
push 0
push 0
push 1
push 0
mov ecx, eax
push edx
push 1
mov dword [ebp - 0x1c], ecx
call sub.MFC42.DLL_CHttpConnection::OpenRequest
lea edx, [ebx + 0xb8]
mov esi, eax
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
push 0
repne scasb al, byte es:[edi]
not ecx
push ecx
push edx
push 0x2b
mov ecx, esi
mov dword [ebp - 0x24], esi
call sub.MFC42.DLL_CInternetFile::SetOption
test eax, eax
je 0x410a62
lea edx, [ebx + 0xd0]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
push 0
push ecx
push edx
push 0x2c
mov ecx, esi
call sub.MFC42.DLL_CInternetFile::SetOption
test eax, eax
je 0x410a62
mov edi, dword [ebp - 0x1c]
push 0
push 0
push 0
push 0
mov ecx, esi
call sub.MFC42.DLL_CHttpFile::SendRequest_1
test eax, eax
je 0x410a62
lea eax, [ebp - 0x44]
mov ecx, esi
push eax
call sub.MFC42.DLL_CHttpFile::QueryInfoStatusCode
cmp dword [ebp - 0x44], 0xc8
jne 0x410b8d
mov ecx, dword [ebp + 0xc]
push 0
push 0x80
push 2
mov eax, dword [ecx]
push 0
push 2
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp - 0x2c], eax
jne 0x410a9e
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 0x54]
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 0x14]
lea ecx, [ebp - 0x40]
call sub.MFC42.DLL_CInternetSession::Close
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.00434eae
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0
call fcn.00434eae
lea ecx, [ebp - 0x40]
mov dword [ebp - 4], 0xffffffff
call fcn.004352c2
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
lea ecx, [ebp - 0x4c]
push 0
lea edx, [ebp - 0x944]
push ecx
push edx
push 5
mov ecx, esi
mov dword [ebp - 0x4c], 0x3e8
call sub.MFC42.DLL_CHttpFile::QueryInfo
lea eax, [ebp - 0x944]
push eax
call dword [sym.imp.MSVCRT.dll_atoi]
mov ecx, 0x400
xor eax, eax
lea edi, [ebp - 0x1944]
add esp, 4
rep stosd dword es:[edi], eax
mov edx, dword [esi]
lea eax, [ebp - 0x1944]
xor edi, edi
push 0x1000
push eax
mov ecx, esi
mov dword [ebp + 8], edi
call dword [edx + 0x3c]
mov byte [ebp + eax - 0x1944], 0
mov dword [ebp + 0xc], eax
test eax, eax
jbe 0x410b4c
lea ecx, [ebp + 8]
push 0
push ecx
push eax
mov eax, dword [ebp - 0x2c]
lea edx, [ebp - 0x1944]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [ebp + 8]
mov edx, dword [esi]
lea eax, [ebp - 0x1944]
add edi, ecx
push 0x1000
push eax
mov ecx, esi
call dword [edx + 0x3c]
mov edx, dword [ebp + 0xc]
mov ecx, dword [ebx + 0x194]
add edx, eax
cmp ecx, 2
mov dword [ebp + 0xc], edx
mov byte [ebp + eax - 0x1944], 0
jne 0x410afd
mov ecx, dword [ebp - 0x2c]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [ebp - 0x20], 1
jmp 0x410b8a
mov edi, dword [ebp - 0x1c]
test esi, esi
mov dword [ebp - 4], 2
je 0x410ba8
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 0x54]
mov eax, dword [esi]
push 1
mov ecx, esi
call dword [eax + 4]
test edi, edi
je 0x410bbc
mov edx, dword [edi]
mov ecx, edi
call dword [edx + 0x14]
mov eax, dword [edi]
push 1
mov ecx, edi
call dword [eax + 4]
lea ecx, [ebp - 0x40]
call sub.MFC42.DLL_CInternetSession::Close
mov esi, dword [ebp - 0x20]
lea ecx, [ebp - 0x18]
and esi, 0xff
mov byte [ebp - 4], 1
call fcn.00434eae
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0
call fcn.00434eae
lea ecx, [ebp - 0x40]
mov dword [ebp - 4], 0xffffffff
call fcn.004352c2
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 8