Function at 0x4992d0
Capabilities:
Check for time delay via gettickcount
Check internet connectivity via wininet
Connect to http server
Create http request
Delete file
Download and write a file
Move file
Read data from internet
Receive and write data from server to client
Receive data
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4b1b28
mov eax, dword fs:[0]
push eax
push ecx
mov eax, 0x42e4
call fcn.0047ad70
mov eax, dword [0x4ec00c]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x422c], ecx
mov dword [ebp - 0x42d8], 0
mov dword [ebp - 0x42d0], 4
mov dword [ebp - 0x4230], 0
mov dword [ebp - 0x4238], 0
mov dword [ebp - 0x423c], 0
push 0
lea eax, [ebp - 0x4280]
push eax
call dword [sym.imp.WININET.dll_InternetGetConnectedState]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
push 0x4cfd10
lea ecx, [ebp - 0x94]
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
mov edx, dword [ebp - 0x422c]
cmp dword [edx], 0
je 0x4993c1
mov eax, dword [ebp - 0x422c]
add eax, 0xcc
push eax
mov ecx, dword [ebp - 0x422c]
add ecx, 4
push ecx
push 0x4cfd24
lea edx, [ebp - 0x224]
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
push 0
push 0
lea eax, [ebp - 0x224]
push eax
push 3
lea ecx, [ebp - 0x94]
push ecx
call dword [sym.imp.WININET.dll_InternetOpenW]
mov dword [ebp - 0x4230], eax
jmp 0x499404
mov edx, dword [ebp - 0x4280]
and edx, 4
jne 0x4993e9
push 0
push 0
push 0
push 1
lea eax, [ebp - 0x94]
push eax
call dword [sym.imp.WININET.dll_InternetOpenW]
mov dword [ebp - 0x4230], eax
jmp 0x499404
push 0
push 0
push 0
push 0
lea ecx, [ebp - 0x94]
push ecx
call dword [sym.imp.WININET.dll_InternetOpenW]
mov dword [ebp - 0x4230], eax
cmp dword [ebp - 0x4230], 0
jne 0x499475
push 0x4cfd48
push 0x206
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x42d4], esp
push 0x4cfd74
call fcn.00419750
mov dword [ebp - 0x42f4], eax
mov dword [ebp - 4], 0
call sym.Install_adv.exe_public:_static_class_CNsLog____cdecl_CNsLog::Instance_void_
mov dword [ebp - 4], 0xffffffff
mov ecx, eax
call sym.Install_adv.exe_public:_void___thiscall_CNsLog::WriteLog2_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char____int__wchar_t_const__
cmp dword [ebp + 0x14], 0
je 0x49946e
sub esp, 8
xorps xmm0, xmm0
movsd qword [esp], xmm0
push 0
push 0
push 0
push 0
mov edx, dword [ebp + 8]
push edx
push 4
call dword [ebp + 0x14]
xor eax, eax
jmp 0x499f16
mov dword [ebp - 0x4284], 0xbb8
push 4
lea eax, [ebp - 0x4284]
push eax
push 2
mov ecx, dword [ebp - 0x4230]
push ecx
call dword [sym.imp.WININET.dll_InternetSetOptionW]
mov edx, dword [ebp + 8]
push edx
lea ecx, [ebp - 0x4228]
call fcn.004096a0
mov dword [ebp - 4], 1
lea ecx, [ebp - 0x4240]
call fcn.004097c0
mov byte [ebp - 4], 2
push 7
push 0x4cfd9c
lea ecx, [ebp - 0x4228]
call fcn.0040f4b0
mov dword [ebp - 0x4270], eax
cmp dword [ebp - 0x4270], 0
jle 0x499593
mov eax, dword [ebp - 0x4270]
sub eax, 6
push eax
push 6
lea ecx, [ebp - 0x4290]
push ecx
lea ecx, [ebp - 0x4228]
call fcn.004126b0
mov dword [ebp - 0x4288], eax
mov edx, dword [ebp - 0x4288]
mov dword [ebp - 0x428c], edx
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x428c]
push eax
lea ecx, [ebp - 0x4240]
call fcn.00409610
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x4290]
call fcn.00409680
lea ecx, [ebp - 0x4228]
call fcn.004097f0
sub eax, dword [ebp - 0x4270]
push eax
lea ecx, [ebp - 0x42b4]
push ecx
lea ecx, [ebp - 0x4228]
call fcn.004125e0
mov dword [ebp - 0x42c4], eax
mov edx, dword [ebp - 0x42c4]
mov dword [ebp - 0x42c0], edx
mov byte [ebp - 4], 4
mov eax, dword [ebp - 0x42c0]
push eax
lea ecx, [ebp - 0x4228]
call fcn.00409610
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x42b4]
call fcn.00409680
jmp 0x4995b2
mov ecx, dword [ebp + 8]
push ecx
lea ecx, [ebp - 0x4240]
call fcn.004095c0
push 0x4cfda0
lea ecx, [ebp - 0x4228]
call fcn.004095c0
mov dword [ebp - 0x4260], 0
mov edx, dword [ebp - 0x422c]
mov eax, dword [ebp - 0x4260]
cmp eax, dword [edx + 0x1b0]
jge 0x4996f6
push 0
push 0x8000000
push 1
mov ecx, dword [ebp + 0x1c]
push ecx
mov edx, dword [ebp + 0x18]
push edx
push 0x15
lea ecx, [ebp - 0x4240]
call sym.Install_adv.exe_public:_char_const____thiscall_Json::StaticString::operator_char_const__void_const
push eax
mov eax, dword [ebp - 0x4230]
push eax
call dword [sym.imp.WININET.dll_InternetConnectW]
mov dword [ebp - 0x4238], eax
cmp dword [ebp - 0x4238], 0
je 0x499619
jmp 0x4996f6
mov ecx, dword [ebp - 0x4260]
add ecx, 1
mov dword [ebp - 0x4260], ecx
mov edx, dword [ebp - 0x422c]
mov eax, dword [ebp - 0x4260]
cmp eax, dword [edx + 0x1b0]
jl 0x4996de
push 0x4cfda4
push 0x231
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x42ec], esp
push 0x4cfdd4
call fcn.00419750
mov dword [ebp - 0x42f0], eax
mov byte [ebp - 4], 5
call sym.Install_adv.exe_public:_static_class_CNsLog____cdecl_CNsLog::Instance_void_
mov byte [ebp - 4], 2
mov ecx, eax
call sym.Install_adv.exe_public:_void___thiscall_CNsLog::WriteLog2_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char____int__wchar_t_const__
cmp dword [ebp + 0x14], 0
je 0x49969b
sub esp, 8
xorps xmm0, xmm0
movsd qword [esp], xmm0
push 0
push 0
push 0
push 0
mov ecx, dword [ebp + 8]
push ecx
push 4
call dword [ebp + 0x14]
mov edx, dword [ebp - 0x4230]
push edx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov dword [ebp - 0x42b0], 0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x4240]
call fcn.00409680
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x4228]
call fcn.00409680
mov eax, dword [ebp - 0x42b0]
jmp 0x499f16
mov eax, dword [ebp - 0x422c]
mov ecx, dword [eax + 0x1b4]
push ecx
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x4995bc
mov edx, dword [ebp - 0x422c]
cmp dword [edx], 0
je 0x49975f
mov eax, dword [ebp - 0x422c]
add eax, 0xe4
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
mov ecx, dword [ebp - 0x422c]
add ecx, 0xe4
push ecx
push 0x2b
mov edx, dword [ebp - 0x4238]
push edx
call dword [sym.imp.WININET.dll_InternetSetOptionW]
mov eax, dword [ebp - 0x422c]
add eax, 0x148
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
mov ecx, dword [ebp - 0x422c]
add ecx, 0x148
push ecx
push 0x2c
mov edx, dword [ebp - 0x4238]
push edx
call dword [sym.imp.WININET.dll_InternetSetOptionW]
mov eax, dword [ebp + 0xc]
push eax
lea ecx, [ebp - 0x4234]
call fcn.004096a0
mov byte [ebp - 4], 6
push 0x4cfdfc
lea ecx, [ebp - 0x4234]
call fcn.004156b0
xorps xmm0, xmm0
movlpd qword [ebp - 0x4248], xmm0
cmp dword [ebp + 0x10], 0
je 0x4997b3
lea ecx, [ebp - 0x4234]
call sym.Install_adv.exe_public:_char_const____thiscall_Json::StaticString::operator_char_const__void_const
push eax
call sym.Install_adv.exe_long_long___int64____cdecl_FileSize_wchar_t_const__
add esp, 4
mov dword [ebp - 0x4248], eax
mov dword [ebp - 0x4244], edx
push 0
push 2
push bind
lea ecx, [ebp - 0x4228]
call sym.Install_adv.exe_public:_char_const____thiscall_Json::StaticString::operator_char_const__void_const
push eax
mov ecx, dword [ebp - 0x4238]
push ecx
call dword [sym.imp.WININET.dll_FtpOpenFileW]
mov dword [ebp - 0x423c], eax
cmp dword [ebp - 0x423c], 0
jne 0x499843
mov edx, dword [ebp - 0x4238]
push edx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov eax, dword [ebp - 0x4230]
push eax
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov dword [ebp - 0x42b8], 0
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x4234]
call fcn.00409680
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x4240]
call fcn.00409680
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x4228]
call fcn.00409680
mov eax, dword [ebp - 0x42b8]
jmp 0x499f16
xorps xmm0, xmm0
movlpd qword [ebp - 0x4250], xmm0
xorps xmm0, xmm0
movlpd qword [ebp - 0x4258], xmm0
mov dword [ebp - 0x42bc], 0
lea ecx, [ebp - 0x42bc]
push ecx
mov edx, dword [ebp - 0x423c]
push edx
call dword [sym.imp.WININET.dll_FtpGetFileSize]
xor ecx, ecx
mov dword [ebp - 0x4250], eax
mov dword [ebp - 0x424c], ecx
mov edx, dword [ebp - 0x4250]
cmp edx, dword [ebp - 0x4248]
jne 0x49996d
mov eax, dword [ebp - 0x424c]
cmp eax, dword [ebp - 0x4244]
jne 0x49996d
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov edx, dword [ebp + 0xc]
push edx
lea ecx, [ebp - 0x4234]
call sym.Install_adv.exe_public:_char_const____thiscall_Json::StaticString::operator_char_const__void_const
push eax
call fcn.0043fa9b
add esp, 8
cmp dword [ebp + 0x14], 0
je 0x499901
sub esp, 8
xorps xmm0, xmm0
movsd qword [esp], xmm0
mov eax, dword [ebp - 0x4244]
push eax
mov ecx, dword [ebp - 0x4248]
push ecx
mov edx, dword [ebp - 0x4244]
push edx
mov eax, dword [ebp - 0x4248]
push eax
mov ecx, dword [ebp + 8]
push ecx
push 2
call dword [ebp + 0x14]
mov edx, dword [ebp - 0x423c]
push edx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov eax, dword [ebp - 0x4238]
push eax
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov ecx, dword [ebp - 0x4230]
push ecx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov dword [ebp - 0x4294], 1
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x4234]
call fcn.00409680
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x4240]
call fcn.00409680
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x4228]
call fcn.00409680
mov eax, dword [ebp - 0x4294]
jmp 0x499f16
lea ecx, [ebp - 0x4234]
call sym.Install_adv.exe_public:_char_const____thiscall_Json::StaticString::operator_char_const__void_const
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
xorps xmm0, xmm0
movlpd qword [ebp - 0x4248], xmm0
mov dword [ebp - 0x426c], 0
push 0x4cfe04
lea ecx, [ebp - 0x4234]
call sym.Install_adv.exe_public:_char_const____thiscall_Json::StaticString::operator_char_const__void_const
push eax
lea edx, [ebp - 0x426c]
push edx
call fcn.0043ceb0
add esp, 0xc
test eax, eax
je 0x499a24
mov eax, dword [ebp - 0x423c]
push eax
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov ecx, dword [ebp - 0x4238]
push ecx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov edx, dword [ebp - 0x4230]
push edx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov dword [ebp - 0x4298], 0
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x4234]
call fcn.00409680
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x4240]
call fcn.00409680
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x4228]
call fcn.00409680
mov eax, dword [ebp - 0x4298]
jmp 0x499f16
mov dword [ebp - 0x429c], 0x1388
push 4
lea eax, [ebp - 0x429c]
push eax
push 6
mov ecx, dword [ebp - 0x423c]
push ecx
call dword [sym.imp.WININET.dll_InternetSetOptionW]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x42a8], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x427c], eax
mov dword [ebp - 0x4268], 0x64
mov edx, dword [ebp - 0x422c]
movzx eax, byte [edx + 0x1ac]
test eax, eax
jne 0x499e05
mov ecx, dword [ebp + 8]
push ecx
mov ecx, dword [ebp - 0x422c]
call sym.Install_adv.exe_public:_int___thiscall_CNsDownload::isStop_wchar_t_const__
test eax, eax
je 0x499ad3
mov edx, dword [ebp - 0x4258]
cmp edx, dword [ebp - 0x4250]
jne 0x499aac
mov eax, dword [ebp - 0x4254]
cmp eax, dword [ebp - 0x424c]
je 0x499ace
cmp dword [ebp + 0x14], 0
je 0x499ace
sub esp, 8
xorps xmm0, xmm0
movsd qword [esp], xmm0
push 0
push 0
push 0
push 0
mov ecx, dword [ebp + 8]
push ecx
push 3
call dword [ebp + 0x14]
jmp 0x499e05
mov dword [ebp - 0x425c], 0
lea edx, [ebp - 0x425c]
push edx
push 0x4000
lea eax, [ebp - 0x4224]
push eax
mov ecx, dword [ebp - 0x423c]
push ecx
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
jne 0x499bcc
push 0x4cfe0c
push 0x292
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x42c8], esp
push str.d:my2018_nslib_nscore_nsdownload.cpp
call fcn.00419750
mov dword [ebp - 0x42cc], eax
mov byte [ebp - 4], 7
call sym.Install_adv.exe_public:_static_class_CNsLog____cdecl_CNsLog::Instance_void_
mov byte [ebp - 4], 6
mov ecx, eax
call sym.Install_adv.exe_public:_void___thiscall_CNsLog::WriteLog2_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char____int__wchar_t_const__
cmp dword [ebp + 0x14], 0
je 0x499b60
sub esp, 8
xorps xmm0, xmm0
movsd qword [esp], xmm0
push 0
push 0
push 0
push 0
mov edx, dword [ebp + 8]
push edx
push 4
call dword [ebp + 0x14]
mov eax, dword [ebp - 0x423c]
push eax
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov ecx, dword [ebp - 0x4238]
push ecx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov edx, dword [ebp - 0x4230]
push edx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov dword [ebp - 0x42a0], 0
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x4234]
call fcn.00409680
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x4240]
call fcn.00409680
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x4228]
call fcn.00409680
mov eax, dword [ebp - 0x42a0]
jmp 0x499f16
cmp dword [ebp - 0x425c], 0
jne 0x499bda
jmp 0x499e05
mov byte [ebp - 4], 8
mov eax, dword [ebp - 0x426c]
push eax
mov ecx, dword [ebp - 0x425c]
push ecx
push 1
lea edx, [ebp - 0x4224]
push edx
call fcn.0043ccbf
add esp, 0x10
jmp 0x499c5e
mov dword [ebp - 4], 6
jmp 0x499ca5
xorps xmm0, xmm0
movss dword [ebp - 0x4264], xmm0
mov ecx, dword [ebp - 0x425c]
mov dword [ebp - 0x4274], ecx
cvtsi2sd xmm0, dword [ebp - 0x4274]
mov edx, dword [ebp - 0x4274]
shr edx, 0x1f
addsd xmm0, qword [edx*8 + 0x4d1de0]
movsd qword [ebp - 0x42e0], xmm0
cvtsd2ss xmm0, qword [ebp - 0x42e0]
movss dword [ebp - 0x4264], xmm0
mov eax, dword [ebp - 0x4268]
mov dword [ebp - 0x4278], eax
cvtsi2sd xmm0, dword [ebp - 0x4278]
mov ecx, dword [ebp - 0x4278]
shr ecx, 0x1f
addsd xmm0, qword [ecx*8 + 0x4d1de0]
movsd qword [ebp - 0x42e8], xmm0
cvtsd2ss xmm0, qword [ebp - 0x42e8]
divss xmm0, dword [0x4d1cf8]
movss xmm1, dword [ebp - 0x4264]
divss xmm1, xmm0
movss dword [ebp - 0x4264], xmm1
mov edx, dword [ebp - 0x4250]
cmp edx, dword [ebp - 0x4258]
jne 0x499d63
mov eax, dword [ebp - 0x424c]
cmp eax, dword [ebp - 0x4254]
jne 0x499d63
jmp 0x499e05
cmp dword [ebp + 0x14], 0
je 0x499db6
cvtss2sd xmm0, dword [ebp - 0x4264]
sub esp, 8
movsd qword [esp], xmm0
mov ecx, dword [ebp - 0x4250]
add ecx, dword [ebp - 0x4248]
mov edx, dword [ebp - 0x424c]
adc edx, dword [ebp - 0x4244]
push edx
push ecx
mov eax, dword [ebp - 0x4258]
add eax, dword [ebp - 0x4248]
mov ecx, dword [ebp - 0x4254]
adc ecx, dword [ebp - 0x4244]
push ecx
push eax
mov edx, dword [ebp + 8]
push edx
push 1
call dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x427c], eax
mov eax, dword [ebp - 0x427c]
sub eax, dword [ebp - 0x42a8]
mov dword [ebp - 0x4268], eax
jne 0x499de0
mov dword [ebp - 0x4268], 0x64
mov ecx, dword [ebp - 0x425c]
xor edx, edx
add ecx, dword [ebp - 0x4258]
adc edx, dword [ebp - 0x4254]
mov dword [ebp - 0x4258], ecx
mov dword [ebp - 0x4254], edx
jmp 0x499a68
mov eax, dword [ebp - 0x426c]
push eax
call fcn.0044023d
add esp, 4
mov ecx, dword [ebp - 0x426c]
push ecx
call fcn.0043cf8f
add esp, 4
mov edx, dword [ebp - 0x4250]
cmp edx, dword [ebp - 0x4258]
jne 0x499eaf
mov eax, dword [ebp - 0x424c]
cmp eax, dword [ebp - 0x4254]
jne 0x499eaf
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov edx, dword [ebp + 0xc]
push edx
lea ecx, [ebp - 0x4234]
call sym.Install_adv.exe_public:_char_const____thiscall_Json::StaticString::operator_char_const__void_const
push eax
call fcn.0043fa9b
add esp, 8
cmp dword [ebp + 0x14], 0
je 0x499eaf
sub esp, 8
xorps xmm0, xmm0
movsd qword [esp], xmm0
mov eax, dword [ebp - 0x4250]
add eax, dword [ebp - 0x4248]
mov ecx, dword [ebp - 0x424c]
adc ecx, dword [ebp - 0x4244]
push ecx
push eax
mov edx, dword [ebp - 0x4258]
add edx, dword [ebp - 0x4248]
mov eax, dword [ebp - 0x4254]
adc eax, dword [ebp - 0x4244]
push eax
push edx
mov ecx, dword [ebp + 8]
push ecx
push 2
call dword [ebp + 0x14]
mov edx, dword [ebp - 0x423c]
push edx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov eax, dword [ebp - 0x4238]
push eax
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov ecx, dword [ebp - 0x4230]
push ecx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
mov dword [ebp - 0x42ac], 1
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x4234]
call fcn.00409680
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x4240]
call fcn.00409680
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x4228]
call fcn.00409680
mov eax, dword [ebp - 0x42ac]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0042f10e
mov esp, ebp
pop ebp
ret 0x18