Conversation
|
verifyPeerCertInNames 也加个空白检查吧,不然不确定会发生啥,话说如果写了 fromMitm 但入站没传进来 SNI 会发生啥来着
|
|
我发现这个 listable 字符串写空白和列表写一项空白现在是不同的行为,统一一下 trim 掉两边空格并且不带上空白吧
|
|
默认应该是 |
|
就是只改 ListableSimpleString,假如我就是想填一个 |
|
我觉得 |
|
现在的情况就是 "" 并不等于 [""],前者的定义是空(没填)而后者是有一个成员,所以要 fix 一下,这个 simple 就不允许这种吧 |
|
|
|
不然嵌套结构也会有类似 |
|
有些软件的 json 生成方式是即使那个字段没用到也给你填个 "" 上去,这不就误会了, 另外 Golang json 的默认解析,没填和 "" 是一样的,就像 0,不应该改变这个行为, |
|
它们总不会生成 "outbounds": "" 吧 |
|
或者遇到 |
|
我的意思是比如 GUI 直接拿用户填的值来填入 json,用户没填但 GUI 给 json 填个 "",那不就误会了 直接把 ""(含空格)给 trim 掉吧,只有它的话就搞个 nil 回去 |
|
那就这样吧 |
|
还有一件事是收集一下还有哪些适合listable的参数 |
|
比方说desc里说的出站入站 还有vmess vless入站配置的那些clients |
|
如果是 ["", ""] 也应当被视为 nil,就是说不允许填写空的,对于 string 先 trim 一下左右再判断
|
|
现在的逻辑是 |
|
真的烧脑,一切的根源都是 GUI 加可变长度数组可能比较怪,alpn 都是直接让选的 对于这俩参数还有判断是否 nil 来决定是否 allowInscure 并接管证书验证的问题
|
|
|
|
太烧脑了还是,决定把 verifyPeerCertInNames 改成单个的 verifyPeerCertByName,
这东西加进分享链接和 GUI,99% 的场景也就填单个比如 fastly.com ,搞成可变长度数组不划算,同时兼容一下多个就行了 有个小问题是 IPv6 证书的话要填
|
|
|
|
为了UI想这想那有点削足适履的感觉了 |
|
|
|
这个listable只是为了手写简单而且可读性更高而已 |
|
|
the MitM+domainFronting version of serverless-for-Iran is still works. but "x.com" is behind cloudflare now, so domainFronting does not work for it. so domainFronting only works for "youtube", "reddit" and some others ("porn-sites", ...) multiple entries is needed, because we don't know exactly which certificate will be returned for each IP. /// |
|
对了还有个 sockopt,这个也是 Xray 专有的东西直接 json 分享吧,XDRIVE 肯定也是 extra json
|
|
Oh, No, Instagram still works, they only block "www.whatsapp.com" domain that i had used in config, i change it and instagram and whatsapp opened! youtube+instagram+whatsapp is opened, |
…nNames`->`verifyPeerCertByName` And use `,` as the separator instead of `~`/array #5567 (comment) https://t.me/projectXtls/1464 https://t.me/projectXtls/1465 https://t.me/projectXtls/1466 #5625 (comment)
…nNames`->`verifyPeerCertByName` And use `,` as the separator instead of `~`/array #5567 (comment) https://t.me/projectXtls/1464 https://t.me/projectXtls/1465 https://t.me/projectXtls/1466 #5625 (comment)
…nNames`->`verifyPeerCertByName` And use `,` as the separator instead of `~`/array #5567 (comment) https://t.me/projectXtls/1464 https://t.me/projectXtls/1465 https://t.me/projectXtls/1466 #5625 (comment)
|
如果这样改了那现在这个listable怎么办 |
|
|
|
可能下下个版本先给 alpn 上一个然后就可以这样写
|
|
|
|
但是还是有个小问题是有些人可能会这么写 |

这个泛型实现非常通用 目前只加了那个verifyPeerCertInNames和pinnedPeerCertSha256 如果用在出入站上甚至可以这样