|
1 | 1 | {{define "form/streamXHTTP"}} |
2 | | -<a-form :colon="false" :label-col="{ md: {span:8} }" :wrapper-col="{ md: {span:14} }"> |
| 2 | +<a-form :colon="false" :label-col="{ md: {span:8} }" |
| 3 | + :wrapper-col="{ md: {span:14} }"> |
3 | 4 | <a-form-item label='{{ i18n "host" }}'> |
4 | 5 | <a-input v-model.trim="inbound.stream.xhttp.host"></a-input> |
5 | 6 | </a-form-item> |
6 | 7 | <a-form-item label='{{ i18n "path" }}'> |
7 | 8 | <a-input v-model.trim="inbound.stream.xhttp.path"></a-input> |
8 | 9 | </a-form-item> |
9 | 10 | <a-form-item label='{{ i18n "pages.inbounds.stream.tcp.requestHeader" }}'> |
10 | | - <a-button icon="plus" size="small" @click="inbound.stream.xhttp.addHeader('', '')"></a-button> |
| 11 | + <a-button icon="plus" size="small" |
| 12 | + @click="inbound.stream.xhttp.addHeader('', '')"></a-button> |
11 | 13 | </a-form-item> |
12 | 14 | <a-form-item :wrapper-col="{span:24}"> |
13 | | - <a-input-group compact v-for="(header, index) in inbound.stream.xhttp.headers"> |
| 15 | + <a-input-group compact |
| 16 | + v-for="(header, index) in inbound.stream.xhttp.headers"> |
14 | 17 | <a-input :style="{ width: '50%' }" v-model.trim="header.name" |
15 | 18 | placeholder='{{ i18n "pages.inbounds.stream.general.name"}}'> |
16 | | - <template slot="addonBefore" :style="{ margin: '0' }">[[ index+1 ]]</template> |
| 19 | + <template slot="addonBefore" :style="{ margin: '0' }">[[ index+1 |
| 20 | + ]]</template> |
17 | 21 | </a-input> |
18 | 22 | <a-input :style="{ width: '50%' }" v-model.trim="header.value" |
19 | 23 | placeholder='{{ i18n "pages.inbounds.stream.general.value" }}'> |
20 | | - <a-button icon="minus" slot="addonAfter" size="small" @click="inbound.stream.xhttp.removeHeader(index)"></a-button> |
| 24 | + <a-button icon="minus" slot="addonAfter" size="small" |
| 25 | + @click="inbound.stream.xhttp.removeHeader(index)"></a-button> |
21 | 26 | </a-input> |
22 | 27 | </a-input-group> |
23 | 28 | </a-form-item> |
24 | 29 | <a-form-item label='Mode'> |
25 | 30 | <a-select v-model="inbound.stream.xhttp.mode" :style="{ width: '50%' }" |
26 | 31 | :dropdown-class-name="themeSwitcher.currentTheme"> |
27 | | - <a-select-option v-for="key in MODE_OPTION" :value="key">[[ key ]]</a-select-option> |
| 32 | + <a-select-option v-for="key in MODE_OPTION" :value="key">[[ key |
| 33 | + ]]</a-select-option> |
28 | 34 | </a-select> |
29 | 35 | </a-form-item> |
30 | | - <a-form-item label="Max Buffered Upload" v-if="inbound.stream.xhttp.mode === 'packet-up'"> |
31 | | - <a-input-number v-model.number="inbound.stream.xhttp.scMaxBufferedPosts"></a-input-number> |
| 36 | + <a-form-item label="Max Buffered Upload" |
| 37 | + v-if="inbound.stream.xhttp.mode === 'packet-up'"> |
| 38 | + <a-input-number |
| 39 | + v-model.number="inbound.stream.xhttp.scMaxBufferedPosts"></a-input-number> |
32 | 40 | </a-form-item> |
33 | | - <a-form-item label="Max Upload Size (Byte)" v-if="inbound.stream.xhttp.mode === 'packet-up'"> |
34 | | - <a-input v-model.trim="inbound.stream.xhttp.scMaxEachPostBytes"></a-input> |
| 41 | + <a-form-item label="Max Upload Size (Byte)" |
| 42 | + v-if="inbound.stream.xhttp.mode === 'packet-up'"> |
| 43 | + <a-input |
| 44 | + v-model.trim="inbound.stream.xhttp.scMaxEachPostBytes"></a-input> |
35 | 45 | </a-form-item> |
36 | | - <a-form-item label="Stream-Up Server" v-if="inbound.stream.xhttp.mode === 'stream-up'"> |
37 | | - <a-input v-model.trim="inbound.stream.xhttp.scStreamUpServerSecs"></a-input> |
| 46 | + <a-form-item label="Stream-Up Server" |
| 47 | + v-if="inbound.stream.xhttp.mode === 'stream-up'"> |
| 48 | + <a-input |
| 49 | + v-model.trim="inbound.stream.xhttp.scStreamUpServerSecs"></a-input> |
38 | 50 | </a-form-item> |
39 | 51 | <a-form-item label="Padding Bytes"> |
40 | 52 | <a-input v-model.trim="inbound.stream.xhttp.xPaddingBytes"></a-input> |
41 | 53 | </a-form-item> |
| 54 | + <a-form-item label="Padding Obfs Mode"> |
| 55 | + <a-switch v-model="inbound.stream.xhttp.xPaddingObfsMode"></a-switch> |
| 56 | + </a-form-item> |
| 57 | + <template v-if="inbound.stream.xhttp.xPaddingObfsMode"> |
| 58 | + <a-form-item label="Padding Key"> |
| 59 | + <a-input v-model.trim="inbound.stream.xhttp.xPaddingKey" |
| 60 | + placeholder="x_padding"></a-input> |
| 61 | + </a-form-item> |
| 62 | + <a-form-item label="Padding Header"> |
| 63 | + <a-input v-model.trim="inbound.stream.xhttp.xPaddingHeader" |
| 64 | + placeholder="X-Padding"></a-input> |
| 65 | + </a-form-item> |
| 66 | + <a-form-item label="Padding Placement"> |
| 67 | + <a-select v-model="inbound.stream.xhttp.xPaddingPlacement" |
| 68 | + :dropdown-class-name="themeSwitcher.currentTheme"> |
| 69 | + <a-select-option value>Default (queryInHeader)</a-select-option> |
| 70 | + <a-select-option |
| 71 | + value="queryInHeader">queryInHeader</a-select-option> |
| 72 | + <a-select-option value="header">header</a-select-option> |
| 73 | + </a-select> |
| 74 | + </a-form-item> |
| 75 | + <a-form-item label="Padding Method"> |
| 76 | + <a-select v-model="inbound.stream.xhttp.xPaddingMethod" |
| 77 | + :dropdown-class-name="themeSwitcher.currentTheme"> |
| 78 | + <a-select-option value>Default (repeat-x)</a-select-option> |
| 79 | + <a-select-option value="repeat-x">repeat-x</a-select-option> |
| 80 | + <a-select-option value="tokenish">tokenish</a-select-option> |
| 81 | + </a-select> |
| 82 | + </a-form-item> |
| 83 | + </template> |
| 84 | + <a-form-item label="Uplink HTTP Method"> |
| 85 | + <a-select v-model="inbound.stream.xhttp.uplinkHTTPMethod" |
| 86 | + :dropdown-class-name="themeSwitcher.currentTheme"> |
| 87 | + <a-select-option value>Default (POST)</a-select-option> |
| 88 | + <a-select-option value="POST">POST</a-select-option> |
| 89 | + <a-select-option value="PUT">PUT</a-select-option> |
| 90 | + <a-select-option value="GET">GET (packet-up only)</a-select-option> |
| 91 | + </a-select> |
| 92 | + </a-form-item> |
| 93 | + <a-form-item label="Session Placement"> |
| 94 | + <a-select v-model="inbound.stream.xhttp.sessionPlacement" |
| 95 | + :dropdown-class-name="themeSwitcher.currentTheme"> |
| 96 | + <a-select-option value>Default (path)</a-select-option> |
| 97 | + <a-select-option value="path">path</a-select-option> |
| 98 | + <a-select-option value="header">header</a-select-option> |
| 99 | + <a-select-option value="cookie">cookie</a-select-option> |
| 100 | + <a-select-option value="query">query</a-select-option> |
| 101 | + </a-select> |
| 102 | + </a-form-item> |
| 103 | + <a-form-item label="Session Key" |
| 104 | + v-if="inbound.stream.xhttp.sessionPlacement && inbound.stream.xhttp.sessionPlacement !== 'path'"> |
| 105 | + <a-input v-model.trim="inbound.stream.xhttp.sessionKey" |
| 106 | + placeholder="x_session"></a-input> |
| 107 | + </a-form-item> |
| 108 | + <a-form-item label="Sequence Placement"> |
| 109 | + <a-select v-model="inbound.stream.xhttp.seqPlacement" |
| 110 | + :dropdown-class-name="themeSwitcher.currentTheme"> |
| 111 | + <a-select-option value>Default (path)</a-select-option> |
| 112 | + <a-select-option value="path">path</a-select-option> |
| 113 | + <a-select-option value="header">header</a-select-option> |
| 114 | + <a-select-option value="cookie">cookie</a-select-option> |
| 115 | + <a-select-option value="query">query</a-select-option> |
| 116 | + </a-select> |
| 117 | + </a-form-item> |
| 118 | + <a-form-item label="Sequence Key" |
| 119 | + v-if="inbound.stream.xhttp.seqPlacement && inbound.stream.xhttp.seqPlacement !== 'path'"> |
| 120 | + <a-input v-model.trim="inbound.stream.xhttp.seqKey" |
| 121 | + placeholder="x_seq"></a-input> |
| 122 | + </a-form-item> |
| 123 | + <a-form-item label="Uplink Data Placement" |
| 124 | + v-if="inbound.stream.xhttp.mode === 'packet-up'"> |
| 125 | + <a-select v-model="inbound.stream.xhttp.uplinkDataPlacement" |
| 126 | + :dropdown-class-name="themeSwitcher.currentTheme"> |
| 127 | + <a-select-option value>Default (body)</a-select-option> |
| 128 | + <a-select-option value="body">body</a-select-option> |
| 129 | + <a-select-option value="header">header</a-select-option> |
| 130 | + <a-select-option value="query">query</a-select-option> |
| 131 | + </a-select> |
| 132 | + </a-form-item> |
| 133 | + <a-form-item label="Uplink Data Key" |
| 134 | + v-if="inbound.stream.xhttp.mode === 'packet-up' && inbound.stream.xhttp.uplinkDataPlacement && inbound.stream.xhttp.uplinkDataPlacement !== 'body'"> |
| 135 | + <a-input v-model.trim="inbound.stream.xhttp.uplinkDataKey" |
| 136 | + placeholder="x_data"></a-input> |
| 137 | + </a-form-item> |
| 138 | + <a-form-item label="Uplink Chunk Size" |
| 139 | + v-if="inbound.stream.xhttp.mode === 'packet-up' && inbound.stream.xhttp.uplinkDataPlacement && inbound.stream.xhttp.uplinkDataPlacement !== 'body'"> |
| 140 | + <a-input-number v-model.number="inbound.stream.xhttp.uplinkChunkSize" |
| 141 | + :min="0" placeholder="0 (unlimited)"></a-input-number> |
| 142 | + </a-form-item> |
42 | 143 | <a-form-item label="No SSE Header"> |
43 | 144 | <a-switch v-model="inbound.stream.xhttp.noSSEHeader"></a-switch> |
44 | 145 | </a-form-item> |
|
0 commit comments