Function at 0x405980
Capabilities:
Get common file path
Get program files directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x683e6b
mov eax, dword fs:[0]
push eax
sub esp, 0x488
mov eax, dword [0x73d6e0]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x460]
push 0xa
xor eax, eax
mov dword [ebp - 0x450], 0
mov dword [ebp - 0x44c], 0
push str.2345PCSafe
mov dword [ebp - 0x430], ebx
mov dword [ebp - 0x44c], 7
mov dword [ebp - 0x450], 0
mov word [ebp - 0x460], ax
call fcn.00409260
lea esi, [edi + 0x1d4]
mov dword [ebp - 4], 0
lea eax, [ebp - 0x460]
cmp esi, eax
je 0x405a1f
push 0xffffffffffffffff
push 0
push eax
mov ecx, esi
call fcn.00409040
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x44c], 8
jb 0x405a3d
push dword [ebp - 0x460]
call fcn.005472b4
add esp, 4
xor eax, eax
mov dword [ebp - 0x44c], 7
mov ecx, esi
mov dword [ebp - 0x450], 0
mov word [ebp - 0x460], ax
call fcn.00422390
test al, al
je 0x405bbb
lea eax, [ebp - 0x42c]
mov ecx, esi
push eax
call fcn.00422c60
mov ebx, eax
lea esi, [edi + 0x1ec]
mov dword [ebp - 4], 1
cmp esi, ebx
je 0x405ab5
cmp dword [esi + 0x14], 8
jb 0x405a9a
push dword [esi]
call fcn.005472b4
add esp, 4
xor eax, eax
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
mov ecx, esi
push ebx
mov word [esi], ax
call fcn.00408e30
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x418], 8
jb 0x405ad3
push dword [ebp - 0x42c]
call fcn.005472b4
add esp, 4
xor eax, eax
mov dword [ebp - 0x418], 7
mov word [ebp - 0x42c], ax
mov eax, dword [esi + 0x10]
mov dword [ebp - 0x41c], 0
lea ecx, [eax - 1]
cmp eax, ecx
jae 0x405b04
push str.invalid_string_position
call fcn.004ca630
cmp dword [esi + 0x14], 8
mov dword [esi + 0x10], ecx
jb 0x405b11
mov eax, dword [esi]
jmp 0x405b13
mov eax, esi
push 1
xor edx, edx
push ecx
mov word [eax + ecx*2], dx
mov ecx, esi
push 0x6ea1a4
call fcn.004091a0
push eax
push 0
lea eax, [ebp - 0x42c]
mov ecx, esi
push eax
call fcn.00408dc0
mov ebx, eax
mov dword [ebp - 4], 2
cmp esi, ebx
je 0x405b71
cmp dword [esi + 0x14], 8
jb 0x405b56
push dword [esi]
call fcn.005472b4
add esp, 4
xor eax, eax
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
mov ecx, esi
push ebx
mov word [esi], ax
call fcn.00408e30
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x418], 8
jb 0x405d07
push dword [ebp - 0x42c]
call fcn.005472b4
mov ebx, dword [ebp - 0x430]
add esp, 4
xor eax, eax
mov dword [ebp - 0x418], 7
mov dword [ebp - 0x41c], 0
mov word [ebp - 0x42c], ax
jmp 0x405d40
xor eax, eax
push 0x3fe
push eax
mov word [ebp - 0x414], ax
lea eax, [ebp - 0x412]
push eax
call fcn.00549c70
add esp, 0xc
lea eax, [ebp - 0x414]
push 0
push 0x26
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x405d2c
lea eax, [ebp - 0x414]
push eax
lea ecx, [ebp - 0x42c]
call fcn.00408c20
push str.2345Soft2345PCSafe
lea ecx, [ebp - 0x478]
mov dword [ebp - 4], 3
call fcn.00408c20
lea eax, [ebp - 0x478]
mov byte [ebp - 4], 4
push eax
lea eax, [ebp - 0x42c]
push eax
lea eax, [ebp - 0x490]
push eax
call fcn.0041eff0
add esp, 0xc
mov ebx, eax
lea esi, [edi + 0x1ec]
mov byte [ebp - 4], 5
cmp esi, ebx
je 0x405c79
cmp dword [esi + 0x14], 8
jb 0x405c5e
push dword [esi]
call fcn.005472b4
add esp, 4
xor eax, eax
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
mov ecx, esi
push ebx
mov word [esi], ax
call fcn.00408e30
mov byte [ebp - 4], 4
cmp dword [ebp - 0x47c], 8
jb 0x405c94
push dword [ebp - 0x490]
call fcn.005472b4
add esp, 4
xor eax, eax
mov dword [ebp - 0x47c], 7
mov dword [ebp - 0x480], 0
mov word [ebp - 0x490], ax
mov byte [ebp - 4], 3
cmp dword [ebp - 0x464], 8
jb 0x405ccc
push dword [ebp - 0x478]
call fcn.005472b4
add esp, 4
xor eax, eax
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x418], 8
mov dword [ebp - 0x464], 7
mov dword [ebp - 0x468], 0
mov word [ebp - 0x478], ax
jb 0x405d07
push dword [ebp - 0x42c]
call fcn.005472b4
add esp, 4
mov ebx, dword [ebp - 0x430]
xor eax, eax
mov dword [ebp - 0x418], 7
mov dword [ebp - 0x41c], 0
mov word [ebp - 0x42c], ax
jmp 0x405d40
push 0x24
lea esi, [edi + 0x1ec]
push str.C:Program_Files2345Soft2345PCSafe
mov ecx, esi
call fcn.00409260
lea ecx, [edi + 0x204]
cmp ecx, esi
je 0x405d54
push 0xffffffffffffffff
push 0
push esi
call fcn.00409040
push 0xf0
call fcn.00547bd8
mov esi, eax
add esp, 4
mov dword [ebp - 0x430], esi
mov dword [ebp - 4], 6
test esi, esi
je 0x405d8d
push 0xf0
push 0
push esi
call fcn.00549c70
add esp, 0xc
mov ecx, esi
call fcn.00409f70
jmp 0x405d8f
xor eax, eax
mov dword [ebp - 4], 0xffffffff
mov ecx, eax
push edi
mov dword [edi + 0x220], eax
call fcn.0040a170
push ebx
lea ecx, [edi + 0x88]
call fcn.00405ed0
xor eax, eax
mov dword [ebp - 0x438], 0
push eax
mov dword [ebp - 0x434], 0
lea ecx, [ebp - 0x448]
push 0x6ea1a8
mov dword [ebp - 0x434], 7
mov dword [ebp - 0x438], 0
mov word [ebp - 0x448], ax
call fcn.00409260
mov dword [ebp - 4], 7
mov eax, dword [edi + 0x22c]
test eax, eax
je 0x405e0a
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x438], 0
mov dword [edi + 0x22c], 0
jne 0x405e21
xor eax, eax
jmp 0x405e35
cmp dword [ebp - 0x434], 8
lea eax, [ebp - 0x448]
cmovae eax, dword [ebp - 0x448]
push eax
push 0
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [edi + 0x22c], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
lea ecx, [edi + 0x234]
sete al
mov byte [edi + 0x230], al
lea eax, [ebp - 0x448]
cmp ecx, eax
je 0x405e76
push 0xffffffffffffffff
push 0
push eax
call fcn.00409040
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x434], 8
jb 0x405e94
push dword [ebp - 0x448]
call fcn.005472b4
add esp, 4
xor eax, eax
mov dword [ebp - 0x434], 7
mov dword [ebp - 0x438], 0
mov word [ebp - 0x448], ax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.005472b9
mov esp, ebp
pop ebp
ret 4