Skip to content

Commit

Permalink
feat: 更新用户交互和系统服务管理
Browse files Browse the repository at this point in the history
  • Loading branch information
MaxLHy0424 committed Jun 8, 2024
1 parent d0bbb7f commit a7ea13b
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 14 deletions.
4 changes: 2 additions & 2 deletions extern.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
char Dat[3]{};
bool Continue(){
printf("是否继续? (Y/N): ");
while(true){
for(;;){
scanf("%s",&Dat[1]);
if((Dat[1]=='Y'||Dat[1]=='y'||Dat[1]=='N'||Dat[1]=='n')&&(Dat[2]==0)){
break;
Expand All @@ -18,7 +18,7 @@ void ForceShow(){
HWND ForeWnd{GetForegroundWindow()};
DWORD ForeID{GetWindowThreadProcessId(ForeWnd,NULL)};
DWORD CurID{GetCurrentThreadId()};
while(true){
for(;;){
AttachThreadInput(CurID,ForeID,TRUE);
ShowWindow(ForeWnd,SW_SHOWNORMAL);
SetWindowPos(ForeWnd,HWND_TOPMOST,0,0,0,0,SWP_NOSIZE|SWP_NOMOVE);
Expand Down
29 changes: 17 additions & 12 deletions main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@
void About(){
puts("[关于]\n");
puts(" Computer Room Control Software Nemesis");
puts("\t\tv4.9.7\n");
puts("\t\tv4.9.8\n");
puts(" https://github.com/MaxLHy0424/CRCSN");
puts(" (C) 2024 MaxLHy0424, All Rights Reserved.\n");
puts("---------------------------------------------\n");
system("Echo 按任意键返回.&Pause>NUL");
printf("按任意键返回. ");
system("Pause>NUL");
return;
}
void Crack(){
Expand All @@ -16,7 +17,7 @@ void Crack(){
puts(" 1 极域电子教室");
puts(" 2 联想云教室\n");
printf("请输入: ");
while(true){
for(;;){
scanf("%s",&Dat[0]);
if((Dat[0]=='0'||Dat[0]=='1'||Dat[0]=='2')&&(Dat[1]==0)){
break;
Expand Down Expand Up @@ -46,9 +47,9 @@ void Crack(){
system("Reg Add \"HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options\\GATESRV.exe\" /F /T REG_SZ /V debugger /D ?");
system("Reg Add \"HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options\\ProcHelper64.exe\" /F /T REG_SZ /V debugger /D ?");
system("Reg Add \"HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options\\MasterHelper.exe\" /F /T REG_SZ /V debugger /D ?");
system("Net Stop STUDSRV /Y");
system("Net Stop TDNetFilter /Y");
system("Net Stop TDFileFilter /Y");
system("Net Stop STUDSRV /Y");
}
break;
}case '2':{
Expand Down Expand Up @@ -87,15 +88,16 @@ void Crack(){
system("Reg Add \"HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options\\DeploymentManager.exe\" /F /T REG_SZ /V debugger /D ?");
system("Reg Add \"HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options\\DeploymentAgent.exe\" /F /T REG_SZ /V debugger /D ?");
system("Reg Add \"HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options\\XYNTService.exe\" /F /T REG_SZ /V debugger /D ?");
system("Net Stop tvnserver /Y");
system("Net Stop BSAgentSvr /Y");
system("Net Stop WFBSMlogon /Y");
system("Net Stop tvnserver /Y");
}
break;
}
}
puts("\n----------------------------------------\n");
system("Echo 按任意键返回.&Pause>NUL");
printf("按任意键返回. ");
system("Pause>NUL");
}
system("Cls");
goto BEGIN;
Expand All @@ -106,14 +108,15 @@ void Recovery(){
if(!IsUserAnAdmin()){
puts("需要管理员权限.\n");
puts("--------------------\n");
system("Echo 按任意键返回.&Pause>NUL");
printf("按任意键返回. ");
system("Pause>NUL");
return;
}
puts(" 0 返回");
puts(" 1 极域电子教室");
puts(" 2 联想云教室\n");
printf("请输入: ");
while(true){
for(;;){
scanf("%s",&Dat[0]);
if((Dat[0]=='0'||Dat[0]=='1'||Dat[0]=='2')&&(Dat[1]==0)){
break;
Expand Down Expand Up @@ -166,7 +169,8 @@ void Recovery(){
}
}
puts("----------------------------------------\n");
system("Echo 按任意键返回.&Pause>NUL");
printf("按任意键返回. ");
system("Pause>NUL");
}
system("Cls");
goto BEGIN;
Expand Down Expand Up @@ -195,7 +199,8 @@ int main(int argc,char* argv[]){
else{
puts("参数错误.\n");
puts("--------------------\n");
system("Echo 按任意键继续.&Pause>NUL");
printf("按任意键继续. ");
system("Pause>NUL");
goto BEGIN;
}
}
Expand All @@ -210,9 +215,9 @@ int main(int argc,char* argv[]){
puts(" ? 关于");
puts(" 1 破解");
puts(" 2 恢复");
puts(" 3 命令\n");
puts(" 3 CMD\n");
printf("请输入: ");
while(true){
for(;;){
scanf("%s",&Dat[0]);
if((Dat[0]=='?'||Dat[0]=='1'||Dat[0]=='2'||Dat[0]=='3')&&(Dat[1]==0)){
break;
Expand Down

0 comments on commit a7ea13b

Please sign in to comment.