mirror of
https://github.com/2dust/v2rayN.git
synced 2026-03-22 00:08:16 +05:00
Ignore json file extensions in IsDomain
This commit is contained in:
@@ -497,6 +497,13 @@ public class Utils
|
||||
return false;
|
||||
}
|
||||
|
||||
var ext = Path.GetExtension(domain);
|
||||
if (ext.IsNotEmpty()
|
||||
&& ext[1..].ToLowerInvariant() is "json" or "txt" or "xml" or "cfg" or "ini" or "log" or "yaml" or "yml" or "toml")
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
return Uri.CheckHostName(domain) == UriHostNameType.Dns;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user