Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/MHSanaei/3x-ui.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/web
diff options
context:
space:
mode:
authorMHSanaei <ho3ein.sanaei@gmail.com>2023-03-19 12:09:14 +0300
committerMHSanaei <ho3ein.sanaei@gmail.com>2023-03-19 12:09:14 +0300
commite68317c6bd0279b158a24dedfffc87f4856fb214 (patch)
treee0d055c744a5790698f679407c2562f3da018c08 /web
parentb7f476568bd6dd85a0e43591386a7d101357630b (diff)
xtls bug fixed
Diffstat (limited to 'web')
-rw-r--r--web/assets/js/model/xray.js18
1 files changed, 6 insertions, 12 deletions
diff --git a/web/assets/js/model/xray.js b/web/assets/js/model/xray.js
index b3127706..47c5b04b 100644
--- a/web/assets/js/model/xray.js
+++ b/web/assets/js/model/xray.js
@@ -1156,13 +1156,10 @@ class Inbound extends XrayCommonClass {
}
}
- if (this.xtls) {
- if (!ObjectUtil.isEmpty(this.stream.tls.server)) {
- address = this.stream.tls.server;
+ if (this.XTLS) {
if (type === "tcp") {
params.set("flow", this.settings.vlesses[clientIndex].flow);
}
- }
}
const link = `vless://${uuid}@${address}:${port}`;
@@ -1245,19 +1242,16 @@ class Inbound extends XrayCommonClass {
params.set("alpn", this.stream.tls.alpn[0]);
if (!ObjectUtil.isEmpty(this.stream.tls.server)) {
address = this.stream.tls.server;
- }
- if (this.stream.tls.settings[0]['serverName'] !== ''){
- params.set("sni", this.stream.tls.settings[0]['serverName']);
}
+ if (this.stream.tls.settings[0]['serverName'] !== ''){
+ params.set("sni", this.stream.tls.settings[0]['serverName']);
+ }
}
- if (this.xtls) {
- if (!ObjectUtil.isEmpty(this.stream.tls.server)) {
- address = this.stream.tls.server;
- if (type === "tcp" && this.settings.trojans[clientIndex].flow.length > 0) {
+ if (this.XTLS) {
+ if (type === "tcp" && this.settings.trojans[clientIndex].flow.length > 0) {
params.set("flow", this.settings.trojans[clientIndex].flow);
}
- }
}
const link = `trojan://${settings.trojans[clientIndex].password}@${address}:${this.port}#${encodeURIComponent(remark)}`;