mirror of
https://github.com/2dust/v2rayN.git
synced 2026-11-03 11:05:08 +03:00
feat: support custom headers for Xray HTTP outbounds (#9690)
* feat: support custom headers for Xray HTTP outbounds * feat: simplify HTTP outbound headers input * feat: validate JSON syntax in HTTP headers Keep HTTP outbound headers stored as raw text, while validating header names and values against RFC 9110/9112 syntax. Support string arrays for multi-value headers, reject duplicate JSON header keys, and clarify the invalid header JSON message. * feat: refactor HTTP header parsing into utility * Simplify code * Simplify code * Update CoreConfigV2rayServiceTests.cs --------- Co-authored-by: 2dust <31833384+2dust@users.noreply.github.com>
This commit is contained in:
@@ -256,6 +256,27 @@
|
||||
Grid.Column="1"
|
||||
Width="400"
|
||||
Margin="{StaticResource Margin4}" />
|
||||
|
||||
<TextBlock
|
||||
x:Name="tbHttpHeaders"
|
||||
Grid.Row="3"
|
||||
Grid.Column="0"
|
||||
Margin="{StaticResource Margin4}"
|
||||
VerticalAlignment="Center"
|
||||
IsVisible="False"
|
||||
Text="{x:Static resx:ResUI.TbHttpOutboundHeaders}"
|
||||
ToolTip.Tip="{x:Static resx:ResUI.TipHttpOutboundHeaders}" />
|
||||
<views:JsonEditor
|
||||
x:Name="txtHttpHeadersJson"
|
||||
Grid.Row="3"
|
||||
Grid.Column="1"
|
||||
Width="400"
|
||||
MinHeight="100"
|
||||
Margin="{StaticResource Margin4}"
|
||||
HorizontalAlignment="Stretch"
|
||||
VerticalAlignment="Center"
|
||||
IsVisible="False"
|
||||
ToolTip.Tip="{x:Static resx:ResUI.TipHttpOutboundHeaders}" />
|
||||
</Grid>
|
||||
<Grid
|
||||
x:Name="gridVLESS"
|
||||
|
||||
Reference in New Issue
Block a user