Skip to content

Commit bc2085b

Browse files
jshacpu
authored andcommitted
Default to DNS challenge in chisel and chisel2. (letsencrypt#3621)
This allows these tools to easily be run in command line mode from the host machine against a Boulder running inside docker-compose up without modifying the FAKE_DNS field in docker-compose.yml. This allows for easier testing of various conditions.
1 parent cc5ec34 commit bc2085b

File tree

4 files changed

+8
-2
lines changed

4 files changed

+8
-2
lines changed

test/chisel.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def cleanup():
190190
thread.join()
191191
return cleanup
192192

193-
def auth_and_issue(domains, chall_type="http-01", email=None, cert_output=None, client=None):
193+
def auth_and_issue(domains, chall_type="dns-01", email=None, cert_output=None, client=None):
194194
"""Make authzs for each of the given domains, set up a server to answer the
195195
challenges in those authzs, tell the ACME server to validate the challenges,
196196
then poll for the authzs to be ready and issue a cert."""

test/chisel2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ def http_01_answer(client, chall_body):
9393
chall=chall_body.chall, response=response,
9494
validation=validation)
9595

96-
def auth_and_issue(domains, chall_type="http-01", email=None, cert_output=None, client=None):
96+
def auth_and_issue(domains, chall_type="dns-01", email=None, cert_output=None, client=None):
9797
"""Make authzs for each of the given domains, set up a server to answer the
9898
challenges in those authzs, tell the ACME server to validate the challenges,
9999
then poll for the authzs to be ready and issue a cert."""

test/integration-test.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,9 @@ def test_multidomain():
148148
def test_dns_challenge():
149149
auth_and_issue([random_domain(), random_domain()], chall_type="dns-01")
150150

151+
def test_http_challenge():
152+
auth_and_issue([random_domain(), random_domain()], chall_type="http-01")
153+
151154
def test_issuer():
152155
"""
153156
Issue a certificate, fetch its chain, and verify the chain and

test/v2_integration.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ def test_wildcardmultidomain():
3838
"""
3939
chisel2.auth_and_issue([random_domain(), "*."+random_domain()], chall_type="dns-01")
4040

41+
def test_http_challenge():
42+
chisel2.auth_and_issue([random_domain(), random_domain()], chall_type="http-01")
43+
4144
def test_overlapping_wildcard():
4245
"""
4346
Test issuance for a random domain and a wildcard version of the same domain

0 commit comments

Comments
 (0)