diff --git a/v2rayN/ServiceLib/Global.cs b/v2rayN/ServiceLib/Global.cs index 48df5d22..f962efe1 100644 --- a/v2rayN/ServiceLib/Global.cs +++ b/v2rayN/ServiceLib/Global.cs @@ -265,7 +265,8 @@ namespace ServiceLib "utp", "wechat-video", "dtls", - "wireguard" + "wireguard", + "dns" ]; public static readonly List CoreTypes = diff --git a/v2rayN/ServiceLib/Models/V2rayConfig.cs b/v2rayN/ServiceLib/Models/V2rayConfig.cs index b6ecf52b..e3fa0fd3 100644 --- a/v2rayN/ServiceLib/Models/V2rayConfig.cs +++ b/v2rayN/ServiceLib/Models/V2rayConfig.cs @@ -291,6 +291,8 @@ namespace ServiceLib.Models public object request { get; set; } public object response { get; set; } + + public string? domain { get; set; } } public class KcpSettings4Ray diff --git a/v2rayN/ServiceLib/Services/CoreConfig/CoreConfigV2rayService.cs b/v2rayN/ServiceLib/Services/CoreConfig/CoreConfigV2rayService.cs index 46c99e97..f07a9c94 100644 --- a/v2rayN/ServiceLib/Services/CoreConfig/CoreConfigV2rayService.cs +++ b/v2rayN/ServiceLib/Services/CoreConfig/CoreConfigV2rayService.cs @@ -915,7 +915,8 @@ namespace ServiceLib.Services.CoreConfig kcpSettings.writeBufferSize = _config.KcpItem.WriteBufferSize; kcpSettings.header = new Header4Ray { - type = node.HeaderType + type = node.HeaderType, + domain = host.IsNullOrEmpty() ? null : host }; if (Utils.IsNotEmpty(path)) {