Adding a better error message for really long common names Fixes #38
This commit is contained in:
parent
aca69ce03c
commit
62950128a2
|
@ -7,6 +7,7 @@
|
|||
.. moduleauthor:: Kevin Glisson <kglisson@netflix.com>
|
||||
|
||||
"""
|
||||
import re
|
||||
import ssl
|
||||
import base64
|
||||
from json import dumps
|
||||
|
@ -297,7 +298,7 @@ class CloudCAIssuerPlugin(IssuerPlugin, CloudCA):
|
|||
'ownerEmail': options['owner'],
|
||||
'caName': options['authority'].name,
|
||||
'csr': csr,
|
||||
'comment': options['description']
|
||||
'comment': re.sub(r'^[\w\-\s]+$', '', options['description'])
|
||||
}
|
||||
|
||||
response = self.post(endpoint, remove_none(cloudca_options))
|
||||
|
|
Loading…
Reference in New Issue