Function at 0x405520
Capabilities:
Check if file exists
Parse url

Disassembly:
push 0xffffffffffffffff
push 0x4386bc
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x390
push ebx
push ebp
push esi
push edi
mov esi, ecx
push 3
push 0x4483b8
lea ecx, [esp + 0x18]
mov ebx, dword [esi + 4]
mov dword [esp + 0x20], 0x104
call fcn.004237f6
mov edi, dword [esp + 0x3b4]
push ecx
mov ecx, esp
mov dword [esp + 0x1c], esp
push edi
xor ebp, ebp
push eax
push ecx
mov dword [esp + 0x3bc], ebp
call fcn.004239df
mov ecx, ebx
call fcn.00407250
lea ecx, [esp + 0x10]
mov dword [esp + 0x3a8], 0xffffffff
call fcn.00423788
push edi
mov ecx, esi
call fcn.00405cb0
test eax, eax
je 0x405768
mov edx, dword [esi + 8]
push edx
push edi
call fcn.00416010
add esp, 8
test eax, eax
jne 0x4055e6
mov ecx, dword [esp + 0x3b4]
mov eax, dword [esi + 0xc]
mov dword [ecx], eax
mov eax, dword [esp + 0x3b8]
mov edx, dword [esi + 0x14]
mov dword [eax], edx
mov ecx, dword [esi + 0x18]
mov dword [eax + 4], ecx
mov eax, dword [esp + 0x3bc]
mov edx, dword [esi + 0x10]
mov dword [eax], edx
jmp 0x4058d1
cmp dword [esi + 0x20], ebp
jne 0x4055f3
push edi
mov ecx, esi
call fcn.00406090
lea edx, [esp + 0x18]
push ebp
lea eax, [esp + 0x2a0]
push edx
lea ecx, [esp + 0x1a0]
push eax
push edi
mov dword [esp + 0x58], ecx
mov dword [esp + 0x40], ebp
mov dword [esp + 0x4c], ebp
mov dword [esp + 0x54], ebp
mov dword [esp + 0x5c], 0x104
mov dword [esp + 0x64], ebp
mov dword [esp + 0x34], ebp
mov dword [esp + 0x2c], 0x3c
call dword [sym.imp.WININET.dll_InternetCanonicalizeUrlA]
lea ecx, [esp + 0x1c]
lea edx, [esp + 0x29c]
push ecx
push ebp
push ebp
push edx
call dword [sym.imp.WININET.dll_InternetCrackUrlA]
mov edx, dword [esi + 0x20]
push ebp
lea eax, [esp + 0x5c]
push ebp
lea ecx, [esp + 0x1a0]
push eax
push ecx
push edx
call dword [sym.imp.WININET.dll_FtpFindFirstFileA]
cmp eax, ebp
jne 0x4056f3
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
jne 0x4056e9
cmp dword [esp + 0x3c0], ebp
je 0x4056c6
push 1
push edi
lea ecx, [esp + 0x18]
call fcn.004237f6
push ecx
mov dword [esp + 0x3b0], 1
mov ecx, esp
mov dword [esp + 0x1c], esp
push 0x4483a4
push eax
push ecx
call fcn.004239df
mov ecx, ebx
call fcn.00407250
lea ecx, [esp + 0x10]
mov dword [esp + 0x3a8], 0xffffffff
call fcn.00423788
mov edx, dword [esp + 0x3b4]
mov eax, dword [esp + 0x3b8]
mov dword [edx], ebp
mov dword [eax], ebp
mov dword [eax + 4], ebp
mov eax, dword [esp + 0x3bc]
mov dword [eax], ebp
jmp 0x4058d1
push 0x448390
jmp 0x4058c3
mov ebp, dword [esp + 0x3b4]
mov ecx, dword [esp + 0x58]
mov ebx, dword [esp + 0x3b8]
mov edx, dword [esp + 0x6c]
mov dword [ebp], ecx
mov ecx, dword [esp + 0x70]
mov dword [ebx], edx
mov edx, dword [esp + 0x78]
mov dword [ebx + 4], ecx
mov ecx, dword [esp + 0x74]
sub edx, ecx
mov ecx, dword [esp + 0x3bc]
push eax
mov dword [ecx], edx
call dword [sym.imp.WININET.dll_InternetCloseHandle]
test eax, eax
jne 0x40573d
push 0x448374
jmp 0x4058c3
push edi
lea ecx, [esi + 8]
call fcn.004238d0
mov edx, dword [ebp]
mov eax, dword [esp + 0x3bc]
mov dword [esi + 0xc], edx
mov ecx, dword [eax]
mov dword [esi + 0x10], ecx
mov edx, dword [ebx]
mov dword [esi + 0x14], edx
mov eax, dword [ebx + 4]
mov dword [esi + 0x18], eax
jmp 0x4058d1
push edi
mov ecx, esi
call fcn.00405cf0
test eax, eax
je 0x4058d1
lea ecx, [esp + 0x58]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
jne 0x40587f
mov ebp, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebp
cmp eax, 2
jne 0x4057eb
mov eax, dword [esp + 0x3c0]
test eax, eax
je 0x405846
push 1
push edi
lea ecx, [esp + 0x18]
call fcn.004237f6
push ecx
mov dword [esp + 0x3b0], 2
mov edx, esp
mov dword [esp + 0x1c], esp
push 0x448360
push eax
push edx
call fcn.004239df
mov ecx, ebx
call fcn.00407250
mov dword [esp + 0x3a8], 0xffffffff
lea ecx, [esp + 0x10]
jmp 0x405841
call ebp
cmp eax, 3
jne 0x405876
mov eax, dword [esp + 0x3c0]
test eax, eax
je 0x405846
push 3
push edi
lea ecx, [esp + 0x18]
call fcn.004237f6
push ecx
mov dword [esp + 0x3b0], 3
mov edx, esp
mov dword [esp + 0x1c], esp
push 0x448348
push eax
push edx
call fcn.004239df
mov ecx, ebx
call fcn.00407250
mov dword [esp + 0x3a8], 0xffffffff
lea ecx, [esp + 0x10]
call fcn.00423788
mov eax, dword [esp + 0x3b4]
mov ecx, dword [esp + 0x3bc]
mov dword [eax], 0
mov eax, dword [esp + 0x3b8]
mov dword [eax], 0
mov dword [eax + 4], 0
mov dword [ecx], 0
jmp 0x4058d1
push 0x448390
call ebp
jmp 0x4058c9
mov edx, dword [esp + 0x3b4]
mov ecx, dword [esp + 0x58]
mov edi, dword [esp + 0x74]
push eax
mov dword [edx], ecx
mov ecx, dword [esp + 0x3bc]
mov edx, dword [esp + 0x70]
mov dword [ecx], edx
mov edx, dword [esp + 0x74]
mov dword [ecx + 4], edx
mov ecx, dword [esp + 0x7c]
mov edx, dword [esp + 0x3c0]
sub ecx, edi
mov dword [edx], ecx
call dword [sym.imp.KERNEL32.dll_FindClose]
test eax, eax
jne 0x4058d1
push 0x448330
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov ecx, esi
call fcn.00405e30
mov ecx, dword [esp + 0x3a0]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x39c
ret 0x14