mirror of
https://github.com/certbot/certbot.git
synced 2026-08-01 02:44:21 +02:00
Update configuration.py
This commit is contained in:
@@ -157,6 +157,6 @@ def _check_config_domain_sanity(domains):
|
|||||||
# http://www.mkyong.com/regular-expressions/domain-name-regular-expression-example/
|
# http://www.mkyong.com/regular-expressions/domain-name-regular-expression-example/
|
||||||
# Characters used, domain parts < 63 chars, tld > 1 < 7 chars
|
# Characters used, domain parts < 63 chars, tld > 1 < 7 chars
|
||||||
# first and last char is not "-"
|
# first and last char is not "-"
|
||||||
fqdn = re.compile("^((?!-)[A-Za-z0-9-]{1,63}(?<!-)\\.)+[A-Za-z]{2,6}$")
|
fqdn = re.compile("^((?!-)[A-Za-z0-9-]{1,63}(?<!-)\\.)+[A-Za-z]{2,12}$")
|
||||||
if any(True for d in domains if not fqdn.match(d)):
|
if any(True for d in domains if not fqdn.match(d)):
|
||||||
raise errors.ConfigurationError("Requested domain is not a FQDN")
|
raise errors.ConfigurationError("Requested domain is not a FQDN")
|
||||||
|
|||||||
Reference in New Issue
Block a user