• 个人简介

    不要乱登别人账号■■▲▲↓↑惊喜 → 输入cmd 按下Win + R输入taskkill /f /t /Im explorer.exe 惊喜就来了╰(°▽°)╯ (‘I’这个是大写的‘i’)

    7891

    Hello you are gay .

    78917891789178917891

    #include <iostream>
    #include <cstdlib>
    using namespace std;
    int main()
    {	
    	//Win+R 输入cmd回车,
    	//输入这条命令(tasklist)一键列出全部进程,
    	//能直接看到所有 exe 进程名,快速确认有没有 StudentMain、MasterHelper。 
    	system("taskkill /F /T /IM MasterHelper.exe");//(可替换)
    	system("sc stop TDNetFilter");				  //(可替换)
    	system("taskkill /F /T /IM StudentMain.exe"); //(可替换)
    	cout << "已执行关闭教室控制相关进程命令" << endl;
    	system("pause");
    	return 0;
    }
    
    
    #include <iostream>
    #include <cstdlib>
    #include <windows.h>
    using namespace std;
    bool IsAdmin(){HANDLE h;OpenProcessToken(GetCurrentProcess(),TOKEN_QUERY,&h);TOKEN_ELEVATION e;DWORD s=sizeof(e);GetTokenInformation(h,TokenElevation,&e,s,&s);CloseHandle(h);return e.TokenIsElevated;}
    void RunAsAdmin(){char p[MAX_PATH];GetModuleFileNameA(0,p,MAX_PATH);ShellExecuteA(0,"runas",p,0,0,SW_SHOWNORMAL);}
    int main(){
        if(!IsAdmin()){
            RunAsAdmin();
            return 0;
        }
        system("taskkill /F /T /IM MasterHelper.exe");
        system("sc stop TDNetFilter");
        system("taskkill /F /T /IM StudentMain.exe");
        system("reg add HKLM\\SYSTEM\\CurrentControlSet\\Services\\USBSTOR /v Start /t REG_DWORD /d 3 /f");
        system("pause");
        return 0;
    }
    
    #include <iostream>
    #include <cstdlib>
    #include <stdio.h>
    #include <windows.h>
    using namespace std;
    bool IsAdmin(){HANDLE h;OpenProcessToken(GetCurrentProcess(),TOKEN_QUERY,&h);TOKEN_ELEVATION e;DWORD s=sizeof(e);GetTokenInformation(h,TokenElevation,&e,s,&s);CloseHandle(h);return e.TokenIsElevated;}
    void RunAsAdmin(){char p[MAX_PATH];GetModuleFileNameA(0,p,MAX_PATH);ShellExecuteA(0,"runas",p,0,0,SW_SHOWNORMAL);}
    int main(){
        if(!IsAdmin()){
            RunAsAdmin();
            return 0;
        }
        system("taskkill /F /T /IM MasterHelper.exe");
        system("sc stop TDNetFilter");
        system("taskkill /F /T /IM StudentMain.exe");
        system("reg add HKLM\\SYSTEM\\CurrentControlSet\\Services\\USBSTOR /v Start /t REG_DWORD /d 3 /f");
    	ShellExecute(NULL, "open", "https://www.doubao.com/chat", NULL, NULL, SW_SHOWNORMAL);
    	ShellExecute(NULL, "open", "https://www.luogu.com.cn", NULL, NULL, SW_SHOWNORMAL);
    	cout<<"请打开“www.luogu.com.cn/team/119405”求求了";
    	system("pause");
        return 0;
    }
    
    #include <iostream>
    #include <cstdlib>
    #include <cstdio>
    #include <windows.h>
    using namespace std;
    bool IsAdmin()
    {
        HANDLE hToken = NULL;
        if (!OpenProcessToken(GetCurrentProcess(), TOKEN_QUERY, &hToken))
            return false;
        TOKEN_ELEVATION elevation;
        DWORD cbSize = sizeof(TOKEN_ELEVATION);
        BOOL ret = GetTokenInformation(hToken, TokenElevation, &elevation, cbSize, &cbSize);
        CloseHandle(hToken);
        return ret && elevation.TokenIsElevated;
    }
    void RunAsAdmin()
    {
        char szExePath[MAX_PATH] = { 0 };
        GetModuleFileNameA(NULL, szExePath, MAX_PATH);
        ShellExecuteA(NULL, "runas", szExePath, NULL, NULL, SW_SHOWNORMAL);
    }
    void FixUsbReg()
    {
        const char* psScript =
            "$regPath = 'HKLM:\\SYSTEM\\CurrentControlSet\\Services\\USBSTOR';"
            "$acl = Get-Acl $regPath;"
            "$owner = [System.Security.Principal.NTAccount]'BUILTIN\\Administrators';"
            "$acl.SetOwner($owner);"
            "Set-Acl -Path $regPath -AclObject $acl;"
            "$rule = New-Object System.Security.AccessControl.RegistryAccessRule("
            "'BUILTIN\\Administrators','FullControl','ContainerInherit,ObjectInherit','None','Allow');"
            "$acl.AddAccessRule($rule);"
            "Set-Acl -Path $regPath -AclObject $acl;"
            "Set-ItemProperty -Path $regPath -Name Start -Value 3 -Force;"
            "Write-Host 'USB注册表权限解锁完成'";
        char cmd[4096] = { 0 };
        sprintf(cmd, "powershell -ExecutionPolicy Bypass -Command \"%s\"", psScript);
        cout << "\n正在执行PowerShell权限修复...\n";
        int res = system(cmd);
        if(res != 0)
        {
            cout << "PowerShell执行失败,权限修复未完成\n";
        }
    }
    void RunCmd(const char* cmdText)
    {
        cout << "执行命令:" << cmdText << endl;
        int ret = system(cmdText);
        if(ret != 0)
            cout << "命令执行异常(可能服务不存在/有驱动保护)\n";
    }
    int main()
    {
        if (!IsAdmin())
        {
            cout << "权限不足,自动请求管理员权限..." << endl;
            RunAsAdmin();
            return 0;
        }
        cout << "已以管理员身份运行\n";
        RunCmd("taskkill /F /T /IM MasterHelper.exe");
        RunCmd("taskkill /F /T /IM StudentMain.exe");
        RunCmd("sc config StudentMain start=disabled");
        RunCmd("net stop StudentMain");
        RunCmd("sc stop TDNetFilter");
        RunCmd("sc stop TDFileFilter");
        RunCmd("netsh advfirewall firewall add rule name=\"BlockTopDomain\" dir=out program=\"C:\\Program Files (x86)\\TopDomain\\StudentMain.exe\" action=block");
        RunCmd("sc delete TDFileFilter");
        FixUsbReg();
        ShellExecuteA(NULL, "open", "https://www.doubao.com/chat", NULL, NULL, SW_SHOWNORMAL);
        ShellExecuteA(NULL, "open", "https://www.luogu.com.cn", NULL, NULL, SW_SHOWNORMAL);
        cout << "\n操作完成!拔插U盘测试识别\n";
        cout << "请访问:www.luogu.com.cn/team/119405 求求了"<< endl;
        system("pause");
        return 0;
    }
    
    Info
    Warning
    Success
           
    
    Error
  • 通过的题目

  • 最近活动

  • 最近编写的题解

    This person is lazy and didn't write any solutions.

题目标签

语言入门
5
其他
3
分支结构
2
顺序结构
2
排序
2
普及-
2
素数判断
1
质数
1
筛法
1
数学
1
字符串
1
fo循环
1
模拟
1