Function at 0x405d0d
Capabilities:
Check if file exists
Create process on windows
Delete directory
Delete file
Get common file path
Get comspec environment variable
Get file attributes
Move file
Query environment variable
Self delete
Set current directory
Set file attributes

Disassembly:
push ebp
lea ebp, [esp - 0x9d78]
mov eax, 0x9df8
call fcn.00406ce0
mov eax, dword [0x4181b0]
xor eax, ebp
mov dword [ebp + 0x9d74], eax
push ebx
push edi
mov edi, 0x800
push edi
lea eax, [ebp + 0x77e4]
push eax
xor ebx, ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp + 0x77e4]
push eax
lea eax, [ebp + 0x67e4]
push eax
call fcn.00406d39
lea eax, [ebp + 0x67e4]
push 0x5c
push eax
call fcn.004077ae
add esp, 0x10
cmp eax, ebx
je 0x40625a
lea ecx, [ebp + 0x67e4]
cmp eax, ecx
jbe 0x405d89
cmp word [eax - 2], 0x3a
jne 0x405d89
xor ecx, ecx
mov word [eax + 2], cx
jmp 0x405d8e
xor ecx, ecx
mov word [eax], cx
push esi
lea eax, [ebp + 0x67e4]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push edi
lea eax, [ebp + 0x67e4]
push eax
call fcn.00403c74
mov esi, 0x13f2
cmp byte [0x41e328], bl
jne 0x405ddd
push 0x10024
push esi
call fcn.004052d5
push eax
push 0x13f5
call fcn.004052d5
push eax
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
cmp eax, 6
jne 0x406259
push 0x41498c
push str.Uninstall.lst
call fcn.00401a46
mov dword [ebp - 0x2c], eax
cmp eax, ebx
jne 0x405e36
push str.Uninstall.lst
push 0x13f6
call fcn.004052d5
push eax
lea eax, [ebp + 0x9be4]
push 0xc8
push eax
call fcn.00402453
add esp, 0x10
push 0x10010
push esi
call fcn.004052d5
push eax
lea eax, [ebp + 0x9be4]
push eax
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
jmp 0x406259
push 0x100
push 0x13fc
call fcn.004052d5
push eax
lea eax, [ebp + 0x99e4]
push eax
call fcn.004054a0
push 0x100
push esi
call fcn.004052d5
push eax
lea eax, [ebp + 0x97e4]
push eax
call fcn.004054a0
call fcn.00405a01
mov ecx, 0x41b1e0
call fcn.004051a0
cmp byte [0x41e329], bl
jne 0x406259
mov dword [ebp - 0x28], ebx
mov esi, dword [ebp - 0x28]
push ebx
lea esi, [esi + 0x418188]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
add dword [ebp - 0x28], 4
cmp dword [ebp - 0x28], 8
jb 0x405e88
mov byte [ebp - 0x21], bl
push dword [ebp - 0x2c]
lea eax, [ebp + 0x8fe4]
push edi
push eax
mov dword [ebp - 0x28], ebx
call fcn.00408c27
add esp, 0xc
test eax, eax
je 0x406095
lea eax, [ebp + 0x8fe4]
push eax
call fcn.00407c20
pop ecx
mov esi, eax
jmp 0x405ef9
lea ecx, [ebp + esi + 0x8fe4]
mov al, byte [ecx]
cmp al, 0xd
je 0x405ef7
cmp al, 0xa
je 0x405ef7
cmp al, 0x20
je 0x405ef7
cmp al, 9
jne 0x405efc
mov byte [ecx], bl
dec esi
jns 0x405ede
cmp byte [ebp + 0x8fe4], bl
je 0x406063
lea eax, [ebp + 0x67e4]
push eax
lea eax, [ebp + 0x37e4]
push eax
call fcn.00406d39
lea eax, [ebp + 0x37e4]
push eax
call fcn.0040747a
add esp, 0xc
mov ecx, 0x1000
sub ecx, eax
push ecx
lea eax, [ebp + eax*2 + 0x37e4]
push eax
lea eax, [ebp + 0x8fe4]
push eax
call fcn.004055dc
mov esi, dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
lea eax, [ebp + 0x37e4]
push eax
call esi
mov dword [ebp - 0x20], eax
push ebx
lea eax, [ebp + 0x37e4]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
cmp dword [ebp - 0x20], 0xffffffff
je 0x405f87
test byte [ebp - 0x20], 0x10
je 0x405f87
lea eax, [ebp + 0x37e4]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
add dword [ebp - 0x28], eax
jmp 0x406063
lea eax, [ebp + 0x37e4]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
add dword [ebp - 0x28], eax
cmp eax, ebx
jne 0x406063
cmp dword [ebp - 0x20], 0xffffffff
je 0x406063
lea eax, [ebp + 0x37e4]
push eax
call fcn.00403d42
mov dword [ebp - 0x20], eax
lea eax, [ebp + 0x77e4]
push eax
call fcn.00403d42
push eax
push dword [ebp - 0x20]
call fcn.00405617
test eax, eax
je 0x406063
push str.Uninstall.lst
push dword [ebp - 0x20]
call fcn.00405617
test eax, eax
je 0x406063
mov byte [ebp - 0x21], 1
mov dword [ebp - 0x20], ebx
push dword [ebp - 0x20]
lea eax, [ebp + 0x37e4]
push eax
push str._s._d.tmp
lea eax, [ebp + 0x57e4]
push edi
push eax
call fcn.00402453
add esp, 0x14
lea eax, [ebp + 0x57e4]
push eax
call esi
cmp eax, 0xffffffff
je 0x406026
inc dword [ebp - 0x20]
cmp dword [ebp - 0x20], 0x3e8
jl 0x405fed
lea eax, [ebp + 0x57e4]
push eax
lea eax, [ebp + 0x37e4]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
jne 0x406053
lea eax, [ebp + 0x37e4]
push eax
lea eax, [ebp + 0x57e4]
push eax
call fcn.00406d39
pop ecx
pop ecx
push 4
push ebx
lea eax, [ebp + 0x57e4]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
push dword [ebp - 0x2c]
lea eax, [ebp + 0x8fe4]
push edi
push eax
call fcn.00408c27
add esp, 0xc
test eax, eax
jne 0x405ecd
cmp dword [ebp - 0x28], ebx
je 0x406095
push ebx
push ebx
push dword [ebp - 0x2c]
call fcn.00408ba2
add esp, 0xc
jmp 0x405eaf
push dword [ebp - 0x2c]
call fcn.0040750b
mov dword [esp], str.Uninstall.lst
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp byte [ebp - 0x21], bl
je 0x4060d1
cmp byte [0x41e328], bl
jne 0x4060d1
push 0x10040
lea eax, [ebp + 0x97e4]
push eax
lea eax, [ebp + 0x99e4]
push eax
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
lea eax, [ebp + 0x27e4]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea eax, [ebp + 0x27e4]
push str.Uninstall_Rar.Bat
push eax
call fcn.00406d0b
pop ecx
pop ecx
push 0x413e94
lea eax, [ebp + 0x27e4]
push eax
call fcn.00401a46
mov dword [ebp - 0x2c], eax
cmp eax, ebx
je 0x406259
lea eax, [ebp + 0x77e4]
push eax
push str.__s___wait_r_n
mov esi, 0x400
lea eax, [ebp + 0x87e4]
push esi
push eax
call fcn.00402453
add esp, 0x10
lea eax, [ebp + 0x87e4]
push eax
push dword [ebp - 0x2c]
call fcn.004059b4
lea eax, [ebp - 0x1c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea eax, [ebp + 0x77e4]
push eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp + 0x77e4]
push eax
push str.del___s__r_nrd___s__r_nif_not_exist___s__goto_done_r_n
lea eax, [ebp + 0x87e4]
push esi
push eax
call fcn.00402453
add esp, 0x18
mov dword [ebp - 0x20], 5
lea eax, [ebp + 0x87e4]
push eax
push dword [ebp - 0x2c]
call fcn.004059b4
dec dword [ebp - 0x20]
jne 0x406177
lea eax, [ebp + 0x27e4]
push eax
lea eax, [ebp + 0x77e4]
push eax
push eax
push str.:done_r_nif_exist___s____s___warning_r_ndel___s_
lea eax, [ebp + 0x87e4]
push esi
push eax
call fcn.00402453
add esp, 0x18
lea eax, [ebp + 0x87e4]
push eax
push dword [ebp - 0x2c]
call fcn.004059b4
push dword [ebp - 0x2c]
call fcn.0040750b
pop ecx
xor eax, eax
mov word [ebp + 0xfe4], ax
push edi
lea eax, [ebp + 0xfe4]
push eax
push str.COMSPEC
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
lea eax, [ebp + 0x27e4]
push eax
lea eax, [ebp + 0xfe4]
push eax
push str._s__c___s_
lea eax, [ebp + 0x1fe4]
push esi
push eax
call fcn.00402453
push 0x44
pop esi
push esi
lea eax, [ebp - 0x70]
push ebx
push eax
call fcn.00407400
mov dword [ebp - 0x70], esi
add esp, 0x20
xor esi, esi
xor eax, eax
inc esi
push 0x413358
mov dword [ebp - 0x44], esi
mov word [ebp - 0x40], ax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp - 0x70]
push eax
push ebx
push ebx
call fcn.00403bda
neg eax
sbb eax, eax
and eax, 0xfffffff8
add eax, 8
push eax
push esi
push ebx
push ebx
lea eax, [ebp + 0x1fe4]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
pop esi
mov ecx, dword [ebp + 0x9d74]
pop edi
xor ecx, ebp
pop ebx
call fcn.00406ccd
add ebp, 0x9d78
leave
ret