Commit Graph
9095 Commits
Author SHA1 Message Date
Brad Warren 22858c6025 Bump version to 0.29.0 2018-11-07 13:22:59 -08:00
Brad Warren c1300a8e1b Release 0.28.0 v0.28.0 2018-11-07 13:22:57 -08:00
Brad Warren f3ff548a41 Update changelog for 0.28.0 release. 2018-11-07 13:02:25 -08:00
Adrien FerrandandBrad Warren e6e323e3ff Update Lexicon to correct use of HTTP proxy on OVH provider (#6479)
This PR update requirement of Lexicon to 2.7.14 on OVH plugin, to allow HTTP proxy to be used correctly when underlying OVH provider is invoked.

* Update Lexicon to correct use of HTTP proxy on OVH provider

* Update dev_constraints.txt

* Update CHANGELOG.md
2018-11-07 07:49:13 -08:00
Adrien FerrandandBrad Warren 4edfb3ef65 [Windows] Handle file renaming when the destination path already exists (#6415)
On Linux, you can invoke os.rename(src, dst) even if dst already exists. In this case, destination file will be atomically replaced by the source file.

On Windows, this will lead to an OSError because changes are not atomic. This cause certbot renew to fail in particular, because the old certificate configuration needs to be replace by the new when a certificate is effectively renewed.

One could use the cross-platform function os.replace, but it is available only on Python >= 3.3.

This PR add a function in compat to handle correctly this case on Windows, and delegating everything else to os.rename.

* Cross platform compatible os.rename (we can use os.replace if its python 3)

* Use os.replace instead of custom non-atomic code.

* Avoid errors for lint and mypy. Add a test.
2018-11-06 15:35:09 -08:00
Erica Portnoy 92989956f9 no newline in py27 2018-11-05 17:47:38 -08:00
Erica Portnoy 39a008eb83 ignore our own TLS-SNI-01 warning 2018-11-05 17:42:19 -08:00
Erica Portnoy 91b3c5d61c remove pytest.mark, move to specific ignore in pytest.ini 2018-11-05 17:41:26 -08:00
Erica Portnoy c3fa05ba74 remove unused six imports 2018-11-05 17:38:29 -08:00
Erica Portnoy 5dc9dd8dea Pin requests' dependencies in certbot-auto 2018-11-05 17:34:33 -08:00
Erica Portnoy 6c8652a0a6 add comment explaining about boto* in oldest_constraints.txt 2018-11-05 17:30:26 -08:00
Erica Portnoy b7f4b33ffb Remove module-level ignore::ResourceWarnings 2018-11-05 17:28:26 -08:00
Erica Portnoy 79b2ea19fb no need for U flag because we won't support py2 on windows 2018-11-05 17:19:57 -08:00
Erica Portnoy 9cc5d18b97 Merge branch 'master' into warnings-are-errors 2018-11-05 17:17:51 -08:00
ohemorangeandBrad Warren 47062dbfbf update changelog (#6476) 2018-11-05 17:09:03 -08:00
Erica Portnoy 0e98904bec Merge branch 'master' into warnings-are-errors 2018-11-05 16:57:50 -08:00
ohemorangeandBrad Warren cbdc2ee23b Log warning about TLS-SNI deprecation in Certbot (#6468)
For #6319.

* print warning in auth_handler

* add test
2018-11-05 15:01:16 -08:00
ohemorangeandGitHub cb8dd8a428 Warn when using deprecated acme.challenges.TLSSNI01 (#6469)
* Warn when using deprecated acme.challenges.TLSSNI01

* Update changelog

* remove specific date from warning

* add a raw assert for mypy optional type checking
2018-11-05 14:50:20 -08:00
Adrien FerrandandBrad Warren bc7763dd0f Lexicon v3 compatibility (#6474)
* Propagate correctly domain to lexicon providers

* Pass required parameter to ovh provider

* Fix all other lexicon-based dns plugins
2018-11-05 14:07:09 -08:00
ohemorangeandBrad Warren 9403c1641d Stop preferring TLS-SNI in the Apache, Nginx, and standalone plugins (#6461)
* flip challenge preference in Nginx

* Fix Nginx tests

* Flip challenge preference in Apache

* Flip challenge preference in standalone

* update changelog

* continue to run with tls-sni in integration tests for coverage
2018-11-05 13:58:56 -08:00
Georgio NicolasandGitHub 9fa0a58545 Remove mention of TLS-SNI-01 2018-11-04 01:29:38 -04:00
Georgio NicolasandGitHub 94f0a915c0 Remove mentioning of TLS-SNI-01 2018-11-04 01:23:47 -04:00
ohemorangeandGitHub 2c1964c639 Use the ACMEv2 newNonce endpoint when a new nonce is needed (#6442)
Also, add checking to the newNonce HEAD request, and check responses in general before attempting to save a nonce, for a better error message.

* check response before adding nonce to the pool

* fix tests so that they test what they're supposed to test, and also allow the order of _add_nonce and _check_response to be switched

* make _get_nonce take acme_version

* Send HEAD to newNonce endpoint when using ACMEv2

* check the HEAD newNonce response

* remove unnecessary try; get returns None if the item doesn't exist

* instead of setting new_nonce_url on ClientNetwork, use the saved directory in ClientBase and pass that into ClientNetwork.post

* no need to test acme_version in _get_nonce

* pop new_nonce_url out of kwargs before passing to _send_request
2018-11-02 17:32:33 -07:00
Erica Portnoy eab7aa7bf1 Update changelog 2018-11-02 16:14:10 -07:00
Erica Portnoy bbf89781c9 Merge branch 'master' into warnings-are-errors 2018-11-02 16:12:39 -07:00
Erica Portnoy c98bf18a77 Use older version of boto in oldest tests, because new versions can't handle old versions of requests 2018-11-02 16:00:32 -07:00
Erica Portnoy 0caaf872fb bring requests back down to 2.4.1 in setup and oldest constraints 2018-11-02 15:53:44 -07:00
Erica Portnoy ac8d6f58bb Update requests version in oldest-constraints.txt 2018-11-02 15:30:42 -07:00
Erica Portnoy 1228f5da99 update letsencrypt-auto 2018-11-02 14:59:29 -07:00
Erica Portnoy 64a61fa6d4 Use a newer version of botocore that doesn't vendor requests, which we need because newer versions of requests don't have the DeprecationWarning 2018-11-02 14:53:55 -07:00
Erica Portnoy 1b595f26d8 Requests no longer vendorizes urllib3 2018-11-02 13:31:48 -07:00
Erica Portnoy a83afb6135 properly disable no-member 2018-11-02 13:31:04 -07:00
Erica Portnoy e37a8fbded Use a newer version of requests because of the upcoming Callable import Deprecation in Python 3.8 that warns in Python 3.7 2018-11-02 13:01:14 -07:00
Erica Portnoy d02ea812a5 Cover is run on 2.7, so mark 3-only lines as no cover 2018-11-02 12:36:42 -07:00
Erica Portnoy 28c117abe0 If ResourceWarning is specified in pytest.ini, tests fail on Python3. We should be catching all of them, and they usually fail to successfully error anyway, so this just means we get sligthly worse error messages when they do occur. 2018-11-02 12:31:55 -07:00
Joona HoikkalaandBrad Warren a1af42bc5f Dummy AWS credentials for Route53 tests to prevent outbound connections (#6456)
Boto3 / botocore library has a feature that tries to fetch AWS credentials from IAM if a set of credentials isn't available otherwise. This happens when boto loops through different credential providers in order to find the keys. See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=912103

This PR simply adds dummy environmental variables for the tests that will be picked up by the credential provider iterator in order to prevent making outbound connections.

* Hardcode dummy AWS credentials to prevent boto3 making outgoing connections

* Remove the dummy credentials when tearing down test case
2018-11-02 09:59:27 -07:00
Erica Portnoy 36b6328acd Ignore ResourceWarnings in various modules in a 2-compatible way.
Sometimes tests are flaky about giving this warning, particularly in ACME. I recommend just ignoring them.
2018-11-01 17:56:01 -07:00
Erica Portnoy c699a50983 Ignore all ResourceWarnings in log_test.py 2018-11-01 17:35:12 -07:00
Erica Portnoy a5e26ca890 Ignore all ResourceWarnings in main_test.py, since they're flaky 2018-11-01 17:32:59 -07:00
Erica Portnoy de1554f785 Ignore more warnings. These are the ones I'm less sure about 2018-11-01 17:28:40 -07:00
Erica Portnoy 6e7d42f298 ignore ResourceWarnings in acme tests 2018-11-01 17:17:19 -07:00
Erica Portnoy 36e8d748a1 Clean up many warnings 2018-11-01 16:39:54 -07:00
Erica Portnoy 49619fc0ab Error on warning, unless it's a ResourceWarning 2018-11-01 16:39:29 -07:00
Erica Portnoy 6f662fa489 ignore deprecation and resource warnings in certbot-dns-rfc2136, which are inherited from dnspython 2018-11-01 16:39:01 -07:00
Erica Portnoy 1eabb4bae3 warn-->warning 2018-10-31 18:11:43 -07:00
Erica Portnoy 35510bfc6c assertNotEquals --> assertNotEqual 2018-10-31 17:59:44 -07:00
Erica Portnoy b837f218c9 U mode on open --> newline=None 2018-10-31 17:59:24 -07:00
Erica Portnoy a5e0e801be correctly use getfullargspec 2018-10-31 17:49:50 -07:00
Erica Portnoy 594fbe3ae8 disable pylint no-member for x-version 2018-10-31 17:33:39 -07:00
Erica Portnoy 2ddf47e3cc assertEquals --> assertEqual 2018-10-31 17:28:47 -07:00