Merge pull request #12 from istvanp/patch-1

Allow whitespaces in domain ACL regex
This commit is contained in:
Chris 2017-08-29 12:41:58 +02:00 committed by GitHub
commit 009ba8ea7f
1 changed files with 2 additions and 2 deletions

View File

@ -57,8 +57,8 @@ from certbot import errors
from certbot_haproxy.util import MemoiseNoArgs
RE_HAPROXY_DOMAIN_ACL = re.compile(
r'\s*acl (?P<name>[0-9a-z_\-.]+) '
r'hdr\(host\) -i '
r'\s*acl\s+(?P<name>[0-9a-z_\-.]+)\s+'
r'(?:hdr\(host\)|req\.ssl_sni)\s+-i\s+'
r'(?P<domain>' # Start group "domain"
r'(?:[0-9-a-z](?:[a-z0-9-]{0,61}[a-z0-9]\.)+)' # (sub-)domain parts
r'(?:[0-9-a-z](?:[a-z0-9-]{0,61}[a-z0-9]))' # TLD part