Compare commits

...

3 Commits

Author SHA1 Message Date
Martin Hauser
9f16734266 fix(utilities): Allow single-digit port numbers in URL validator
Change port number regex from `\d{2,5}` to `\d{1,5}` to permit valid
single-digit ports (1-9). This aligns with RFC 3986 and fixes
validation for URLs using ports like :8 or :9.

Fixes #21698
2026-03-20 13:40:40 +01:00
Jeremy Stretch
2bf187c061 Cleanup
CI / build (20.x, 3.14) (push) Failing after 13s
CI / build (20.x, 3.13) (push) Failing after 15s
CI / build (20.x, 3.12) (push) Failing after 17s
2026-03-18 16:24:44 -04:00
Jeremy Stretch
7163840279 #20923: Migrate remaining DCIM views to new UI layouts 2026-03-18 12:31:54 -04:00
+1 -1
View File
@@ -34,7 +34,7 @@ class EnhancedURLValidator(URLValidator):
r'^(?:[a-z0-9\.\-\+]*)://' # Scheme (enforced separately)
r'(?:\S+(?::\S*)?@)?' # HTTP basic authentication
r'(?:' + '|'.join(host_res) + ')' # IPv4, IPv6, FQDN, or hostname
r'(?::\d{2,5})?' # Port number
r'(?::\d{1,5})?' # Port number
r'(?:[/?#][^\s]*)?' # Path
r'\Z', re.IGNORECASE)
schemes = None