Do not allow NULL terminators in the middle of alt name for pattern matching. ZD 17987

This commit is contained in:
Colton Willey
2024-05-14 16:59:28 -07:00
parent 28bd4ebeea
commit 676dfb7edb

View File

@ -12386,6 +12386,8 @@ int MatchDomainName(const char* pattern, int len, const char* str)
while (--len > 0) {
p = (char)XTOLOWER((unsigned char)*pattern);
pattern++;
if (p == '\0' && len > 0)
return 0;
if (p != '*')
break;
}