Function at 0x402880
Capabilities:
Shutdown system

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov eax, dword [0x5c7004]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push str.EnableWarnings
mov esi, edx
mov ebx, ecx
mov edi, 0xc0000001
call sym.ProcessHacker.exe_PhGetIntegerSetting
test eax, eax
je 0x4028c8
push 0
push 0
push str.the_computer
push str.restart
push ebx
call sym.ProcessHacker.exe_PhShowConfirmMessage
mov edi, edi
test al, al
je 0x402b37
call fcn.004de2c0
mov dword [ebp - 0x1c], eax
test eax, eax
je 0x402ac9
jmp 0x4028e0
cmp esi, dword [eax]
jae 0x402a02
lfence
mov eax, dword [eax + 8]
mov eax, dword [eax + esi*4]
mov ecx, dword [eax]
mov dword [ebp - 0x28], ecx
mov ecx, dword [eax + 4]
mov dword [ebp - 0x2c], ecx
mov ecx, dword [eax + 8]
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x34], eax
call fcn.004dd6a0
test al, al
je 0x402a83
mov esi, dword [0x5cf1f4]
lea eax, [ebp - 0x20]
push eax
mov ecx, esi
call dword [0x55890c]
call esi
mov edi, eax
test edi, edi
js 0x402a83
mov edi, dword [ebp - 0x20]
mov dword [ebp - 0x18], edi
call fcn.004dd6a0
mov edi, edi
test al, al
jne 0x40294e
mov edi, 0xc0000001
jmp 0x4029de
mov esi, dword [0x5cf1fc]
lea eax, [ebp - 0x24]
push eax
push 0x5c78c0
push edi
mov ecx, esi
call dword [0x55890c]
call esi
mov edi, eax
test edi, edi
js 0x4029de
mov eax, dword [ebp - 0x28]
mov esi, dword [ebp - 0x24]
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x30]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x38], esi
mov dword [ebp - 8], eax
call fcn.004dd6a0
test al, al
jne 0x40299c
mov edi, 0xc0000001
jmp 0x4029bd
push 0x10
lea eax, [ebp - 0x14]
push eax
push 0x24000002
push esi
mov esi, dword [0x5cf1f8]
mov ecx, esi
call dword [0x55890c]
call esi
mov esi, dword [ebp - 0x38]
mov edi, eax
lea ecx, [ecx]
test esi, esi
je 0x4029de
call fcn.004dd6a0
test al, al
je 0x4029de
push esi
mov esi, dword [0x5cf1e4]
mov ecx, esi
call dword [0x55890c]
call esi
mov esi, dword [ebp - 0x18]
test esi, esi
je 0x4029ff
call fcn.004dd6a0
test al, al
je 0x4029ff
push esi
mov esi, dword [0x5cf1f0]
mov ecx, esi
call dword [0x55890c]
call esi
mov eax, dword [ebp - 0x1c]
mov ecx, eax
call fcn.004de380
test edi, edi
js 0x402a8b
push 0x80000000
push 4
push 0
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_InitiateShutdownW]
test eax, eax
je 0x402b37
push eax
call sym.ProcessHacker.exe_PhGetWin32Message
mov esi, eax
test esi, esi
je 0x402b22
push dword [esi + 4]
push 0x5634d8
push str.Unable_to_configure_the_boot_application.
push 0xfffe
push 0x20
push ebx
call sym.ProcessHacker.exe_PhShowMessage2
add esp, 0x18
lea ecx, [esi - 8]
or eax, 0xffffffff
lock xadd dword [ecx + 4], eax
dec eax
jne 0x402b37
call fcn.004c1f60
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00534c91
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0x1c]
call fcn.004de380
mov ecx, edi
cmp edi, 0xc0000022
je 0x402ab0
cmp edi, 0xc0000005
je 0x402ab0
mov eax, ecx
and eax, 0xfff0000
cmp eax, 0x70000
jne 0x402ac9
movzx eax, cx
jmp 0x402aba
push edi
lfence
call dword [sym.imp.ntdll.dll_RtlNtStatusToDosError]
test eax, eax
je 0x402ac9
push eax
lfence
call sym.ProcessHacker.exe_PhGetWin32Message
jmp 0x402ad2
push edi
lfence
call sym.ProcessHacker.exe_PhGetNtMessage
mov esi, eax
test esi, esi
je 0x402b22
lfence
lfence
push dword [esi + 4]
push 0x5634d8
push str.Unable_to_configure_the_boot_application.
push 0xfffe
push 0x20
push ebx
call sym.ProcessHacker.exe_PhShowMessage2
add esp, 0x18
lea ecx, [esi - 8]
or eax, 0xffffffff
lock xadd dword [ecx + 4], eax
dec eax
jne 0x402b37
lfence
call fcn.004c1f60
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00534c91
mov esp, ebp
pop ebp
ret
push str.Unable_to_configure_the_boot_application.
push 0x5981b0
push 0x10
push ebx
call sym.ProcessHacker.exe_PhShowMessage
add esp, 0x10
mov ecx, dword ds:[ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00534c91
mov esp, ebp
pop ebp
ret