直接写IO端口0x64完成计算机重启操作实现暴力关机

来源:互联网 发布:淘宝优惠券shipinwj 编辑:程序博客网 时间:2024/06/01 22:04
#include<ntddk.h>VOID DriverUnload(IN PDRIVER_OBJECT DriverObject){ KdPrint(("Driver Unload is Run!\n"));}VOID ShutDown()//实现暴力关机{  _asm  {    mov ax,2001h;    mov dx,1004h;    out dx,ax;    //写入 2001h  到端口 1004h    实现暴力关机  }}NTSTATUS DriverEntry(IN PDRIVER_OBJECT DriverObject,IN PUNICODE_STRING RegistryPath){ KdPrint(("Driver Entry is Run!\n"));    DriverObject -> DriverUnload = DriverUnload;  //汇编中直接写端口0x64完成计算机直接重启操作 __asm {  mov al,0xfe  out 0x64,al }    return STATUS_SUCCESS;}

	
				
		
原创粉丝点击