Function at 0x10501ee
Capabilities:
Delete file

Disassembly:
mov eax, 0x1098a8b
call fcn.01077478
sub esp, 0x43c
mov eax, dword [0x10a64dc]
push ebx
mov dword [ebp - 0x10], eax
mov eax, dword [0x10a6184]
cmp eax, 0x10a6184
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x428], ecx
je 0x1050248
test byte [eax + 0x1c], 1
je 0x1050248
cmp byte [eax + 0x19], 5
jb 0x1050248
push esi
push edi
push dword [ebp + 8]
push ecx
push 0x100672c
push 0x176
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0106ae69
xor ebx, ebx
push 0x10a8b2c
lea ecx, [ebp - 0x430]
mov dword [ebp - 0x42c], ebx
call fcn.01020db5
mov eax, dword [ebp + 8]
sub eax, ebx
mov dword [ebp - 4], ebx
je 0x10506ec
dec eax
je 0x10505fb
dec eax
je 0x1050540
dec eax
je 0x10503e8
dec eax
je 0x10503be
dec eax
je 0x10503aa
dec eax
je 0x10502a3
mov dword [ebp - 0x42c], 0x80070057
jmp 0x10508cb
cmp edi, ebx
je 0x10508cb
cmp esi, ebx
je 0x10508cb
push 0x10a8b2c
lea ecx, [ebp - 0x424]
call fcn.01020db5
mov eax, dword [esi]
cmp eax, ebx
mov byte [ebp - 4], 2
jl 0x10502e5
lea eax, [ebp - 0x424]
push 0x1006b54
push eax
call fcn.0100d972
pop ecx
pop ecx
jmp 0x1050380
push ebx
push ebx
lea ecx, [ebp - 0x420]
push ecx
push ebx
and eax, 0xffff
push eax
push ebx
push 0x1100
mov dword [ebp - 0x420], ebx
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
test eax, eax
je 0x105036a
cmp dword [ebp - 0x420], ebx
je 0x105036a
push dword [ebp - 0x420]
call dword [sym.imp.msvcrt.dll_wcslen]
cmp eax, 2
pop ecx
jb 0x1050340
mov edx, dword [ebp - 0x420]
lea ecx, [edx + eax*2 - 4]
cmp word [ecx], 0xd
jne 0x1050340
cmp word [edx + eax*2 - 2], 0xa
jne 0x1050340
mov word [ecx], bx
push dword [ebp - 0x420]
lea eax, [ebp - 0x424]
push dword [esi]
push 0x1006b24
push eax
call fcn.0100d972
add esp, 0x10
push dword [ebp - 0x420]
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x1050380
push dword [esi]
lea eax, [ebp - 0x424]
push 0x1006afc
push eax
call fcn.0100d972
add esp, 0xc
mov esi, dword [ebp - 0x424]
push esi
push dword [edi]
push 0x1006a80
lea eax, [ebp - 0x430]
push eax
call fcn.0100d972
add esp, 0x10
lea ecx, [esi - 0x10]
call fcn.01009cd1
jmp 0x105070a
cmp edi, ebx
je 0x10508cb
push dword [edi]
push 0x1006a08
jmp 0x10506fb
mov esi, dword [ebp - 0x428]
add esi, 0x178
mov eax, dword [esi]
cmp dword [eax - 0xc], ebx
je 0x10508cb
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ecx, esi
call fcn.01009f04
jmp 0x10508cb
mov esi, dword [ebp - 0x428]
add esi, 0x178
mov eax, dword [esi]
mov eax, dword [eax - 0xc]
cmp eax, ebx
jne 0x1050494
push 0x104
lea eax, [ebp - 0x41c]
push eax
call fcn.01024507
cmp eax, ebx
jne 0x105043e
lea eax, [ebp - 0x41c]
push eax
mov ecx, esi
call fcn.0100a804
push 0x10050e4
mov ecx, esi
call fcn.0100a88e
push 0x10069dc
mov ecx, esi
call fcn.0100a88e
jmp 0x1050494
push eax
call fcn.01009676
mov dword [ebp - 0x42c], eax
mov eax, dword [0x10a6184]
cmp eax, 0x10a6184
je 0x1050488
test byte [eax + 0x1c], 0x10
je 0x1050488
cmp byte [eax + 0x19], 2
jb 0x1050488
push dword [ebp - 0x42c]
push dword [ebp - 0x428]
push 0x100672c
push 0x177
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0100ef6e
mov eax, dword [0x10a6184]
cmp dword [ebp - 0x42c], ebx
jl 0x10508d0
mov eax, dword [esi]
push ebx
push 0x80
push 2
push ebx
push 1
push 0x20006
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
jne 0x1050509
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.01009676
mov dword [ebp - 0x42c], eax
mov eax, dword [0x10a6184]
cmp eax, 0x10a6184
je 0x1050500
test byte [eax + 0x1c], 0x10
je 0x1050500
cmp byte [eax + 0x19], 2
jb 0x1050500
push dword [ebp - 0x42c]
mov ecx, dword [esi]
push ecx
push dword [ebp - 0x428]
push 0x100672c
push 0x178
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.0102eef0
mov ecx, esi
call fcn.01009f04
jmp 0x1050510
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x42c], ebx
jl 0x10508cb
mov ecx, dword [0x10a7cf4]
cmp ecx, ebx
je 0x10508cb
mov esi, dword [esi]
push ebx
push ebx
push esi
push 0x400d377c
push 4
call fcn.0100d481
jmp 0x10508cb
cmp edi, ebx
je 0x10508cb
cmp esi, ebx
je 0x10508cb
push ebx
push ebx
lea eax, [ebp - 0x420]
push eax
mov eax, dword [esi]
push ebx
and eax, 0xffff
push eax
push ebx
push 0x1100
mov dword [ebp - 0x420], ebx
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
test eax, eax
je 0x10505dd
cmp dword [ebp - 0x420], ebx
je 0x10505dd
push dword [ebp - 0x420]
call dword [sym.imp.msvcrt.dll_wcslen]
cmp eax, 2
pop ecx
jb 0x10505ad
mov edx, dword [ebp - 0x420]
lea ecx, [edx + eax*2 - 4]
cmp word [ecx], 0xd
jne 0x10505ad
cmp word [edx + eax*2 - 2], 0xa
jne 0x10505ad
mov word [ecx], bx
push dword [ebp - 0x420]
mov eax, dword [edi]
push dword [esi]
push eax
lea eax, [ebp - 0x430]
push 0x1006988
push eax
call fcn.0100d972
add esp, 0x14
push dword [ebp - 0x420]
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x105070a
push dword [esi]
mov eax, dword [edi]
push eax
lea eax, [ebp - 0x430]
push 0x1006938
push eax
call fcn.0100d972
add esp, 0x10
jmp 0x105070a
cmp edi, ebx
je 0x10508cb
cmp esi, ebx
je 0x10508cb
push 0x10a8b2c
lea ecx, [ebp - 0x424]
call fcn.01020db5
mov eax, dword [esi]
cmp eax, ebx
mov byte [ebp - 4], 1
jl 0x105063d
lea eax, [ebp - 0x424]
push 0x1006b54
push eax
call fcn.0100d972
pop ecx
pop ecx
jmp 0x10506d8
push ebx
push ebx
lea ecx, [ebp - 0x420]
push ecx
push ebx
and eax, 0xffff
push eax
push ebx
push 0x1100
mov dword [ebp - 0x420], ebx
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
test eax, eax
je 0x10506c2
cmp dword [ebp - 0x420], ebx
je 0x10506c2
push dword [ebp - 0x420]
call dword [sym.imp.msvcrt.dll_wcslen]
cmp eax, 2
pop ecx
jb 0x1050698
mov edx, dword [ebp - 0x420]
lea ecx, [edx + eax*2 - 4]
cmp word [ecx], 0xd
jne 0x1050698
cmp word [edx + eax*2 - 2], 0xa
jne 0x1050698
mov word [ecx], bx
push dword [ebp - 0x420]
lea eax, [ebp - 0x424]
push dword [esi]
push 0x1006b24
push eax
call fcn.0100d972
add esp, 0x10
push dword [ebp - 0x420]
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x10506d8
push dword [esi]
lea eax, [ebp - 0x424]
push 0x1006afc
push eax
call fcn.0100d972
add esp, 0xc
mov esi, dword [ebp - 0x424]
mov eax, dword [edi]
push esi
push eax
push 0x10068e8
jmp 0x105038e
cmp edi, ebx
je 0x10508cb
push dword [edi]
push 0x10068a0
lea eax, [ebp - 0x430]
push eax
call fcn.0100d972
add esp, 0xc
push 0x10a8b2c
lea ecx, [ebp - 0x420]
call fcn.01020db5
mov esi, dword [ebp - 0x428]
mov eax, dword [esi + 0x178]
cmp dword [eax - 0xc], ebx
mov byte [ebp - 4], 3
jne 0x105073a
push ebx
push ebx
push 3
mov ecx, esi
call fcn.010501ee
mov eax, dword [esi + 0x178]
cmp dword [eax - 0xc], ebx
mov edi, dword [ebp - 0x430]
je 0x10507e3
cmp dword [edi - 0xc], ebx
je 0x10507e3
lea eax, [ebp - 0x448]
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
push 0x7f
lea eax, [ebp - 0x210]
push eax
push 0x1006788
lea eax, [ebp - 0x448]
push eax
push ebx
mov esi, 0x800
push esi
call dword [sym.imp.KERNEL32.dll_GetDateFormatW]
test eax, eax
jne 0x1050792
mov word [ebp - 0x210], bx
push 0x7f
lea eax, [ebp - 0x110]
push eax
push 0x1006890
lea eax, [ebp - 0x448]
push eax
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GetTimeFormatW]
test eax, eax
jne 0x10507ba
mov word [ebp - 0x110], bx
push edi
lea eax, [ebp - 0x110]
push eax
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x420]
push 0x1006870
push eax
call fcn.0100d972
mov esi, dword [ebp - 0x428]
add esp, 0x14
mov eax, dword [ebp - 0x420]
cmp dword [eax - 0xc], ebx
je 0x10508bd
mov eax, dword [esi + 0x178]
push 0x1006868
push eax
call dword [sym.imp.msvcrt.dll__wfopen]
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 0x434], eax
je 0x10508bd
mov esi, dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push ebx
push ebx
push ebx
push ebx
push 0xffffffffffffffff
push dword [ebp - 0x420]
mov edi, 0xfde9
push ebx
push edi
call esi
cmp eax, ebx
mov dword [ebp - 0x424], eax
jle 0x10508b0
push 0x10a8b2c
lea ecx, [ebp - 0x428]
call fcn.01020db5
mov eax, dword [ebp - 0x424]
inc eax
push eax
lea ecx, [ebp - 0x428]
mov byte [ebp - 4], 4
mov dword [ebp - 0x438], eax
call fcn.010213b2
cmp eax, ebx
mov dword [ebp - 0x424], eax
je 0x10508a2
push ebx
push ebx
push dword [ebp - 0x438]
push eax
push 0xffffffffffffffff
push dword [ebp - 0x420]
push ebx
push edi
call esi
dec eax
cmp eax, ebx
jle 0x10508a2
push dword [ebp - 0x434]
push 1
push eax
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll_fwrite]
add esp, 0x10
mov ecx, dword [ebp - 0x428]
add ecx, 0xfffffff0
call fcn.01009cd1
push dword [ebp - 0x434]
call dword [sym.imp.msvcrt.dll_fclose]
pop ecx
mov ecx, dword [ebp - 0x420]
add ecx, 0xfffffff0
call fcn.01009cd1
mov eax, dword [0x10a6184]
cmp eax, 0x10a6184
je 0x1050911
test byte [eax + 0x1c], 1
je 0x1050911
movzx ecx, byte [eax + 0x19]
xor edx, edx
cmp dword [ebp - 0x42c], ebx
setl dl
dec edx
and edx, 3
inc edx
inc edx
cmp ecx, edx
jl 0x1050911
push dword [ebp - 0x42c]
push 0x100672c
push 0x179
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01009b3f
mov ecx, dword [ebp - 0x430]
add ecx, 0xfffffff0
call fcn.01009cd1
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
mov ecx, dword [ebp - 0x10]
pop ebx
call fcn.01076f63
leave
ret 0xc