@@ -52,11 +52,20 @@ public abstract class StandardV2RayBean extends AbstractBean {
5252
5353 public Boolean enableECH ;
5454
55+ public String echConfig ;
56+
57+ // sing-box 不再使用
5558 public Boolean enablePqSignature ;
5659
5760 public Boolean disabledDRS ;
5861
59- public String echConfig ;
62+ // --------------------------------------- Mux
63+
64+ public Boolean enableMux ;
65+ public Boolean muxPadding ;
66+ public Integer muxType ;
67+ public Integer muxConcurrency ;
68+
6069
6170 // --------------------------------------- //
6271
@@ -101,11 +110,16 @@ public void initializeDefaultValues() {
101110 if (JavaUtil .isNullOrBlank (echConfig )) echConfig = "" ;
102111 if (enablePqSignature == null ) enablePqSignature = false ;
103112 if (disabledDRS == null ) disabledDRS = false ;
113+
114+ if (enableMux == null ) enableMux = false ;
115+ if (muxPadding == null ) muxPadding = false ;
116+ if (muxType == null ) muxType = 0 ;
117+ if (muxConcurrency == null ) muxConcurrency = 1 ;
104118 }
105119
106120 @ Override
107121 public void serialize (ByteBufferOutput output ) {
108- output .writeInt (1 );
122+ output .writeInt (2 );
109123 super .serialize (output );
110124 output .writeString (uuid );
111125 output .writeString (encryption );
@@ -160,6 +174,11 @@ public void serialize(ByteBufferOutput output) {
160174 }
161175
162176 output .writeInt (packetEncoding );
177+
178+ output .writeBoolean (enableMux );
179+ output .writeBoolean (muxPadding );
180+ output .writeInt (muxType );
181+ output .writeInt (muxConcurrency );
163182 }
164183
165184 @ Override
@@ -239,6 +258,13 @@ public void deserialize(ByteBufferInput input) {
239258 }
240259
241260 packetEncoding = input .readInt ();
261+
262+ if (version >= 2 ) {
263+ enableMux = input .readBoolean ();
264+ muxPadding = input .readBoolean ();
265+ muxType = input .readInt ();
266+ muxConcurrency = input .readInt ();
267+ }
242268 }
243269
244270 @ Override
@@ -251,6 +277,10 @@ public void applyFeatureSettings(AbstractBean other) {
251277 bean .enableECH = enableECH ;
252278 bean .disabledDRS = disabledDRS ;
253279 bean .echConfig = echConfig ;
280+ bean .enableMux = enableMux ;
281+ bean .muxPadding = muxPadding ;
282+ bean .muxType = muxType ;
283+ bean .muxConcurrency = muxConcurrency ;
254284 }
255285
256286 public boolean isVLESS () {
0 commit comments