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
diff options
context:
space:
mode:
authorMHSanaei <ho3ein.sanaei@gmail.com>2024-03-11 10:36:33 +0300
committerMHSanaei <ho3ein.sanaei@gmail.com>2024-03-11 10:57:43 +0300
commitd18eb7e4e45306ee09fcd60c3d589da5197b626a (patch)
tree5447cfea8583cc72e7645866dd9ca64830ad405e /web/html/xui/form
parentd3377cd45effb3f95bb5b1023fd4d386d8c2e469 (diff)
New - HttpUpgrade Transport
Diffstat (limited to 'web/html/xui/form')
-rw-r--r--web/html/xui/form/outbound.html64
-rw-r--r--web/html/xui/form/stream/stream_httpupgrade.html13
-rw-r--r--web/html/xui/form/stream/stream_settings.html9
3 files changed, 58 insertions, 28 deletions
diff --git a/web/html/xui/form/outbound.html b/web/html/xui/form/outbound.html
index 469c42b9..b6874240 100644
--- a/web/html/xui/form/outbound.html
+++ b/web/html/xui/form/outbound.html
@@ -214,34 +214,34 @@
<!-- stream settings -->
<template v-if="outbound.canEnableStream()">
- <a-form-item label='{{ i18n "transmission" }}'>
- <a-select v-model="outbound.stream.network" @change="streamNetworkChange"
- :dropdown-class-name="themeSwitcher.currentTheme">
- <a-select-option value="tcp">TCP</a-select-option>
- <a-select-option value="kcp">mKCP</a-select-option>
- <a-select-option value="ws">WS</a-select-option>
- <a-select-option value="http">H2</a-select-option>
- <a-select-option value="quic">QUIC</a-select-option>
- <a-select-option value="grpc">gRPC</a-select-option>
- </a-select>
- </a-form-item>
+ <a-form-item label='{{ i18n "transmission" }}'>
+ <a-select v-model="outbound.stream.network" @change="streamNetworkChange"
+ :dropdown-class-name="themeSwitcher.currentTheme">
+ <a-select-option value="tcp">TCP</a-select-option>
+ <a-select-option value="kcp">mKCP</a-select-option>
+ <a-select-option value="ws">WS</a-select-option>
+ <a-select-option value="http">H2</a-select-option>
+ <a-select-option value="quic">QUIC</a-select-option>
+ <a-select-option value="grpc">gRPC</a-select-option>
+ <a-select-option value="httpupgrade">HttpUpgrade</a-select-option>
+ </a-select>
+ </a-form-item>
<template v-if="outbound.stream.network === 'tcp'">
<a-form-item label='HTTP {{ i18n "camouflage" }}'>
- <a-switch
- :checked="outbound.stream.tcp.type === 'http'"
+ <a-switch :checked="outbound.stream.tcp.type === 'http'"
@change="checked => outbound.stream.tcp.type = checked ? 'http' : 'none'">
</a-switch>
</a-form-item>
<template v-if="outbound.stream.tcp.type == 'http'">
- <a-form-item label='{{ i18n "host" }}'>
- <a-input v-model.trim="outbound.stream.tcp.host"></a-input>
- </a-form-item>
- <a-form-item label='{{ i18n "path" }}'>
- <a-input v-model.trim="outbound.stream.tcp.path"></a-input>
- </a-form-item>
+ <a-form-item label='{{ i18n "host" }}'>
+ <a-input v-model.trim="outbound.stream.tcp.host"></a-input>
+ </a-form-item>
+ <a-form-item label='{{ i18n "path" }}'>
+ <a-input v-model.trim="outbound.stream.tcp.path"></a-input>
+ </a-form-item>
</template>
</template>
-
+
<!-- kcp -->
<template v-if="outbound.stream.network === 'kcp'">
<a-form-item label='{{ i18n "camouflage" }}'>
@@ -265,7 +265,7 @@
</a-form-item>
<a-form-item label='Uplink (MB/s)'>
<a-input-number v-model.number="outbound.stream.kcp.upCap"></a-input-number>
- </a-form-item>
+ </a-form-item>
<a-form-item label='Downlink (MB/s)'>
<a-input-number v-model.number="outbound.stream.kcp.downCap"></a-input-number>
</a-form-item>
@@ -279,7 +279,7 @@
<a-input-number v-model.number="outbound.stream.kcp.writeBuffer"></a-input-number>
</a-form-item>
</template>
-
+
<!-- ws -->
<template v-if="outbound.stream.network === 'ws'">
<a-form-item label='{{ i18n "host" }}'>
@@ -287,9 +287,9 @@
</a-form-item>
<a-form-item label='{{ i18n "path" }}'>
<a-form-item><a-input v-model.trim="outbound.stream.ws.path"></a-input>
- </a-form-item>
+ </a-form-item>
</template>
-
+
<!-- http -->
<template v-if="outbound.stream.network === 'http'">
<a-form-item label='{{ i18n "host" }}'>
@@ -299,7 +299,7 @@
<a-input v-model.trim="outbound.stream.http.path"></a-input>
</a-form-item>
</template>
-
+
<!-- quic -->
<template v-if="outbound.stream.network === 'quic'">
<a-form-item label='{{ i18n "pages.inbounds.stream.quic.encryption" }}'>
@@ -311,7 +311,7 @@
</a-form-item>
<a-form-item label='{{ i18n "password" }}'>
<a-input v-model.trim="outbound.stream.quic.key"></a-input>
- </a-form-item>
+ </a-form-item>
<a-form-item label='{{ i18n "camouflage" }}'>
<a-select v-model="outbound.stream.quic.type" :dropdown-class-name="themeSwitcher.currentTheme">
<a-select-option value="none">None</a-select-option>
@@ -323,7 +323,7 @@
</a-select>
</a-form-item>
</template>
-
+
<!-- grpc -->
<template v-if="outbound.stream.network === 'grpc'">
<a-form-item label='Service Name'>
@@ -333,6 +333,16 @@
<a-switch v-model="outbound.stream.grpc.multiMode"></a-switch>
</a-form-item>
</template>
+
+ <!-- httpupgrade -->
+ <template v-if="outbound.stream.network === 'httpupgrade'">
+ <a-form-item label='{{ i18n "host" }}'>
+ <a-input v-model="outbound.stream.httpupgrade.host"></a-input>
+ </a-form-item>
+ <a-form-item label='{{ i18n "path" }}'>
+ <a-form-item><a-input v-model.trim="outbound.stream.httpupgrade.path"></a-input>
+ </a-form-item>
+ </template>
</template>
<!-- tls settings -->
diff --git a/web/html/xui/form/stream/stream_httpupgrade.html b/web/html/xui/form/stream/stream_httpupgrade.html
new file mode 100644
index 00000000..73f10b07
--- /dev/null
+++ b/web/html/xui/form/stream/stream_httpupgrade.html
@@ -0,0 +1,13 @@
+{{define "form/streamHTTPUPGRADE"}}
+<a-form :colon="false" :label-col="{ md: {span:8} }" :wrapper-col="{ md: {span:14} }">
+ <a-form-item label="PROXY Protocol">
+ <a-switch v-model="inbound.stream.httpupgrade.acceptProxyProtocol"></a-switch>
+ </a-form-item>
+ <a-form-item label='{{ i18n "path" }}'>
+ <a-input v-model.trim="inbound.stream.httpupgrade.path"></a-input>
+ </a-form-item>
+ <a-form-item label='{{ i18n "host" }}'>
+ <a-input v-model.trim="inbound.stream.httpupgrade.host"></a-input>
+ </a-form-item>
+</a-form>
+{{end}}
diff --git a/web/html/xui/form/stream/stream_settings.html b/web/html/xui/form/stream/stream_settings.html
index af81651d..a3cb0362 100644
--- a/web/html/xui/form/stream/stream_settings.html
+++ b/web/html/xui/form/stream/stream_settings.html
@@ -2,7 +2,7 @@
<!-- select stream network -->
<a-form :colon="false" :label-col="{ md: {span:8} }" :wrapper-col="{ md: {span:14} }">
<a-form-item label='{{ i18n "transmission" }}'>
- <a-select v-model="inbound.stream.network" style="width: 50%" @change="streamNetworkChange"
+ <a-select v-model="inbound.stream.network" style="width: 75%" @change="streamNetworkChange"
:dropdown-class-name="themeSwitcher.currentTheme">
<a-select-option value="tcp">TCP</a-select-option>
<a-select-option value="kcp">mKCP</a-select-option>
@@ -10,6 +10,7 @@
<a-select-option value="http">H2</a-select-option>
<a-select-option value="quic">QUIC</a-select-option>
<a-select-option value="grpc">gRPC</a-select-option>
+ <a-select-option value="httpupgrade">HttpUpgrade</a-select-option>
</a-select>
</a-form-item>
</a-form>
@@ -43,6 +44,12 @@
<template v-if="inbound.stream.network === 'grpc'">
{{template "form/streamGRPC"}}
</template>
+
+<!-- httpupgrade -->
+<template v-if="inbound.stream.network === 'httpupgrade'">
+ {{template "form/streamHTTPUPGRADE"}}
+</template>
+
<!-- sockopt -->
<template>
{{template "form/streamSockopt"}}