Function at 0x42013d
Capabilities:
Check if file exists
Copy file

Disassembly:
mov eax, 0x4638f5
call fcn.00451324
sub esp, 0xb8
push ebx
push esi
push edi
xor esi, esi
mov dword [ebp - 0x10], esi
push esi
lea ecx, [ebp - 0x34]
mov dword [ebp - 0x1c], 0xf
call fcn.0041a131
mov dword [ebp - 0x18], esi
mov byte [ebp - 0x14], 0
mov ebx, dword [ebp + 8]
add ebx, 4
mov dword [ebp - 4], esi
push ebx
mov dword [ebp - 0x70], ebx
call dword [sym.imp.KERNEL32.DLL_EnterCriticalSection]
mov byte [ebp - 4], 1
push dword [ebp + 0xc]
lea esi, [ebx + 0x18]
lea edi, [ebp - 0x10]
call fcn.0042caf2
mov eax, dword [ebx + 0x1c]
mov ecx, dword [ebp - 0x10]
cmp ecx, eax
jne 0x4201d4
push dword [ebp + 0xc]
push esi
call fcn.0042ca57
push 0xffffffffffffffff
push 0
push dword [ebp + 0x10]
mov esi, eax
mov ecx, esi
call fcn.0041a38e
mov eax, dword [ebp + 0x14]
push ebx
mov dword [esi + 0x1c], eax
call dword [sym.imp.KERNEL32.DLL_LeaveCriticalSection]
push 0
push 1
lea ecx, [ebp - 0x34]
call fcn.0041a87c
xor al, al
jmp 0x420411
lea edi, [ecx + 0x28]
lea esi, [ebp - 0x34]
call fcn.00420422
push ebx
call dword [sym.imp.KERNEL32.DLL_LeaveCriticalSection]
cmp dword [ebp - 0x18], 0
je 0x4201f7
push 0xffffffffffffffff
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.DLL_WaitForSingleObject]
push 0
push 1
lea ecx, [ebp - 0x34]
call fcn.0041a87c
push ebx
mov dword [ebp + 0x14], ebx
call dword [sym.imp.KERNEL32.DLL_EnterCriticalSection]
mov dword [ebp - 4], 2
push dword [ebp + 0xc]
lea esi, [ebx + 0x18]
lea edi, [ebp + 0xc]
call fcn.0042caf2
mov eax, dword [ebx + 0x1c]
mov esi, dword [ebp + 0xc]
cmp esi, eax
je 0x420404
add esi, 0x28
cmp byte [esi + 0x20], 0
je 0x420404
cmp dword [esi + 0x18], 0x10
lea edi, [esi + 4]
jb 0x42024a
mov eax, dword [edi]
jmp 0x42024c
mov eax, edi
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x420404
mov ebx, dword [ebp + 0x10]
cmp dword [ebx + 0x18], 0x10
jb 0x420269
mov eax, dword [ebx + 4]
jmp 0x42026c
lea eax, [ebx + 4]
cmp dword [esi + 0x18], 0x10
jb 0x420274
mov edi, dword [edi]
push 0
push eax
push edi
call dword [sym.imp.KERNEL32.DLL_CopyFileA]
test eax, eax
je 0x420404
push esi
lea ecx, [ebp - 0x50]
call fcn.0041b74c
push ebx
lea ecx, [ebp - 0x6c]
mov byte [ebp - 4], 3
call fcn.0041b74c
mov edi, str..html
push edi
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 4
call fcn.0041b5d0
mov esi, str..mht
mov byte [ebp - 4], 5
push esi
lea ecx, [ebp - 0xa8]
mov dword [ebp - 0x10], 1
call fcn.0041b5d0
push 3
pop ebx
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0xa8]
push eax
lea eax, [ebp - 0x50]
mov dword [ebp - 4], 6
push eax
mov dword [ebp - 0x10], ebx
call fcn.0044c300
add esp, 0xc
test eax, eax
je 0x420359
cmp dword [ebp - 0x38], 0x10
mov eax, dword [ebp - 0x4c]
jae 0x4202fe
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x420359
push edi
lea ecx, [ebp - 0x8c]
call fcn.0041b5d0
push 7
pop eax
mov dword [ebp - 4], eax
push esi
lea ecx, [ebp - 0xc4]
mov dword [ebp - 0x10], eax
call fcn.0041b5d0
push 0xf
pop ebx
lea eax, [ebp - 0x8c]
push eax
lea eax, [ebp - 0xc4]
push eax
lea eax, [ebp - 0x6c]
mov dword [ebp - 4], 8
push eax
mov dword [ebp - 0x10], ebx
call fcn.0044c300
add esp, 0xc
test eax, eax
mov byte [ebp + 0xf], 1
jne 0x42035d
mov byte [ebp + 0xf], 0
xor esi, esi
test bl, 8
je 0x420375
push esi
push 1
lea ecx, [ebp - 0xc4]
and ebx, 0xfffffff7
call fcn.0041a87c
test bl, 4
je 0x42038b
push esi
push 1
lea ecx, [ebp - 0x8c]
and ebx, 0xfffffffb
call fcn.0041a87c
test bl, 2
je 0x4203a1
push esi
push 1
lea ecx, [ebp - 0xa8]
and ebx, 0xfffffffd
call fcn.0041a87c
test bl, 1
mov dword [ebp - 4], 4
je 0x4203b8
push esi
push 1
lea ecx, [ebp - 0x2c]
call fcn.0041a87c
cmp byte [ebp + 0xf], 0
je 0x4203ea
cmp dword [ebp - 0x54], 0x10
mov ecx, dword [ebp - 0x68]
jae 0x4203ca
lea ecx, [ebp - 0x68]
cmp dword [ebp - 0x38], 0x10
mov eax, dword [ebp - 0x4c]
jae 0x4203d6
lea eax, [ebp - 0x4c]
push esi
push ecx
push eax
call dword [sym.imp.KERNEL32.DLL_CopyFileA]
push dword [ebp + 8]
lea edi, [ebp - 0x6c]
call fcn.00420a62
push esi
push 1
lea ecx, [ebp - 0x6c]
call fcn.0041a87c
push esi
push 1
lea ecx, [ebp - 0x50]
call fcn.0041a87c
mov bl, 1
jmp 0x420406
xor bl, bl
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.DLL_LeaveCriticalSection]
mov al, bl
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 0x10