Skip to content

Use auth_key authentication instead of HTTP Proxy authentication #17

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 12, 2023

Conversation

lxrite
Copy link
Owner

@lxrite lxrite commented Nov 12, 2023

新的身份校验
1.0版本使用HTTP的Proxy-Authentication进行身份校验,并且依赖浏览器等UI交互来实现账号、密码输入;对于一些没有UI界面的命令行应用会很不方便。
1.1版本开始修改成内建的AuthKey身份校验方案,客户端将AuthKey写在JSON配置文件中,不再依赖浏览器等UI交互。

配置文件改动

  • 服务端(ahps)
    • 移除users字段
    • 新增auth_key_list字段
  • 客户端(ahpc)
    • 新增auth_key字段

新老版本兼容性

当服务端不启用身份校验时(配置文件auth的值为false),1.1版本的服务端可以同时接收1.0和1.1版本客户端的请求;
当客户端不填auth_key时(配置文件没有auth_key字段或者auth_key的值为空字符串),1.1版本的客户端会使用1.0版本的格式进行请求来同时兼容1.0和1.1的服务端。

ahpc \ ahps 1.0 ("auth": false) 1.0 ("auth": true) 1.1 ("auth": false) 1.1 ("auth": true)
1.0
1.1 ("auth_key": "")
1.1 ("auth_key": "key_value")

@lxrite lxrite added this to the 1.1 milestone Nov 12, 2023
@lxrite lxrite merged commit 941bd54 into master Nov 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant