Function at 0x415e70
Capabilities:
Check http status code
Initialize winhttp library
Prepare http request
Read http header
Receive http response
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x264
mov eax, dword [0x4754f4]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
xor ebx, ebx
push edi
push 0x2000
mov dword [ebp - 0x21c], eax
mov dword [ebp - 0x208], ebx
mov dword [ebp - 0x20c], ebx
mov dword [ebp - 0x228], ebx
call fcn.004217c0
mov ecx, dword [ebp + 8]
mov esi, eax
add esp, 4
mov dword [ebp - 0x220], 0x2000
mov dword [ebp - 0x218], ebx
mov dword [ebp - 0x224], ebx
mov dword [ebp - 0x214], ebx
mov dword [ebp - 0x210], 0xffffffff
mov edx, 0x1000
sub ecx, esi
lea edi, [edx + 0x7fffeffe]
test edi, edi
je 0x415f00
movzx edi, word [ecx + eax]
cmp di, bx
je 0x415f00
mov word [eax], di
add eax, 2
dec edx
jne 0x415ee2
jmp 0x415f04
cmp edx, ebx
jne 0x415f07
sub eax, 2
push 0x38
lea edx, [ebp - 0x260]
xor ecx, ecx
push ebx
push edx
mov word [eax], cx
call fcn.0042c300
add esp, 0xc
or eax, 0xffffffff
mov dword [ebp - 0x25c], eax
mov dword [ebp - 0x250], eax
mov dword [ebp - 0x234], eax
mov dword [ebp - 0x22c], eax
mov eax, esi
mov dword [ebp - 0x264], 0x3c
lea edx, [eax + 2]
jmp 0x415f50
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x415f50
lea ecx, [ebp - 0x264]
push ecx
sub eax, edx
push ebx
sar eax, 1
push eax
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpCrackUrl]
test eax, eax
je 0x416160
push ebx
push ebx
push ebx
push ebx
push str.Funshion_3.0
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov edi, eax
mov dword [ebp - 0x218], edi
cmp edi, ebx
je 0x416160
push 0x7530
push 0x7530
push 0xea60
push 0xea60
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSetTimeouts]
test eax, eax
je 0x416160
push 0x1fe
lea eax, [ebp - 0x202]
xor edx, edx
push ebx
push eax
mov word [ebp - 0x204], dx
call fcn.0042c300
mov ebx, dword [ebp - 0x250]
add esp, 0xc
cmp ebx, 0x7ffffffe
jbe 0x415ff0
xor ecx, ecx
mov word [ebp - 0x204], cx
jmp 0x416036
mov edi, dword [ebp - 0x254]
lea eax, [ebp - 0x204]
mov ecx, eax
mov edx, 0xff
sub edi, ecx
lea ecx, [ebx + edx - 0xff]
test ecx, ecx
je 0x416024
movzx ecx, word [edi + eax]
test cx, cx
je 0x416024
mov word [eax], cx
add eax, 2
dec edx
jne 0x416005
jmp 0x416028
test edx, edx
jne 0x41602b
sub eax, 2
mov edi, dword [ebp - 0x218]
xor edx, edx
mov word [eax], dx
mov eax, dword [ebp - 0x24c]
push 0
push eax
lea ecx, [ebp - 0x204]
push ecx
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov ecx, eax
mov dword [ebp - 0x224], ecx
test ecx, ecx
je 0x416160
mov edx, dword [ebp - 0x238]
xor eax, eax
cmp dword [ebp - 0x258], 2
setne al
dec eax
and eax, 0x800000
push eax
push 0
push 0
push 0
push edx
push 0x46d870
push ecx
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov edi, eax
mov dword [ebp - 0x214], edi
test edi, edi
je 0x416160
push 0
push 0
push 0
push 0
push 0
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
je 0x416160
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
je 0x416160
push 0
lea eax, [ebp - 0x20c]
push eax
push esi
push 0
push 0x13
push edi
mov dword [ebp - 0x20c], 0x1000
call dword [sym.imp.WINHTTP.dll_WinHttpQueryHeaders]
push esi
call fcn.00421800
add esp, 4
cmp eax, 0xc8
jne 0x416166
mov ebx, dword [ebp - 0x21c]
test ebx, ebx
je 0x4161cb
cmp word [ebx], 0
je 0x4161cb
push ebx
mov edx, SHChangeNotifyRegister
mov eax, 0x1000
mov ecx, esi
call fcn.00414a20
push 0x5c
push esi
call fcn.00427e60
add esp, 8
test eax, eax
je 0x41613a
xor ecx, ecx
push esi
push ecx
mov word [eax], cx
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
mov dword [ebp - 0x210], ebx
cmp ebx, 0xffffffff
jne 0x4161d1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x208], eax
push esi
call fcn.00425750
mov eax, dword [ebp - 0x210]
add esp, 4
cmp eax, 0xffffffff
je 0x416187
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x214]
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
test eax, eax
je 0x41619a
push eax
call esi
mov eax, dword [ebp - 0x224]
test eax, eax
je 0x4161a7
push eax
call esi
mov eax, dword [ebp - 0x218]
test eax, eax
je 0x4161b4
push eax
call esi
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x208]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00420d00
mov esp, ebp
pop ebp
ret
mov ebx, dword [ebp - 0x210]
lea edx, [ebp - 0x20c]
push edx
push edi
mov dword [ebp - 0x20c], 0
call dword [sym.imp.WINHTTP.dll_WinHttpQueryDataAvailable]
test eax, eax
je 0x416160
mov eax, dword [ebp - 0x20c]
cmp eax, dword [ebp - 0x220]
jbe 0x41621d
push esi
call fcn.00425750
mov eax, dword [ebp - 0x20c]
inc eax
push eax
mov dword [ebp - 0x220], eax
call fcn.004217c0
add esp, 8
mov esi, eax
mov ecx, dword [ebp - 0x20c]
push ecx
push 0
push esi
call fcn.0042c300
mov eax, dword [ebp - 0x20c]
add esp, 0xc
lea edx, [ebp - 0x228]
push edx
push eax
push esi
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReadData]
test eax, eax
je 0x416271
cmp ebx, 0xffffffff
je 0x416271
mov edx, dword [ebp - 0x228]
xor edi, edi
push edi
lea ecx, [ebp - 0x21c]
push ecx
push edx
push esi
push ebx
mov dword [ebp - 0x21c], edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x416289
cmp dword [ebp - 0x20c], 0
jbe 0x41616c
mov edi, dword [ebp - 0x214]
jmp 0x4161cb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x20c], edi
jmp 0x416166