mirror of
https://github.com/zhaojh329/rttys.git
synced 2026-02-27 09:53:21 +08:00
@@ -38,17 +38,15 @@ as the password for device connecting.
|
||||
$ rttys run -t 34762d07637276694b938d23f10d7164
|
||||
|
||||
### Use your own authentication server
|
||||
If the device authentication URL is configured, when the device connecting,
|
||||
rttys will initiate an authentication request to this URL, and the authentication
|
||||
If the device hook URL is configured, when the device connecting,
|
||||
rttys will initiate a request to this URL, and the authentication
|
||||
server will return whether the authentication has been passed.
|
||||
|
||||
Request data format:
|
||||
|
||||
{"devid":"test", "token":"34762d07637276694b938d23f10d7164"}
|
||||
|
||||
Authentication Server Response Format:
|
||||
|
||||
{"auth": true}
|
||||
Authentication Server Response HTTP 200 to indicate that the device is allowed to connect.
|
||||
|
||||
### mTLS
|
||||
You can enable mTLS by specifying device CA storage (valid file) in config file or from CLI (variable ssl-cacert).
|
||||
|
||||
@@ -37,15 +37,13 @@ golang and node 20+ is required
|
||||
$ rttys -t 34762d07637276694b938d23f10d7164
|
||||
|
||||
### 使用自己的认证服务器
|
||||
如果配置了设备认证 url, 设备连接时, rttys 会向此 url 发起认证请求, 认证服务器返回是否通过认证.
|
||||
如果配置了设备 hook url, 设备连接时, rttys 会向此 url 发起请求, 认证服务器返回是否通过认证.
|
||||
|
||||
请求数据格式:
|
||||
|
||||
{"devid":"test", "token":"34762d07637276694b938d23f10d7164"}
|
||||
|
||||
认证服务器响应格式:
|
||||
|
||||
{"auth": true}
|
||||
认证服务器响应 HTTP 200 表示允许设备连接.
|
||||
|
||||
### SSL 双向认证(mTLS)
|
||||
您可以在配置文件中指定设备 CA 存储(有效文件)或在 CLI 中指定设备 CA 存储(参数 ssl-cacert) 来启用 mTLS。
|
||||
|
||||
Reference in New Issue
Block a user