Function at 0x4157d0
Capabilities:
Check for time delay via gettickcount
Check if file exists
Create directory
Delete directory
Delete file
Get common file path

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x84744
call fcn.0040c3c0
mov eax, dword [0x420088]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x83e68], 0
mov dword [ebp - 0x83e6c], 0
lea ecx, [ebp - 0x84310]
call fcn.00412a60
mov dword [ebp - 0x83e54], 1
mov dword [ebp - 0x83e60], 0
push 0
call dword [sym.imp.ole32.dll_CoInitialize]
mov eax, dword [ebp + 8]
mov dword [0x422328], eax
lea ecx, [ebp - 0xe50]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea edx, [ebp - 0xe50]
push edx
call fcn.0040112a
add esp, 4
mov dword [ebp - 0xc44], eax
cmp dword [ebp - 0xc44], 0
je 0x41588f
mov eax, dword [ebp - 0xc44]
movzx ecx, word [ebp + eax*2 - 0xe52]
cmp ecx, 0x5c
je 0x41588f
mov edx, 0x5c
mov eax, dword [ebp - 0xc44]
mov word [ebp + eax*2 - 0xe50], dx
mov ecx, dword [ebp - 0xc44]
add ecx, 1
mov dword [ebp - 0xc44], ecx
xor edx, edx
mov eax, dword [ebp - 0xc44]
mov word [ebp + eax*2 - 0xe50], dx
push 1
push 0
push 0
mov ecx, dword [ebp + 8]
push ecx
lea ecx, [ebp - 0x84310]
call fcn.00412b20
lea edx, [ebp - 0x214]
push edx
push str..mdata
lea ecx, [ebp - 0x84310]
call fcn.00412880
mov dword [ebp - 0xc48], eax
cmp dword [ebp - 0xc48], 0
jne 0x4158fa
push 0
push 0x69
push 0xd
call fcn.00415190
add esp, 0xc
lea eax, [ebp - 0xe50]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x415d37
mov ecx, dword [ebp - 0xc48]
mov edx, dword [ecx + 0x10]
mov dword [ebp - 0x83e58], edx
mov eax, dword [ebp - 0x214]
mov dword [ebp - 0x83e64], eax
push 1
mov ecx, dword [ebp - 0x83e64]
mov edx, dword [ecx + 0x10]
push edx
mov eax, dword [ebp - 0x214]
add eax, 0x120
push eax
mov ecx, 0x42232c
call fcn.004143c0
mov ecx, dword [ebp - 0x83e64]
movzx edx, byte [ecx + 0x14]
test edx, edx
je 0x415a1c
lea eax, [ebp - 0x210]
push eax
push 0
push 0x41de48
lea ecx, [ebp - 0xe50]
push ecx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x415980
push 0
push 0x68
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00415190
add esp, 0xc
jmp 0x415d37
lea edx, [ebp - 0x210]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea eax, [ebp - 0x210]
push eax
push 0x104
lea ecx, [ebp - 0xe50]
push ecx
call fcn.004012ab
add esp, 0xc
push 0x41de50
push 0x104
lea edx, [ebp - 0xe50]
push edx
call fcn.0040131a
add esp, 0xc
push 0
lea eax, [ebp - 0xe50]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea ecx, [ebp - 0xc40]
push ecx
mov edx, dword [ebp - 0x83e58]
push edx
mov eax, dword [ebp - 0x83e6c]
push eax
mov ecx, dword [ebp - 0x83e64]
push ecx
lea edx, [ebp - 0xe50]
push edx
call fcn.004154c0
add esp, 0x14
mov dword [ebp - 0x83e60], eax
cmp dword [ebp - 0x83e60], 0
jne 0x415a17
lea eax, [ebp - 0xe50]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x415ab4
lea ecx, [ebp - 0x84740]
call fcn.00415e00
mov ecx, dword [ebp - 0x83e64]
mov dword [ebp - 0x84524], ecx
mov edx, dword [ebp - 0xc48]
mov eax, dword [edx + 0x10]
mov dword [ebp - 0x84520], eax
mov dword [ebp - 0x84740], 0x42232c
lea ecx, [ebp - 0x84740]
call fcn.00416540
cmp eax, 1
je 0x415a6c
lea ecx, [ebp - 0x84740]
call fcn.00415df0
jmp 0x415d37
mov ecx, dword [ebp - 0x84530]
mov dword [ebp - 0x83e54], ecx
mov edx, dword [ebp - 0x84534]
mov dword [ebp - 0x83e6c], edx
lea eax, [ebp - 0x8451c]
push eax
push 0x104
lea ecx, [ebp - 0xc40]
push ecx
call fcn.004012ab
add esp, 0xc
mov dword [ebp - 0x83e60], 1
lea ecx, [ebp - 0x84740]
call fcn.00415df0
cmp dword [ebp - 0x83e60], 0
je 0x415bca
cmp dword [ebp - 0x83e54], 0
jne 0x415adc
mov edx, dword [ebp - 0x83e64]
movzx eax, byte [edx + 0x14]
test eax, eax
je 0x415bca
mov ecx, 0x2f
mov word [ebp - 0xa38], cx
mov edx, 0x70
mov word [ebp - 0xa36], dx
mov eax, 0x22
mov word [ebp - 0xa34], ax
xor ecx, ecx
mov word [ebp - 0xa32], cx
push 0x101
lea edx, [ebp - 0xa32]
push edx
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea ecx, [ebp - 0xa38]
push ecx
call fcn.0040112a
add esp, 4
mov dword [ebp - 0xc44], eax
mov edx, 0x22
mov eax, dword [ebp - 0xc44]
mov word [ebp + eax*2 - 0xa38], dx
xor ecx, ecx
mov edx, dword [ebp - 0xc44]
mov word [ebp + edx*2 - 0xa36], cx
push 0x41de54
push 0x410
lea eax, [ebp - 0xa38]
push eax
call fcn.0040131a
add esp, 0xc
mov ecx, dword [ebp + 0x10]
push ecx
push 0x410
lea edx, [ebp - 0xa38]
push edx
call fcn.0040131a
add esp, 0xc
push 2
push 5
lea eax, [ebp - 0xe50]
push eax
lea ecx, [ebp - 0xa38]
push ecx
lea edx, [ebp - 0xc40]
push edx
push 0x41de58
call fcn.00414fe0
add esp, 0x18
test eax, eax
jne 0x415bca
push 0
push 0x6b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00415190
add esp, 0xc
jmp 0x415d37
mov eax, dword [ebp - 0x83e64]
movzx ecx, byte [eax + 0x14]
test ecx, ecx
je 0x415d2d
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x83e70], eax
mov edx, 1
test edx, edx
je 0x415cec
mov dword [ebp - 0x83e5c], 0
mov dword [ebp - 0xc44], 0
jmp 0x415c1a
mov eax, dword [ebp - 0xc44]
add eax, 1
mov dword [ebp - 0xc44], eax
mov ecx, dword [ebp - 0x83e64]
mov edx, dword [ebp - 0xc44]
cmp edx, dword [ecx + 4]
jae 0x415cc7
mov eax, dword [ebp - 0xc44]
imul eax, eax, 0x20c
movzx ecx, word [ebp + eax - 0x83e50]
test ecx, ecx
je 0x415c5d
mov edx, dword [ebp - 0xc44]
imul edx, edx, 0x20c
cmp dword [ebp + edx - 0x83c48], 1
jne 0x415c5f
jmp 0x415c0b
mov eax, dword [ebp - 0xc44]
imul eax, eax, 0x20c
lea ecx, [ebp + eax - 0x83e50]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x415cc2
mov edx, dword [ebp - 0xc44]
imul edx, edx, 0x20c
lea eax, [ebp + edx - 0x83e50]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x415cb3
mov ecx, dword [ebp - 0xc44]
imul ecx, ecx, 0x20c
xor edx, edx
mov word [ebp + ecx - 0x83e50], dx
jmp 0x415cc2
mov eax, dword [ebp - 0x83e5c]
add eax, 1
mov dword [ebp - 0x83e5c], eax
jmp 0x415c0b
cmp dword [ebp - 0x83e5c], 0
jne 0x415cd2
jmp 0x415cec
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebp - 0x83e70]
cmp eax, 0xbb8
jbe 0x415ce7
jmp 0x415cec
jmp 0x415be8
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp - 0x83e70], eax
mov ecx, 1
test ecx, ecx
je 0x415d2d
lea edx, [ebp - 0xe50]
push edx
call fcn.00414da0
add esp, 4
test eax, eax
je 0x415d16
jmp 0x415d2d
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebp - 0x83e70]
cmp eax, 0xbb8
jbe 0x415d2b
jmp 0x415d2d
jmp 0x415cf8
mov dword [ebp - 0x83e68], 1
call dword [sym.imp.ole32.dll_CoFreeUnusedLibraries]
call dword [sym.imp.ole32.dll_CoUninitialize]
mov eax, dword [ebp - 0x83e68]
mov dword [ebp - 0x84744], eax
lea ecx, [ebp - 0x84310]
call fcn.00412a40
mov eax, dword [ebp - 0x84744]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040109c
mov esp, ebp
pop ebp
ret 0x10