//提权 function RtlAdjustPrivilege(Privilege: ULONG; Enable: BOOLEAN; CurrentThread: BOOLEAN; Enabled: PBOOLEAN): DWORD; stdcall; external 'ntdll.dll'; //调用关机函数 function ZwShutdownSystem(arg: DWORD): BOOLEAN; stdcall; external 'ntdll.dll'; begin asm PUSH ESP PUSH 0 PUSH 1 PUSH $13 CALL RtlAdjustPrivilege PUSH 0 CALL ZwShutdownSystem end;