Function at 0x409390
Capabilities:
Delete file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x43b8c0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, 0x1254
call fcn.0043aa70
mov eax, dword [ebp + 0x18]
push ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 0x10], esp
mov ecx, dword [ebp + 0x1c]
xor esi, esi
push 0x450728
mov dword [ebp - 0x30], edi
mov dword [eax], esi
call sub.MFC42.DLL_CString::operator_1
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x20], esi
call sub.MFC42.DLL_CString::CString_3
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], esi
call sub.MFC42.DLL_CString::CString_3
mov ecx, dword [ebp + 8]
mov eax, dword [edi + 0xe8]
mov byte [ebp - 4], 1
mov edx, dword [ecx + 0x10]
mov ecx, dword [eax + 0x18]
push edx
push ecx
lea edx, [ebp - 0x14]
push 0x44b410
push edx
call sub.MFC42.DLL_CString::Format
add esp, 0x10
lea eax, [ebp - 0x14]
lea ecx, [ebp - 0x28]
push eax
push ecx
mov ecx, edi
call fcn.0040bc20
push eax
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 2
call sub.MFC42.DLL_CString::operator
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CString::CString
mov edx, dword [ebp - 0x14]
mov eax, dword [0x450ba4]
push edx
push str.CSyncEngine::DownloadOneFileFromServer__Download_File_URL___s
push 1
push eax
mov byte [ebp - 4], 3
call fcn.00404960
mov ecx, dword [edi + 0xe8]
mov dword [ebp - 0x60], str.image_gif
mov dword [ebp - 0x5c], str.image_x_xbitmap
mov dword [ebp - 0x58], str.image_jpeg
mov dword [ebp - 0x54], str.image_pjpeg
mov dword [ebp - 0x50], str.application_x_shockwave_flash
mov dword [ebp - 0x4c], str.application_vnd.ms_excel
mov dword [ebp - 0x48], str.application_vnd.ms_powerpoint
mov dword [ebp - 0x44], str.application_msword
mov dword [ebp - 0x40], 0x44c338
mov dword [ebp - 0x3c], esi
mov eax, dword [ecx + 0x24]
add esp, 0x10
cmp eax, esi
mov ebx, 0xa0400000
jle 0x4094f4
mov edx, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer____set_cert_flag_1
push 2
push edx
call fcn.00404960
mov ecx, dword [ebp + 0x14]
mov eax, 1
add esp, 0xc
cmp ecx, eax
mov ebx, 0xa0c00000
je 0x4094d9
mov ecx, dword [edi + 0xe8]
cmp dword [ecx + 0x24], eax
jne 0x4094f4
mov edx, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer____set_cert_ignore_flag_2
push 2
push edx
mov ebx, 0xa0c03000
call fcn.00404960
add esp, 0xc
mov ecx, dword [ebp - 0x18]
push ebx
lea eax, [ebp - 0x60]
push str.HTTP_1.1
push eax
push 1
push esi
push ecx
mov ecx, dword [edi + 0xe4]
push 0x44c2a8
call sub.MFC42.DLL_CHttpConnection::OpenRequest
mov ebx, eax
cmp ebx, esi
mov dword [ebp - 0x20], ebx
jne 0x409563
mov edx, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer__OpenRequest___Return_NULL
push 4
push edx
call fcn.00404960
add esp, 0xc
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
or edi, 0xffffffff
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], edi
call sub.MFC42.DLL_CString::CString
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
mov eax, dword [edi + 0xe8]
mov eax, dword [eax + 0x24]
cmp eax, esi
jle 0x4095b0
cmp dword [ebp + 0x14], 1
je 0x40957b
cmp eax, 1
jne 0x4095b0
mov ecx, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer__Try_to_SetOption_____set_cert_ignore_flag_3
push 2
push ecx
mov dword [ebp + 0x14], esi
call fcn.00404960
mov ecx, dword [ebp + 0x14]
add esp, 0xc
or ecx, 0x3380
lea edx, [ebp + 0x14]
push esi
push 4
mov dword [ebp + 0x14], ecx
push edx
push 0x1f
mov ecx, ebx
call sub.MFC42.DLL_CInternetFile::SetOption
push esi
push esi
push esi
push esi
mov ecx, ebx
call sub.MFC42.DLL_CHttpFile::SendRequest
lea eax, [ebp - 0x28]
mov ecx, ebx
push eax
call sub.MFC42.DLL_CHttpFile::QueryInfoStatusCode
cmp eax, esi
je 0x409b5c
cmp dword [ebp - 0x28], 0xc8
jne 0x409b5c
mov edx, dword [ebp + 8]
lea ecx, [ebp - 0x34]
push ecx
push ecx
lea esi, [edx + 0x14]
mov ecx, esp
mov dword [ebp + 0x14], esp
push esi
mov dword [ebp - 0x34], 0
call sub.MFC42.DLL_CString::CString_2
call fcn.00401430
add esp, 8
cmp eax, 1
je 0x409697
cmp eax, 0xfffffffe
jne 0x409629
mov eax, dword [esi]
mov ecx, dword [0x450ba4]
push eax
push str.CSyncEngine::DownloadOneFileFromServer___s____Directory_path_unknown.
push 4
push ecx
call fcn.00404960
add esp, 0x10
jmp 0x409664
cmp eax, 0xfffffffd
jne 0x409648
mov edx, dword [esi]
mov eax, dword [0x450ba4]
push edx
push str.CSyncEngine::DownloadOneFileFromServer___s____Invalid_directory_path.
push 4
push eax
call fcn.00404960
add esp, 0x10
jmp 0x409664
mov ecx, dword [ebp - 0x34]
mov edx, dword [esi]
mov eax, dword [0x450ba4]
push ecx
push edx
push str.CSyncEngine::DownloadOneFileFromServer___s____Directory_creation_or_exists__failed.__GetLastError___is__d_
push 4
push eax
call fcn.00404960
add esp, 0x14
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, 0xfffffff8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
mov ecx, dword [ebp + 8]
push ecx
mov ecx, edi
call fcn.00409ed0
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [esi]
push 0x44c10c
push eax
call dword [sym.imp.MSVCRT.dll_fopen]
xor edi, edi
add esp, 8
cmp eax, edi
mov dword [ebp - 0x24], eax
jne 0x40972e
mov edx, dword [esi]
mov eax, dword [0x450ba4]
push edx
push str.CSyncEngine::DownloadOneFileFromServer__Local_File_Open__s__Fail
push 4
push eax
call fcn.00404960
mov ecx, dword [0x450ba4]
add esp, 0x10
call fcn.00404e20
mov edx, dword [ebx]
mov ecx, ebx
call dword [edx + 0x54]
mov eax, dword [ebx]
push 1
mov ecx, ebx
call dword [eax + 4]
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x20], edi
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, 0xfffffffd
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
mov eax, dword [ebp + 8]
mov dword [ebp - 0x1c], edi
cmp dword [eax + 8], edi
je 0x409758
mov ecx, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer__Write_transfer_encoded_chunked_file._So_the_total_size_of_the_file_is_unknown.
push 1
push ecx
mov dword [ebp - 0x2c], 0xa000
call fcn.00404960
add esp, 0xc
jmp 0x409768
mov eax, dword [eax + 0x2c]
push eax
call dword [sym.imp.MSVCRT.dll_atoi]
add esp, 4
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x38], 1
mov dword [ebp + 0x14], edi
mov edx, dword [ebp + 8]
mov eax, dword [edx + 8]
test eax, eax
jne 0x40978a
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp + 0x14]
cmp ecx, eax
jge 0x409838
mov ecx, 0x3ff
xor eax, eax
lea edi, [ebp - 0x1263]
mov byte [ebp - 0x1264], 0
rep stosd dword es:[edi], eax
mov edx, dword [ebx]
push 0x1000
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 0x1264]
mov ecx, ebx
push eax
call dword [edx + 0x3c]
mov esi, eax
xor edi, edi
cmp esi, edi
jg 0x409a28
cmp dword [ebp - 0x38], edi
je 0x409838
mov ecx, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer__pHttpFile__Read_pBuf__sizeof_pBuf_____No_data.
push 4
push ecx
call fcn.00404960
mov edx, dword [ebp - 0x24]
add esp, 0xc
push edx
call dword [sym.imp.MSVCRT.dll_fclose]
mov eax, dword [ebx]
add esp, 4
mov ecx, ebx
call dword [eax + 0x54]
test ebx, ebx
je 0x4097fe
mov edx, dword [ebx]
push 1
mov ecx, ebx
call dword [edx + 4]
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x20], 0
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, 0xfffffff6
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.MSVCRT.dll_fclose]
mov ecx, dword [ebp + 8]
or edi, 0xffffffff
add esp, 4
cmp dword [ecx + 0xc], edi
jne 0x4098b9
lea ecx, [ebp - 0x1c]
call sub.MFC42.DLL_CString::CString_3
lea edx, [ebp - 0x1c]
push 0
push edx
push 0x1d
mov ecx, ebx
mov byte [ebp - 4], 4
call sub.MFC42.DLL_CHttpFile::QueryInfo
mov eax, dword [ebp - 0x1c]
push str.gzip
push eax
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
jne 0x4098a3
mov ecx, dword [ebp + 8]
push str.CSyncEngine::DownloadOneFileFromServer__Content_encoding_GZIP.
push 1
mov dword [ecx + 0xc], 1
mov edx, dword [0x450ba4]
push edx
call fcn.00404960
add esp, 0xc
jmp 0x4098ad
mov eax, dword [ebp + 8]
mov dword [eax + 0xc], 0
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 3
call sub.MFC42.DLL_CString::CString
mov edx, dword [ebx]
mov ecx, ebx
call dword [edx + 0x54]
test ebx, ebx
je 0x4098cd
mov eax, dword [ebx]
push 1
mov ecx, ebx
call dword [eax + 4]
mov eax, dword [ebp + 8]
mov dword [ebp - 0x20], 0
cmp dword [eax + 0xc], 1
jne 0x409952
lea ecx, [ebp - 0x1c]
lea esi, [eax + 0x14]
push ecx
mov ecx, dword [ebp - 0x30]
push esi
call fcn.0040e170
test eax, eax
jne 0x40991d
mov edx, dword [esi]
mov eax, dword [0x450ba4]
push edx
push str.CSyncEngine::DownloadOneFileFromServer__UnCompressGzipFile__s__Failed.
push 4
push eax
call fcn.00404960
add esp, 0x10
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
mov dword [ebp - 4], edi
jmp 0x409c4f
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp + 0x14]
mov eax, dword [esi]
push ecx
mov ecx, dword [0x450ba4]
push edx
push eax
push str.CSyncEngine::DownloadOneFileFromServer__UnCompressGzipFile__s__Success._nCurrentServerReadSize_d_dwUnCompressSize_d
push 1
push ecx
call fcn.00404960
mov ecx, dword [ebp - 0x1c]
add esp, 0x18
test ecx, ecx
jbe 0x40994a
mov eax, dword [ebp + 8]
jmp 0x409955
mov ecx, dword [ebp + 0x14]
mov eax, dword [ebp + 8]
jmp 0x409955
mov ecx, dword [ebp + 0x14]
mov edx, dword [eax + 8]
test edx, edx
jne 0x4099aa
mov edx, dword [ebp - 0x2c]
cmp ecx, edx
je 0x4099aa
push ecx
push edx
mov edx, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer__Server_File_Size___d__Write_File_Size___d
push 4
push edx
call fcn.00404960
add esp, 0x14
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], edi
call sub.MFC42.DLL_CString::CString
mov eax, 0xfffffffc
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
mov ecx, dword [ebp - 0x30]
push eax
call fcn.00409eb0
test eax, eax
jge 0x4099fc
push eax
mov eax, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer__SetDownFileModifyDate___Fail__RetVal___d
push 4
push eax
call fcn.00404960
add esp, 0x10
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], edi
call sub.MFC42.DLL_CString::CString
mov eax, 0xfffffffb
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], edi
call sub.MFC42.DLL_CString::CString
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 0x18
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp - 0x1c]
add ecx, esi
add edx, esi
mov dword [ebp + 0x14], ecx
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x1c], edx
push ecx
push esi
lea edx, [ebp - 0x1264]
push 1
push edx
mov dword [ebp - 0x38], edi
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
cmp eax, esi
je 0x409ac7
push eax
mov eax, dword [0x450ba4]
push str.CSyncEngine::DownloadOneFileFromServer__fwrite___Fail__RetVal___d
push 1
push eax
call fcn.00404960
mov ecx, dword [ebp - 0x24]
add esp, 0x10
push ecx
call dword [sym.imp.MSVCRT.dll_fclose]
mov edx, dword [ebx]
add esp, 4
mov ecx, ebx
call dword [edx + 0x54]
test ebx, ebx
je 0x409a8d
mov eax, dword [ebx]
push 1
mov ecx, ebx
call dword [eax + 4]
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x20], 0
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, 0xfffffff7
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
mov ecx, dword [ebp + 8]
cmp dword [ecx + 8], edi
je 0x409adc
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x2c]
cmp edx, eax
jl 0x409adc
mov dword [ebp - 0x1c], edi
mov eax, dword [ebp - 0x30]
mov eax, dword [eax + 0x18]
cmp eax, edi
je 0x409772
mov ecx, dword [0x450ba4]
push eax
push str.CSyncEngine::DownloadOneFileFromServer__m_nRequestStopFlag___d
push 1
push ecx
call fcn.00404960
mov edx, dword [ebp - 0x24]
add esp, 0x10
push edx
call dword [sym.imp.MSVCRT.dll_fclose]
mov eax, dword [ebx]
add esp, 4
mov ecx, ebx
call dword [eax + 0x54]
test ebx, ebx
je 0x409b22
mov edx, dword [ebx]
push 1
mov ecx, ebx
call dword [edx + 4]
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x20], 0
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, 0xfffffff9
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x14]
mov edx, dword [0x450ba4]
push eax
push ecx
push str.CSyncEngine::DownloadOneFileFromServer__QueryInfoStatusCode__s__Return___d
push 4
push edx
call fcn.00404960
mov eax, dword [ebx]
add esp, 0x14
mov ecx, ebx
call dword [eax + 0x54]
mov edx, dword [ebx]
push 1
mov ecx, ebx
call dword [edx + 4]
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x20], esi
mov byte [ebp - 4], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, 0xfffffffe
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::CString
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov eax, 0xfffffffa
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret 0x18