Browse Source

New - Splithttp (xPaddingBytes)

mhsanaei 2 months ago
parent
commit
2471bda211
2 changed files with 7 additions and 0 deletions
  1. 4 0
      web/assets/js/model/xray.js
  2. 3 0
      web/html/xui/form/stream/stream_splithttp.html

+ 4 - 0
web/assets/js/model/xray.js

@@ -559,6 +559,7 @@ class SplitHTTPStreamSettings extends XrayCommonClass {
         scMaxEachPostBytes = "1000000-2000000",
         scMinPostsIntervalMs = "10-50",
         noSSEHeader = false,
+        xPaddingBytes = "100-1000",
     ) {
         super();
         this.path = path;
@@ -568,6 +569,7 @@ class SplitHTTPStreamSettings extends XrayCommonClass {
         this.scMaxEachPostBytes = scMaxEachPostBytes;
         this.scMinPostsIntervalMs = scMinPostsIntervalMs;
         this.noSSEHeader = noSSEHeader;
+        this.xPaddingBytes = xPaddingBytes;
     }
 
     addHeader(name, value) {
@@ -587,6 +589,7 @@ class SplitHTTPStreamSettings extends XrayCommonClass {
             json.scMaxEachPostBytes,
             json.scMinPostsIntervalMs,
             json.noSSEHeader,
+            json.xPaddingBytes,
         );
     }
 
@@ -599,6 +602,7 @@ class SplitHTTPStreamSettings extends XrayCommonClass {
             scMaxEachPostBytes: this.scMaxEachPostBytes,
             scMinPostsIntervalMs: this.scMinPostsIntervalMs,
             noSSEHeader: this.noSSEHeader,
+            xPaddingBytes: this.xPaddingBytes,
         };
     }
 }

+ 3 - 0
web/html/xui/form/stream/stream_splithttp.html

@@ -28,6 +28,9 @@
     <a-form-item label="Min Upload Interval (Ms)">
         <a-input v-model.trim="inbound.stream.splithttp.scMinPostsIntervalMs"></a-input>
     </a-form-item>
+    <a-form-item label="Padding Bytes">
+        <a-input v-model.trim="inbound.stream.splithttp.xPaddingBytes"></a-input>
+    </a-form-item>
     <a-form-item label="No SSE Header">
         <a-switch v-model="inbound.stream.splithttp.noSSEHeader"></a-switch>
     </a-form-item>