Allow deeper nesting of hostnames

This commit is contained in:
2026-06-02 13:19:25 +00:00
parent 6f3c7338c7
commit cb03c811ef
2 changed files with 121 additions and 103 deletions

View File

@@ -20,7 +20,7 @@ class COIDParser {
const COID_VERSIONED = 3;
const COID_VERSION_WILDCARD = 4;
const REGEX_HOSTNAME = "/^([a-z0-9-]+\.)?[a-z0-9-]+\.[a-z]+$/";
const REGEX_HOSTNAME = "/^([a-z0-9-]+\.)*[a-z0-9-]+\.[a-z]+$/";
const REGEX_SEGMENT = "/^[A-Za-z-_0-9\.]+$/";
const REGEX_VERSION_WILDCARD = "/^((\^|~)(\d+\.)?\d|(\d+\.){1,2}\*)$/";