Function at 0x470bf0
Capabilities:
Copy file
Delete file
Get file size
Read http header
Receive http response
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4c9819
mov eax, dword fs:[0]
push eax
sub esp, 0x1d0
mov eax, dword [0x5142b0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 0x10]
mov edx, dword [ebp + 0x18]
mov ebx, dword [ebp + 0x28]
mov esi, dword [ebp + 0x2c]
mov dword [ebp - 0x190], eax
mov eax, dword [ebp + 0x1c]
mov dword [ebp - 0x150], ecx
mov ecx, dword [ebp + 0x20]
mov dword [ebp - 0x188], edx
mov edx, dword [ebp + 0x24]
mov dword [ebp - 0x178], eax
mov eax, dword [ebp + 0x30]
mov dword [ebp - 0x180], ecx
mov ecx, dword [ebp + 0x3c]
mov dword [ebp - 0x184], edx
mov edx, dword [0x513fec]
mov dword [ebp - 0x170], eax
mov eax, dword [edx + 0xc]
mov dword [ebp - 0x158], ecx
xor edi, edi
mov ecx, 0x513fec
mov dword [ebp - 0x174], ebx
mov dword [ebp - 0x16c], esi
mov byte [ebp - 0x139], 0
mov dword [ebp - 0x1c4], edi
call eax
add eax, 0x10
mov dword [ebp - 0x18c], eax
mov dword [ebp - 4], edi
cmp ebx, edi
jne 0x470cab
xor eax, eax
jmp 0x470cbf
mov eax, ebx
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x470cb0
sub eax, edx
sar eax, 1
push eax
push ebx
lea ecx, [ebp - 0x18c]
call fcn.00402380
mov edx, dword [0x513fec]
mov eax, dword [edx + 0xc]
mov ecx, 0x513fec
mov dword [ebp - 0x154], edi
call eax
add eax, 0x10
mov dword [ebp - 0x198], eax
push esi
lea ecx, [ebp - 0x138]
mov byte [ebp - 4], 1
call fcn.00401e50
push 0x4dc0b8
push 0x4dc0b4
lea ecx, [ebp - 0x138]
mov byte [ebp - 4], 2
call fcn.00465ae0
push 0x4dc0b8
push 0x4dc0ac
lea ecx, [ebp - 0x138]
call fcn.00465ae0
mov esi, dword [ebp - 0x18c]
cmp dword [esi - 0xc], edi
jl 0x470d77
push str..xml
push esi
call fcn.0049200f
add esp, 8
cmp eax, edi
je 0x470d53
sub eax, esi
sar eax, 1
cmp eax, 0xffffffff
jne 0x470f43
cmp dword [esi - 0xc], edi
jl 0x470d77
push str..json
push esi
call fcn.0049200f
add esp, 8
cmp eax, edi
je 0x470d77
sub eax, esi
sar eax, 1
cmp eax, 0xffffffff
jne 0x470f43
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp - 0x150]
push ecx
push edx
push str.InternetGetDownloader_:_DesktopCentral_Server__Port_____S_:__d__n
call fcn.00423db0
mov eax, dword [0x513fec]
mov edx, dword [eax + 0xc]
add esp, 0xc
mov ecx, 0x513fec
mov dword [ebp - 0x168], edi
call edx
add eax, 0x10
mov dword [ebp - 0x144], eax
mov edx, dword [str.SoftwareAdventNetDesktopCentralDCAgent]
mov byte [ebp - 4], 3
cmp edx, edi
jne 0x470dbf
xor eax, eax
jmp 0x470dcd
mov eax, edx
lea esi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x470dc4
sub eax, esi
push eax
push edx
lea ecx, [ebp - 0x144]
call fcn.00401700
push 9
push str.Settings
lea ecx, [ebp - 0x144]
call fcn.00411c00
mov esi, dword [ebp - 0x144]
cmp dword [esi - 4], 1
jle 0x470e0d
mov eax, dword [esi - 0xc]
push eax
lea ecx, [ebp - 0x144]
call fcn.004014b0
mov esi, dword [ebp - 0x144]
lea ecx, [ebp - 0x168]
push ecx
push str.DownloadMode
push esi
push reloc.OLEAUT32.dll_SysReAllocString
call fcn.00478d80
add esp, 0x10
test eax, eax
mov eax, dword [ebp - 0x168]
jne 0x470f15
cmp eax, 1
jne 0x470f15
cmp dword [ebp + 0x34], 0x2afb
jne 0x470f15
lea ecx, [ebp - 0xb0]
call fcn.00468c00
mov eax, dword [ebp - 0x138]
cmp dword [eax - 4], 1
mov byte [ebp - 4], 4
jle 0x470e7b
mov edx, dword [eax - 0xc]
push edx
lea ecx, [ebp - 0x138]
call fcn.00402490
mov eax, dword [ebp - 0x138]
mov ecx, dword [ebp - 0x158]
mov edx, dword [ebp + 0x38]
push ecx
mov ecx, dword [ebp - 0x170]
push edx
mov edx, dword [ebp - 0x184]
push 0x2afb
push ecx
mov ecx, dword [ebp - 0x178]
push eax
mov eax, dword [ebp - 0x180]
push ebx
push edx
mov edx, dword [ebp - 0x188]
push eax
mov eax, dword [ebp + 0x14]
push ecx
mov ecx, dword [ebp - 0x150]
push edx
mov edx, dword [ebp - 0x190]
push eax
mov eax, dword [ebp + 8]
push ecx
push edx
push eax
lea ecx, [ebp - 0xb0]
call fcn.0046ee50
lea ecx, [ebp - 0xb0]
mov esi, eax
mov byte [ebp - 4], 3
call fcn.00468d60
lea ecx, [ebp - 0x144]
call fcn.00401ed0
lea ecx, [ebp - 0x138]
call fcn.00401ed0
lea ecx, [ebp - 0x198]
call fcn.00401ed0
lea ecx, [ebp - 0x18c]
call fcn.00401ed0
mov eax, esi
jmp 0x471edd
push eax
push str.InternetGetDownloader_:_Download_Mode__lu_n
call fcn.00423db0
lea eax, [esi - 0x10]
add esp, 8
mov byte [ebp - 4], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x470f43
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push str._________Inside_InternetGetRequestEx_Method___________n
mov dword [ebp - 0x148], edi
mov dword [ebp - 0x1c0], edi
mov dword [ebp - 0x164], edi
mov dword [ebp - 0x160], edi
mov dword [ebp - 0x194], edi
mov dword [ebp - 0x144], edi
mov dword [ebp - 0x1b8], edi
call fcn.00423960
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp - 0x150]
push ecx
push edx
push str.InternetGetRequestEx_:_DesktopCentral_Server__Port_____S_:__d__n
call fcn.00423db0
add esp, 0x10
push ebx
lea ecx, [ebp - 0x14c]
call fcn.00401e50
mov eax, dword [ebp - 0x14c]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x15c], esp
mov esi, esp
push eax
mov byte [ebp - 4], 5
call fcn.00404fb0
add eax, 0x10
mov dword [esi], eax
lea eax, [ebp - 0x15c]
add esp, 4
push eax
call fcn.00466100
add esp, 8
push eax
lea ecx, [ebp - 0x14c]
mov byte [ebp - 4], 6
call fcn.00404900
mov eax, dword [ebp - 0x15c]
add eax, 0xfffffff0
or esi, 0xffffffff
mov byte [ebp - 4], 5
lea ecx, [eax + 0xc]
mov edx, esi
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471006
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x14c]
cmp dword [eax - 4], 1
jle 0x471027
mov ecx, dword [eax - 0xc]
push ecx
lea ecx, [ebp - 0x14c]
call fcn.00402490
mov eax, dword [ebp - 0x14c]
push eax
push str.InternetGetRequestEx_:_URL_to_Get_____S__n
call fcn.00423960
mov eax, dword [ebp - 0x138]
add esp, 8
cmp dword [eax - 4], 1
mov dword [ebp - 0x1b0], esi
mov dword [ebp - 0x1ac], esi
mov dword [ebp - 0x1a8], esi
mov dword [ebp - 0x19c], edi
mov dword [ebp - 0x1a4], edi
mov dword [ebp - 0x1a0], edi
mov dword [ebp - 0x17c], edi
jle 0x471080
mov edx, dword [eax - 0xc]
push edx
lea ecx, [ebp - 0x138]
call fcn.00402490
mov eax, dword [ebp - 0x138]
mov ecx, dword [ebp + 0x40]
mov edx, dword [ebp - 0x158]
push ecx
push edx
mov edx, dword [ebp + 0x38]
lea ecx, [ebp - 0x1b0]
push ecx
mov ecx, dword [ebp + 0x34]
push edx
mov edx, dword [ebp - 0x170]
push ecx
mov ecx, dword [ebp - 0x180]
push edx
mov edx, dword [ebp - 0x178]
push eax
mov eax, dword [ebp - 0x184]
push ebx
push eax
mov eax, dword [ebp - 0x188]
push ecx
mov ecx, dword [ebp + 0x14]
push edx
mov edx, dword [ebp - 0x150]
push eax
mov eax, dword [ebp - 0x190]
push ecx
mov ecx, dword [ebp + 8]
push edx
push eax
push ecx
call fcn.00469e40
mov edx, dword [ebp - 0x1b0]
mov esi, dword [ebp - 0x1a8]
mov edi, eax
mov eax, dword [ebp - 0x1ac]
add esp, 0x40
cmp byte [ebp + 0x40], 0
mov dword [ebp - 0x15c], edx
mov dword [ebp - 0x1c8], eax
mov dword [ebp - 0x1b4], esi
je 0x471212
push 0
lea ecx, [ebp - 0x168]
push ecx
push 0
push str.Content_Encoding
push 0xffff
push esi
mov dword [ebp - 0x168], 4
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
mov edx, dword [ebp - 0x168]
lea eax, [edx*4 + 8]
push eax
push 1
call fcn.00491e51
add esp, 8
push 0
lea ecx, [ebp - 0x168]
push ecx
push eax
push str.Content_Encoding
push 0xffff
push esi
mov dword [ebp - 0x140], eax
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
test eax, eax
jne 0x4711b1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x1bc], eax
cmp eax, 0x2f76
jne 0x47118f
push str.InternetGetRequestEx_:_Response_Header_doesnt_contain_content_Encoding.__n
call fcn.00423ad0
jmp 0x4711f7
mov edx, dword [ebp - 0x1bc]
push edx
push str.InternetGetRequestEx_:__Error_in_WinHttpQueryHeaders______lu__n
call fcn.00423ad0
mov eax, dword [ebp - 0x1bc]
push eax
call fcn.00464180
add esp, 0xc
jmp 0x4711fa
mov ecx, dword [ebp - 0x140]
push ecx
push str.InternetGetRequestEx_:__Response_Header_Informations_:__S__n
call fcn.00423960
mov edx, dword [ebp - 0x140]
push str.gzip
push edx
call fcn.00495a60
add esp, 0x10
test eax, eax
jne 0x4711ed
push str.InternetGetRequestEx_:_Response_Header_contains_content_Encoding_as_gzip__n
call fcn.00423db0
mov byte [ebp - 0x139], 1
jmp 0x4711f7
push str.InternetGetRequestEx_:_Response_Header_doesnt_contain_content_Encoding_as_gzip__n
call fcn.00423db0
add esp, 4
cmp dword [ebp - 0x140], 0
je 0x471212
mov eax, dword [ebp - 0x140]
push eax
call fcn.0048efd8
add esp, 4
test edi, edi
jne 0x47182c
mov edi, dword [ebp - 0x19c]
cmp edi, 0xc8
jne 0x471a87
mov ecx, dword [ebp - 0x158]
cmp dword [ecx + 0x14], 0
je 0x4712a1
lea edx, [ebp - 0x17c]
push edx
push esi
call fcn.00464de0
mov edi, dword [ebp - 0x17c]
lea eax, [ebp - 0x154]
push edi
push eax
call fcn.00463bf0
add esp, 0x10
mov ecx, dword [ebp - 0x158]
add ecx, 0x28
push eax
mov byte [ebp - 4], 7
call fcn.0040fa30
mov eax, dword [ebp - 0x154]
add eax, 0xfffffff0
mov byte [ebp - 4], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471294
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test edi, edi
je 0x4712a1
push edi
call fcn.0048efd8
add esp, 4
push 0
lea ecx, [ebp - 0x1cc]
push ecx
lea edx, [ebp - 0x164]
push edx
push 0
push 0x20000005
push esi
mov dword [ebp - 0x1cc], 4
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
mov edi, eax
mov dword [ebp - 0x154], edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp edi, 1
je 0x471322
cmp eax, 0x7a
je 0x471322
cmp eax, 0x2f76
je 0x471322
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push edi
push str.InternetGetRequestEx_:__Error_in_Content_Length_Header_____lu__n
call fcn.00423ad0
mov eax, dword [ebp - 0x154]
push eax
call fcn.00464180
add esp, 0xc
cmp edi, 0x216
jne 0x47182c
mov dword [ebp - 0x1c4], 1
jmp 0x471338
mov ecx, dword [ebp - 0x164]
push ecx
push str.InternetGetRequestEx_:_Content_Length_of_the_request_file:__lu_Bytes_n
call fcn.00423db0
add esp, 8
xor edi, edi
mov eax, dword [ebp + 0x34]
cmp eax, 0x2afb
jne 0x471443
mov eax, dword [ebp - 0x138]
cmp dword [eax - 4], 1
jle 0x471367
mov edx, dword [eax - 0xc]
push edx
lea ecx, [ebp - 0x138]
call fcn.00402490
mov eax, dword [ebp - 0x138]
push 1
push eax
call fcn.0045c500
add esp, 8
test eax, eax
je 0x4713a5
mov eax, dword [ebp - 0x138]
cmp dword [eax - 4], 1
jle 0x471397
mov eax, dword [eax - 0xc]
push eax
lea ecx, [ebp - 0x138]
call fcn.00402490
mov eax, dword [ebp - 0x138]
push eax
push str.InternetGetRequestEx_:_Failed_to_create_the_destination_directory_for_the_destination_file__S__n
call fcn.00423ad0
add esp, 8
mov eax, dword [ebp - 0x138]
cmp dword [eax - 4], 1
jle 0x4713c6
mov ecx, dword [eax - 0xc]
push ecx
lea ecx, [ebp - 0x138]
call fcn.00402490
mov eax, dword [ebp - 0x138]
lea edx, [eax + 2]
lea esp, [esp]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4713d0
sub eax, edx
sar eax, 1
lea edx, [eax*4 + 0x1e]
push edx
push 1
call fcn.00491e51
add esp, 8
mov dword [ebp - 0x148], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [ebp - 0x154], eax
mov eax, dword [ebp - 0x138]
cmp dword [eax - 4], 1
jle 0x471424
mov eax, dword [eax - 0xc]
push eax
lea ecx, [ebp - 0x138]
call fcn.00402490
mov eax, dword [ebp - 0x138]
mov ecx, dword [ebp - 0x154]
mov edx, dword [ebp - 0x148]
push ecx
push eax
push str._s_d.tmp
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
jmp 0x47147d
cmp eax, 0x2af9
jne 0x47147d
call fcn.004651c0
lea ecx, [ebp - 0x148]
push ecx
push eax
mov dword [ebp - 0x17c], eax
call fcn.004627d0
add esp, 8
cmp dword [ebp - 0x17c], 0
je 0x47147d
mov edx, dword [ebp - 0x17c]
push edx
call fcn.0048efd8
add esp, 4
mov ecx, dword [ebp - 0x148]
xor eax, eax
push eax
push 0x80
push 2
mov dword [ebp - 0x1d4], eax
mov dword [ebp - 0x1d0], eax
lea eax, [ebp - 0x1d8]
push eax
push 1
push 2
push ecx
mov dword [ebp - 0x1d8], 0xc
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x140], eax
test eax, eax
jne 0x4714e0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push edi
push str.InternetGetRequestEx_:_Error_occured_while_creating_the_file______lu__n
call fcn.00423ad0
push edi
call fcn.00464180
add esp, 0xc
jmp 0x47182c
cmp dword [ebp - 0x1c4], 1
jne 0x471588
push str.File_download_more_than_4_GB_method__n
call fcn.00423db0
mov edx, dword [ebp - 0x158]
mov ecx, dword [ebp + 0x38]
push edx
mov edx, dword [ebp + 0x34]
lea eax, [ebp - 0x1b0]
push eax
mov eax, dword [ebp - 0x170]
push ecx
mov ecx, dword [ebp - 0x16c]
push edx
mov edx, dword [ebp - 0x184]
push eax
mov eax, dword [ebp - 0x180]
push ecx
mov ecx, dword [ebp - 0x178]
push ebx
push edx
mov edx, dword [ebp - 0x188]
push eax
mov eax, dword [ebp + 0x14]
push ecx
mov ecx, dword [ebp - 0x150]
push edx
mov edx, dword [ebp - 0x190]
push eax
mov eax, dword [ebp + 8]
push ecx
mov ecx, dword [ebp - 0x140]
push edx
push eax
push ecx
call fcn.0046eb50
mov edi, eax
add esp, 0x44
test edi, edi
jne 0x471575
push str.InternetGetRequestEx:_File_downloaded_successfully_without_checking_the_contentlength__n
call fcn.00423db0
add esp, 4
jmp 0x471818
push edi
push str.InternetGetRequestEx:_More_than_4GB_file_cannot_download_and_error__lu_n
call fcn.00423ad0
add esp, 8
jmp 0x471818
lea edx, [ebp - 0x160]
push edx
push esi
mov dword [ebp - 0x160], 0
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
jne 0x471716
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push edi
push str.InternetGetRequestEx_:_Error_occured_in_WinHttpQueryDataAvailable______lu__n
call fcn.00423ad0
push edi
call fcn.00464180
add esp, 0xc
cmp edi, 0x2ee2
jne 0x471716
mov edi, dword [ebp - 0x144]
push edi
push str.Total_Bytes_read_so_far:_lu_n
call fcn.00423db0
push str.InternetGetRequestEx_:_second_attempt_to_recover_from_previous_error_n
call fcn.00423db0
add esp, 0xc
push esi
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call esi
mov eax, dword [ebp - 0x1ac]
push eax
call esi
mov ecx, dword [ebp - 0x1b0]
push ecx
call esi
push 0x190
push 1
call fcn.00491e51
add esp, 8
mov esi, eax
test edi, edi
jne 0x471636
mov edx, dword [ebp - 0x164]
dec edx
push edx
push str.Range:_bytes0__lu
push esi
call fcn.00463e60
add esp, 0xc
jmp 0x47164d
mov eax, dword [ebp - 0x164]
dec eax
push eax
push edi
push str.Range:_bytes_lu__lu
push esi
call fcn.00463e60
add esp, 0x10
push esi
push str.InternetGetRequestByBitrate:_Content_Range_Header_message:__S_n
call fcn.00423960
mov ecx, dword [ebp - 0x158]
mov eax, dword [ebp + 0x38]
push 0
push ecx
mov ecx, dword [ebp + 0x34]
lea edx, [ebp - 0x1b0]
push edx
mov edx, dword [ebp - 0x170]
push eax
mov eax, dword [ebp - 0x16c]
push ecx
mov ecx, dword [ebp - 0x184]
push edx
mov edx, dword [ebp - 0x180]
push eax
mov eax, dword [ebp - 0x178]
push ebx
push ecx
mov ecx, dword [ebp - 0x188]
push edx
mov edx, dword [ebp + 0x14]
push eax
mov eax, dword [ebp - 0x150]
push ecx
mov ecx, dword [ebp - 0x190]
push edx
mov edx, dword [ebp + 8]
push eax
push ecx
push edx
mov dword [ebp - 0x1a4], 1
mov dword [ebp - 0x1a0], esi
call fcn.00469e40
add esp, 0x48
mov edi, eax
test esi, esi
je 0x4716d8
push esi
call fcn.0048efd8
add esp, 4
mov eax, dword [ebp - 0x1b0]
mov ecx, dword [ebp - 0x1ac]
mov esi, dword [ebp - 0x1a8]
mov dword [ebp - 0x15c], eax
mov dword [ebp - 0x1c8], ecx
mov dword [ebp - 0x1b4], esi
test edi, edi
jne 0x471716
lea edx, [ebp - 0x160]
push edx
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
je 0x4717cb
cmp dword [ebp - 0x160], 0
je 0x471a17
mov eax, dword [ebp - 0x160]
inc eax
push eax
push 1
call fcn.00491e51
mov edx, dword [ebp - 0x160]
add esp, 8
lea ecx, [ebp - 0x194]
push ecx
push edx
mov ebx, eax
push ebx
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x4717f6
mov eax, dword [ebp - 0x194]
add dword [ebp - 0x144], eax
test eax, eax
je 0x47178b
mov edx, dword [ebp - 0x140]
push 0
lea ecx, [ebp - 0x1dc]
push ecx
push eax
push ebx
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4719de
mov eax, dword [ebp - 0x194]
test ebx, ebx
je 0x47179e
push ebx
call fcn.0048efd8
mov eax, dword [ebp - 0x194]
add esp, 4
mov ecx, dword [ebp - 0x164]
mov edx, dword [ebp - 0x144]
cmp edx, ecx
je 0x4719f9
ja 0x471a05
test eax, eax
je 0x471a17
mov ebx, dword [ebp - 0x174]
jmp 0x471588
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push edi
push str.InternetGetRequestEx_:_Error_occured_in_WinHttpQueryDataAvailable______ld__n
call fcn.00423ad0
push edi
call fcn.00464180
add esp, 0xc
mov dword [ebp - 0x160], 0
jmp 0x471a17
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push edi
push str.InternetGetRequestEx_:__Error_in_WinHttpReadData______lu__n
call fcn.00423ad0
push edi
call fcn.00464180
add esp, 0xc
mov ebx, dword [ebp - 0x174]
mov esi, dword [ebp - 0x140]
push esi
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x1b4]
push edx
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
test eax, eax
jne 0x471859
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push str.InternetGetRequestEx_:__Error_in_WinHttpCloseHandle_hRequest______lu__n
call fcn.00423ad0
push esi
call fcn.00464180
add esp, 0xc
mov eax, dword [ebp - 0x1c8]
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
test eax, eax
jne 0x471886
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push str.InternetGetRequestEx_:__Error_in_WinHttpCloseHandle_hConnect______lu__n
call fcn.00423ad0
push esi
call fcn.00464180
add esp, 0xc
mov ecx, dword [ebp - 0x15c]
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
test eax, eax
jne 0x4718b3
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push str.InternetGetRequestEx_:__Error_in_WinHttpCloseHandle_hSession______lu__n
call fcn.00423ad0
push esi
call fcn.00464180
add esp, 0xc
test edi, edi
jne 0x471d40
cmp byte [ebp + 0x40], 1
jne 0x4719a4
cmp byte [ebp - 0x139], 1
jne 0x4719a4
mov edx, dword [ebp - 0x150]
push edx
push str.InternetGetRequestEx_:_Successfully_downloaded_the_Gzip_compressed_file_from_the_server__S__n
call fcn.00423db0
push str.InternetGetRequestEx_:_Need_to_decompress_the_file_n
call fcn.00423960
mov ecx, dword [ebp - 0x148]
add esp, 0xc
push 3
lea eax, [ebp - 0x90]
push ecx
lea ecx, [ebp - 0x94]
mov dword [ebp - 0x94], eax
call fcn.004622b0
mov eax, dword [ebp - 0x148]
push 3
lea edx, [ebp - 0x130]
push eax
lea ecx, [ebp - 0x134]
mov byte [ebp - 4], 9
mov dword [ebp - 0x134], edx
call fcn.004622b0
mov ecx, dword [ebp - 0x94]
mov edx, dword [ebp - 0x134]
push ecx
push edx
mov byte [ebp - 4], 0xa
call fcn.00466660
mov byte [ebp - 0x139], al
mov eax, dword [ebp - 0x134]
lea ecx, [ebp - 0x130]
add esp, 8
cmp eax, ecx
je 0x47196d
push eax
call fcn.0048efd8
add esp, 4
mov eax, dword [ebp - 0x94]
lea edx, [ebp - 0x90]
mov byte [ebp - 4], 5
cmp eax, edx
je 0x47198a
push eax
call fcn.0048efd8
add esp, 4
cmp byte [ebp - 0x139], 0
je 0x471b6a
push str.InternetGetRequestEx_:_File_Decompressed_successfully._n
call fcn.00423db0
add esp, 4
cmp dword [ebp + 0x34], 0x2af9
jne 0x471ca3
mov esi, dword [ebp - 0x170]
push esi
call fcn.004655c0
add esp, 4
cmp eax, 1
jne 0x471c8c
mov ecx, dword [esi]
push ecx
push str.Data_in_memory_:__s_n
call fcn.00423960
add esp, 8
jmp 0x471d40
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push edi
push str.InternetGetRequestEx_:__Error_in_WriteFile______lu__n
call fcn.00423ad0
add esp, 8
jmp 0x471812
push str.Bytes_read_reached_the_contenlength_n
call fcn.00423db0
jmp 0x471a14
push str.InternetGetRequestEx_:_File_downloading_more_than_the_content_length._File_download_deleted_and_download_failed.__n
call fcn.00423ad0
mov edi, 0xd
add esp, 4
mov eax, dword [ebp - 0x144]
push eax
push str.InternetGetRequestEx_:_Total_bytes_read___lu_n
call fcn.00423db0
add esp, 8
test edi, edi
jne 0x471812
mov ecx, dword [ebp - 0x140]
push edi
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, dword [ebp - 0x164]
jne 0x471a68
push esi
push str.InternetGetRequestEx_:_GetFileSize_returns_:___u_n
call fcn.00423db0
push str.InternetGetRequestEx_:_File_completely_downloaded..__n
call fcn.00423db0
add esp, 0xc
jmp 0x471812
push str.InternetGetRequestEx_:_Error_in_downloading..__n
mov edi, 0x2c3
call fcn.00423db0
push esi
push str.InternetGetRequestEx_:_Only_partial_file_downloaded._GetFileSize_returns_:___u_n
call fcn.00423db0
jmp 0x47180f
cmp edi, 0x130
jne 0x471aad
mov edx, dword [0x515dc0]
push edx
push str.InternetGetRequestEx_:File_not_modified_since_the_time:__S_n
call fcn.00423db0
add esp, 8
mov edi, 0x15f91
jmp 0x47182c
cmp edi, 0x12e
je 0x471ad0
cmp edi, 0x12d
je 0x471ad0
push edi
push str.InternetGetRequestEx_:_Failed_with_the_http_status_code___d__n
call fcn.00423ad0
add esp, 8
jmp 0x47182c
lea eax, [ebp - 0x154]
push eax
push esi
call fcn.00464f10
mov edi, dword [ebp - 0x154]
lea ecx, [ebp - 0x154]
push edi
push ecx
call fcn.00463bf0
add esp, 0x10
mov esi, dword [ebp - 0x158]
push eax
lea ecx, [esi + 0x24]
mov byte [ebp - 4], 8
call fcn.0040fa30
mov eax, dword [ebp - 0x154]
add eax, 0xfffffff0
mov byte [ebp - 4], 5
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x471b2c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esi + 0x24]
cmp dword [eax - 4], 1
jle 0x471b41
mov ecx, dword [eax - 0xc]
push ecx
lea ecx, [esi + 0x24]
call fcn.004014b0
mov esi, dword [esi + 0x24]
push esi
push str.Redirection_url_is__s_n
call fcn.00423db0
add esp, 8
test edi, edi
je 0x471b5f
push edi
call fcn.0048efd8
add esp, 4
mov edi, dword [ebp - 0x19c]
jmp 0x47182c
push str.InternetGetRequestEx_:_File_Decompression_failure._So_need_to_download_the_original_file._n
mov dword [ebp - 0x1b8], 1
call fcn.00423ad0
mov eax, dword [0x515dc0]
add esp, 4
test eax, eax
je 0x471b9d
push eax
call fcn.0048efd8
add esp, 4
mov dword [0x515dc0], 0
mov eax, dword [ebp - 0x158]
mov ecx, dword [ebp + 0x38]
mov edx, dword [ebp + 0x34]
mov esi, dword [ebp - 0x16c]
push 0
push eax
mov eax, dword [ebp - 0x170]
push ecx
mov ecx, dword [ebp - 0x184]
push edx
mov edx, dword [ebp - 0x180]
push eax
mov eax, dword [ebp - 0x178]
push esi
push ebx
push ecx
mov ecx, dword [ebp - 0x188]
push edx
mov edx, dword [ebp + 0x14]
push eax
mov eax, dword [ebp - 0x150]
push ecx
mov ecx, dword [ebp - 0x190]
push edx
mov edx, dword [ebp + 8]
push eax
push ecx
push edx
call fcn.00470bf0
mov dword [ebp - 0x1c0], eax
lea eax, [ebp - 0x140]
push eax
push esi
mov dword [ebp - 0x140], 0
call fcn.00462840
mov esi, dword [ebp - 0x140]
mov eax, esi
add esp, 0x44
lea ecx, [eax + 1]
nop
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x471c20
sub eax, ecx
add eax, 0x41
push eax
push 1
call fcn.00491e51
push esi
push str._tGzip_file_Decompression_failed_for_the_file__s_n
push eax
mov dword [ebp - 0x15c], eax
call fcn.00492848
mov eax, dword [ebp - 0x140]
add esp, 0x14
test eax, eax
je 0x471c66
push eax
call fcn.0048efd8
add esp, 4
mov dword [ebp - 0x140], 0
mov esi, dword [ebp - 0x15c]
push esi
call fcn.0045ddc0
add esp, 4
test esi, esi
je 0x471c82
push esi
call fcn.0048efd8
add esp, 4
call fcn.00467fc0
jmp 0x471d40
push str.InternetGetRequestEx:_could_nt_read_the_data_from_.tmp_file__n
call fcn.00423ad0
add esp, 4
mov edi, 6
jmp 0x471d40
mov eax, dword [ebp - 0x138]
mov esi, 1
cmp dword [eax - 4], esi
jle 0x471cc8
mov edx, dword [eax - 0xc]
push edx
lea ecx, [ebp - 0x138]
call fcn.00402490
mov eax, dword [ebp - 0x138]
push 0
push eax
mov eax, dword [ebp - 0x148]
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
cmp eax, esi
je 0x471d04
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp - 0x16c]
mov edx, dword [ebp - 0x148]
push ecx
push edx
push str.InternetGetRequestEx_:_could_nt_copy_from__S_file_to__S___n
mov edi, eax
call fcn.00423ad0
push edi
call fcn.004635b0
jmp 0x471d3d
mov eax, dword [ebp - 0x14c]
cmp dword [eax - 4], esi
jle 0x471d24
mov eax, dword [eax - 0xc]
push eax
lea ecx, [ebp - 0x14c]
call fcn.00402490
mov eax, dword [ebp - 0x14c]
mov ecx, dword [ebp - 0x16c]
mov edx, dword [ebp - 0x150]
push ecx
push edx
push eax
push str.InternetGetRequestEx_:_Successfully_downloaded_the_file__S_from_the_server__S_to_the_destination_file__S__n
call fcn.00423db0
add esp, 0x10
mov eax, dword [ebp - 0x164]
mov ecx, dword [ebp - 0x16c]
mov edx, dword [ebp + 0x14]
push edi
push eax
mov eax, dword [ebp - 0x150]
push ecx
push ebx
push edx
push eax
call fcn.00468750
mov ecx, dword [ebp - 0x148]
add esp, 0x18
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [ebp - 0x148]
test eax, eax
je 0x471d8d
push eax
call fcn.0048efd8
add esp, 4
mov dword [ebp - 0x148], 0
push str._________End_Of_InternetGetRequestEx_Method___________n
call fcn.00423960
mov eax, dword [ebp - 0x14c]
add esp, 4
add eax, 0xfffffff0
cmp dword [ebp - 0x1b8], 0
mov byte [ebp - 4], 2
je 0x471e4d
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x471dcd
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x138]
add eax, 0xfffffff0
mov byte [ebp - 4], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471df3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x198]
add eax, 0xfffffff0
mov byte [ebp - 4], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471e19
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x18c]
add eax, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471e42
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x1c0]
jmp 0x471edd
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471e66
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x138]
add eax, 0xfffffff0
mov byte [ebp - 4], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471e8c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x198]
add eax, 0xfffffff0
mov byte [ebp - 4], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471eb2
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x18c]
add eax, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x471edb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0048ed61
mov esp, ebp
pop ebp
ret