Function at 0x513980
Capabilities:
Read .ini file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5ac821
mov eax, dword fs:[0]
push eax
sub esp, 0x4a4
mov eax, dword [0x608554]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
push ecx
push str.CBaseOSSpecTypeWin2K::PSReboot
lea ecx, [ebp - 0x498]
call fcn.0040a480
mov dword [ebp - 4], 0
mov ecx, dword [0x608f30]
cmp ecx, 0x608f30
je 0x513a0b
test byte [ecx + 0x1c], 1
je 0x513a0b
cmp dword [0x608f68], 8
mov eax, 0x608f54
mov edx, 0x5dd3a8
cmovae eax, dword [0x608f54]
push eax
push dword [ecx + 0x14]
push dword [ecx + 0x10]
mov ecx, 0x10d
call fcn.00401840
add esp, 0xc
push esi
lea ecx, [ebp - 0x4a0]
call fcn.00403320
push 0x40
lea eax, [ebp - 0x50]
mov byte [ebp - 4], 1
push 0
push eax
call fcn.00571c00
push 0x208
lea eax, [ebp - 0x258]
push 0
push eax
call fcn.00571c00
push 0x208
lea eax, [ebp - 0x460]
push 0
push eax
call fcn.00571c00
add esp, 0x24
lea ecx, [ebp - 0x49c]
call fcn.0046a2f0
mov byte [ebp - 4], 2
mov ecx, dword [0x608f30]
cmp ecx, 0x608f30
je 0x513aa0
test byte [ecx + 0x1c], 4
je 0x513aa0
cmp dword [0x608f68], 8
mov eax, 0x608f54
mov edx, 0x5dd3a8
cmovae eax, dword [0x608f54]
push eax
push dword [ecx + 0x14]
push dword [ecx + 0x10]
mov ecx, 0x10e
call fcn.00401840
add esp, 0xc
mov ecx, dword [0x6184f0]
lea eax, [ebp - 0x258]
push eax
push str.TEMPPATH
mov ecx, dword [ecx + 0x1c]
call fcn.004f65f0
lea eax, [ebp - 0x258]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatW]
cmp word [ebp + eax*2 - 0x25a], 0x5c
je 0x513ae6
push 0x5c692c
lea eax, [ebp - 0x258]
push eax
call esi
push str.InsDrv.ini
lea eax, [ebp - 0x258]
push eax
call esi
lea eax, [ebp - 0x258]
push eax
push 0x104
lea eax, [ebp - 0x460]
push eax
push 0x5c6930
push str.Version
push str.PSRebootVersion
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
cmp word [ebp - 0x460], 0
jne 0x513b38
push str.2.30
lea eax, [ebp - 0x460]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
push 0
lea eax, [ebp - 0x50]
push eax
push edi
lea ecx, [ebp - 0x49c]
call fcn.0046d300
mov ecx, dword [0x608f30]
cmp ecx, 0x608f30
je 0x513be0
test byte [ecx + 0x1c], 4
je 0x513ba5
cmp dword [0x608f68], 8
lea edx, [ebp - 0x50]
push edx
lea edx, [ebp - 0x460]
mov eax, 0x608f54
cmovae eax, dword [0x608f54]
push edx
push dword [ebp - 0x4a0]
mov edx, 0x5dd3a8
push eax
push dword [ecx + 0x14]
push dword [ecx + 0x10]
mov ecx, 0x10f
call fcn.0040c1c0
mov ecx, dword [0x608f30]
add esp, 0x18
cmp ecx, 0x608f30
je 0x513be0
test byte [ecx + 0x1c], 4
je 0x513be0
cmp dword [0x608f68], 8
mov eax, 0x608f54
push edi
cmovae eax, dword [0x608f54]
mov edx, 0x5dd3a8
push eax
push dword [ecx + 0x14]
push dword [ecx + 0x10]
mov ecx, 0x110
call fcn.00405920
add esp, 0x10
lea eax, [ebp - 0x50]
push eax
call fcn.00582d08
lea eax, [ebp - 0x460]
fstp qword [ebp - 0x4b0]
push eax
call fcn.00582d08
fstp qword [ebp - 0x4a8]
movsd xmm0, qword [ebp - 0x4a8]
add esp, 8
comisd xmm0, xmmword [ebp - 0x4b0]
jb 0x513c6e
mov ecx, dword [0x608f30]
cmp ecx, 0x608f30
je 0x513c56
test byte [ecx + 0x1c], 4
je 0x513c56
cmp dword [0x608f68], 8
mov eax, 0x608f54
mov edx, 0x5dd3a8
cmovae eax, dword [0x608f54]
push eax
push dword [ecx + 0x14]
push dword [ecx + 0x10]
mov ecx, 0x111
call fcn.00401840
add esp, 0xc
mov ecx, dword [0x6184f0]
push 0x5ca984
push str.PSPCLREBOOT
mov ecx, dword [ecx + 0x1c]
call fcn.004f6860
mov byte [ebp - 0x494], 1
mov ecx, dword [0x608f30]
cmp ecx, 0x608f30
je 0x513cb7
test byte [ecx + 0x1c], 1
je 0x513cb7
cmp dword [0x608f68], 8
mov eax, 0x608f54
push 1
cmovae eax, dword [0x608f54]
mov edx, 0x5dd3a8
push eax
push dword [ecx + 0x14]
push dword [ecx + 0x10]
mov ecx, 0x112
call fcn.004018a0
add esp, 0x10
lea ecx, [ebp - 0x49c]
call fcn.0046a3c0
mov byte [ebp - 4], 0
or eax, 0xffffffff
mov edx, dword [ebp - 0x4a0]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x513ce4
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea ecx, [ebp - 0x498]
call fcn.0040a570
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0056d977
mov esp, ebp
pop ebp
ret 8