Xray-core icon indicating copy to clipboard operation
Xray-core copied to clipboard

使用xtls后nginx没有办法做客户端认证,该如何解决?

Open bitching opened this issue 2 years ago • 4 comments

根据搜索结果显示: A client-side certificate is a transport-layer authentication mechanism; it can be used to verify a user before the application layer. In terms of a web app, it happens at the “S” of “HTTPS”: the client is authenticated when the TLS handshake occurrs, and not at the HTTP layer that is tunneled over the secure connection. 只有用非443端口一条路了么?

bitching avatar Jan 04 '22 09:01 bitching

这客户端认证指的是啥认证啊?是nginx开启https吗

huangguiniab avatar Jan 07 '22 03:01 huangguiniab

这客户端认证指的是啥认证啊?是nginx开启https吗

双向SSL吧,服务器要向客户端提供证书,客户端也要向服务器提供证书,互撸

UJX6N avatar Jan 09 '22 07:01 UJX6N

这客户端认证指的是啥认证啊?是nginx开启https吗

双向SSL吧,服务器要向客户端提供证书,客户端也要向服务器提供证书,互撸

是的,目前用nginx return 302到非标端口做认证。 感觉可能也没什么好的解决办法了。

bitching avatar Jan 10 '22 13:01 bitching

应该就是客户端访问网站时会弹出窗口要求选择证书这个东西吧。但是客户端证书我搞不到实验不了。我有一个想法,分两个域名。用nginx挡在443监听SNI分流,域名A监听非标端口,xray也监听非标端口。监听到域名A就转发流量到nginx的A端口,监听到域名B就转发流量到xray。理论上这样域名A可以得到裸的TLS连接,就能进行客户端认证。在用户看来还是标准的443端口。 我搞不到客户端证书,所以我试不了,不知道这样行不行。谷歌搜索nginx sni分流有教程

huangguiniab avatar Jan 11 '22 02:01 huangguiniab

解决不了

Fangliding avatar Apr 17 '24 19:04 Fangliding