Merge pull request #2809 from letsencrypt/domain-ordering

Preserve domain ordering in CSR
This commit is contained in:
schoen
2016-04-28 14:34:12 -07:00
2 changed files with 5 additions and 3 deletions
+3 -2
View File
@@ -245,8 +245,9 @@ class Client(object):
domains,
self.config.allow_subset_of_names)
domains = [a.body.identifier.value.encode('ascii')
for a in authzr]
auth_domains = set(a.body.identifier.value.encode('ascii')
for a in authzr)
domains = [d for d in domains if d in auth_domains]
# Create CSR from names
key = crypto_util.init_save_key(
+2 -1
View File
@@ -201,7 +201,8 @@ class ClientTest(unittest.TestCase):
authzr = []
for domain in domains:
# domain ordering should not be affected by authorization order
for domain in reversed(domains):
authzr.append(
mock.MagicMock(
body=mock.MagicMock(