Skip to content

SJTU-Plus/ManagerBotServer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ManagerBotServer (Deprecated)

ManagerBotServer 是 ManagerBot 的配套网页。

如何使用

  1. 创建 Python(>=3.7) 虚拟环境
     virtualenv venv
     source venv/bin/activate
  2. 安装依赖
    pip install -r requirements.txt
  3. 新建并配置config.json
    {
    "ENV": "development",
    "JACCOUNT_CLIENT_ID": "",
    "JACCOUNT_CLIENT_SECRET": "",
    "JACCOUNT_ACCESS_TOKEN_URL": "https://jaccount.sjtu.edu.cn/oauth2/token",
    "JACCOUNT_AUTHORIZE_URL": "https://jaccount.sjtu.edu.cn/oauth2/authorize",
    "JACCOUNT_API_BASE_URL": "https://api.sjtu.edu.cn/",
    "JACCOUNT_CLIENT_KWARGS": {
        "scope": "openid",
        "token_endpoint_auth_method": "client_secret_basic",
        "token_placement": "header"
    },
    "ATTESTATION_SECRET": ""
    }
    其中secret可以按照cmac_attestation.py中的方式生成。
  4. 运行app.py