Merge pull request #1225 from infchaos/fixbug_fix_missing_parentheses_error_in_RegexPatterns

fix missing parentheses error in RegexPatterns.IpDPattern and RegexPatterns.IpEPattern
This commit is contained in:
NaBian authored and GitHub committed 2023-09-28 15:01:15 +08:00
commit 475a7600c5
1 file changed
+2 -2
@@ -56,7 +56,7 @@ public sealed class RegexPatterns
/// D类IP正则匹配
/// </summary>
public const string IpDPattern =
@"^(22[4-9]|23\d\."
@"^(22[4-9]|23\d)\."
+ @"(25[0-5]|2[0-4]\d|1\d{2}|[1-9]?\d)\."
+ @"(25[0-5]|2[0-4]\d|1\d{2}|[1-9]?\d)\."
+ @"(25[0-5]|2[0-4]\d|1\d{2}|[1-9]?\d)$";
@@ -65,7 +65,7 @@ public sealed class RegexPatterns
/// E类IP正则匹配
/// </summary>
public const string IpEPattern =
@"^(25[0-5]|24\d\."
@"^(25[0-5]|24\d)\."
+ @"(25[0-5]|2[0-4]\d|1\d{2}|[1-9]?\d)\."
+ @"(25[0-5]|2[0-4]\d|1\d{2}|[1-9]?\d)\."
+ @"(25[0-5]|2[0-4]\d|1\d{2}|[1-9]?\d)$";