1
0
mirror of https://github.com/certbot/certbot.git synced 2026-01-26 07:41:33 +03:00
Commit Graph

10684 Commits

Author SHA1 Message Date
Brad Warren
c32da71e8a fail faster if we try to use candidate 2023-02-09 18:56:43 -08:00
Brad Warren
ca5f13d0e3 update snapcraft credentials 2023-02-09 18:55:29 -08:00
Brad Warren
91005a0422 always push to beta 2023-02-09 18:45:06 -08:00
Brad Warren
f91d3ca828 remove 1.32.x deps 2023-02-09 18:42:41 -08:00
Brad Warren
3512d15dff Remove most progressive release tooling 2023-02-09 18:41:16 -08:00
Will Greenberg
caad4d93d0 Merge pull request #9574 from certbot/remove-test-test-code
Remove code testing testing code
2023-02-09 12:03:06 -08:00
Brad Warren
aac02bef35 Remove code testing testing code 2023-02-08 20:55:59 -08:00
alexzorin
cbb4c871c2 docs: document reconfigure verb (#9563)
* docs: document reconfigure verb

* expand on the flags relevant to reconfigure

* Update phrasing

Co-authored-by: ohemorange <ebportnoy@gmail.com>

---------

Co-authored-by: ohemorange <ebportnoy@gmail.com>
2023-02-09 13:14:32 +11:00
ohemorange
99956ecab9 Fix typo direcory --> directory in --run-deploy-hooks help (#9568) 2023-02-08 16:16:28 -08:00
Brad Warren
d792d39813 reset set_by_cli between each test (#9567) 2023-02-09 09:24:07 +11:00
Brad Warren
f5ea5d453e fix requests-toolbelt warning (#9569) 2023-02-09 09:21:07 +11:00
Alexis
cd9ee996a8 Create SECURITY.md (#9566) 2023-02-09 07:12:15 +11:00
alexzorin
99184daff6 repin cryptography for openssl security update (#9565)
* repin cryptography for openssl security update

https://www.openssl.org/news/secadv/20230207.txt
https://cryptography.io/en/latest/changelog/#v39-0-1

* fix type hints

* remove outdated comments
2023-02-08 11:17:44 -08:00
ohemorange
23090198bf Configuration File Update w/o Certificate Issuance (#9355)
* Add command to update config files without issuing/renewing cert

* toss up a vague untested skeleton

* remove duplicated code

* set certname in config

* consistent name, no zope

* import copy

* reconsitute is in renewal

* import renewal

* import cli

* fix lint errors

* call choose_configurator_plugins for its side effect of writing to config

* Set certonly in choose config plugins as we do for renew

* rewrite by piggybacking on existing side effects of a dry run instead

* do not allow domains to be set while reconfiguring

* remove unused cert_manager.reconfigure

* remove unused imports

* Add comments and messages

* add cli information

* start adding tests

* remove test code

* get certname before setting up plugins

* get plugin from lineage if not set on cli

* import copy

* always reconstitute

* only load cert once

* add error message

* improve comment

* mock everything out for tests

* test functionality is working!

* add tests for adding and modifying hooks

* test that we don't modify the config if the dry run fails

* improve documentation

* add webroot to reconfigure common options

* lint and clean up intermediate artifacts

* mock validate_hooks for windows

* print success message with updated parameters

* Improve success message

* add message for no changes have been made

* improve changed message to show before as well

* syntax

* Add changes will apply at the next renewal message

* lint

* lint really likes dict.items() for some reason

* run the deploy hook

* turn off dry run to test deploy hook

* patch list_hooks call for tests

* factor out reporting results code

* Remove reporting of which values were changed

* add flag to run deploy hook despite doing a dry run, and recommend setting that to yes when running reconfigure and modifying the deploy hook

* missing () around multi-line string

* test if the two dicts are equal instead of finding the actual changes, thus avoiding having to deal with webroot_map being a list

* refer to --deploy-hook instead of deploy hook

* use renewal configuration instead of configuration information

* mention that the deploy hook will use the active cert not the test one

* disable lint and remove new from language asking about running a deploy hook

* pluralize run deploy hook(s)

* Add test for reporting results when there is a webroot map

* update changelog

* Update error message about modifying domains on the certificate

* update changelog

* Add basic integration tests

* Just set -a rather than redoing the whole testing infrastructure

* used webroot in integration test since it's already installed

* file contents are accessed twice now

---------

Co-authored-by: Alex Zorin <alex@zorin.au>
2023-02-04 08:46:08 +11:00
alexzorin
724635bbbd docs: generate a man page with a structure (#9561)
If you looked at [the Debian man page for Certbot](https://manpages.debian.org/bullseye/certbot/certbot.1.en.html) or [the FreeBSD one](https://man.freebsd.org/cgi/man.cgi?query=certbot&sektion=1&apropos=0&manpath=FreeBSD+13.1-RELEASE+and+Ports), you will notice that the entire document is in the "NAME" section. It looks weird in particular on the [FreeBSD man page listing](https://man.freebsd.org/cgi/man.cgi?query=certbot&apropos=1&sektion=0&manpath=FreeBSD+13.1-RELEASE+and+Ports&arch=default&format=html).

This PR adds some structure to the man page by adding a new "Synopsis" section (lifted from the Certbot snap's synopsis) and shoving the `certbot --help all` output into a new "Options" section. I think this should be sustainable for us, without having to worry about the man page in particular.

Fixes #9560.
2023-02-03 11:35:15 -08:00
Daniel McMahon
71a14f5193 Fix docs google permissions (#9556)
* include project level IAM requirements

* add name to authors.md

* Update certbot-dns-google/certbot_dns_google/__init__.py

Co-authored-by: alexzorin <alex@zorin.au>

* Update certbot-dns-google/certbot_dns_google/__init__.py

Co-authored-by: alexzorin <alex@zorin.au>

* Update certbot-dns-google/certbot_dns_google/__init__.py

Co-authored-by: alexzorin <alex@zorin.au>

---------

Co-authored-by: Daniel McMahon <daniel@igloocontrols.com>
Co-authored-by: alexzorin <alex@zorin.au>
2023-02-02 07:59:35 +11:00
alexzorin
cea717db3e docs: update -d flag copy to be CA-agnostic (#9542)
Some confusion ensued in [this community thread](https://community.letsencrypt.org/t/connection-between-ios-9-support-and-subject-common-name-or-x509v3-subject-alternative-name-critical/191619) about the Subject CN, which Certbot omits from the CSR, Let's Encrypt includes in the issued certificate, but some other CAs do not. 

It's probably for the best that we do not entomb Let's Encrypt's current issuance practices in Certbot's documentation.
2023-02-01 10:49:37 -08:00
alexzorin
e75dc1dfd0 show_account: display account thumbprint (#9540)
In #9127, where @osirisinferi added the `show_account` verb, I made a call not to include the thumbprint in the output of `certbot show_account`.

In hindsight, and after a community member asked for this feature, I think it's better to include it. 

It is useful on occasion and `show_account` is fairly specialized anyway. It's only really good for getting your account URL for rate limit increases, checking your contacts, and (now) and doing *magic* with the thumbprint for stateless/distributed HTTP-01 responders.

Without this feature, a clever user might figure out their thumbprint by doing a `certonly --manual --preferred-challenges http` request, but most users would probably be lost.

* show_account: display account thumbprint

* use local key for display
2023-02-01 10:48:13 -08:00
Brad Warren
1b1b27df28 Change coverage upload condition (#9552)
* change coverage upload condition

* fix typo

* set uploadCoverage

* add comment

* change coverage upload condition

* verbose version
2023-02-01 17:08:43 +11:00
Brad Warren
00f8d82808 double progressive percentage (#9557) 2023-02-01 07:05:01 +11:00
Will Greenberg
8226d30af0 Bump up the number of operations to 30 (#9554)
This is the default value, which is sensible since an "operation"
basically corresponds to a GH API call, and 1 won't really let us
do anything.
2023-01-28 08:16:15 +11:00
alexzorin
f0b6ba072f certbot-ci: boulder only supports port 80 for http-01 (#9548)
* certbot-ci: boulder will now only supports port 80 for http-01

* forgot to actually use the http_01_port argument

* print the port the proxy listens on

* try allow binding to privileged ports
2023-01-27 14:44:17 +11:00
Will Greenberg
99fea03c50 Merge pull request #9541 from certbot/remove-legacy-new-authz-support
account: stop storing legacy new_authzr_uri
2023-01-26 17:52:33 -08:00
Alex Zorin
08e008ac54 remove unused attributes from test 2023-01-27 10:41:45 +11:00
Alex Zorin
2e3cace739 remove docstring for removed argument 2023-01-27 10:38:00 +11:00
Alex Zorin
f3c6f7d46e Merge remote-tracking branch 'origin/master' into remove-legacy-new-authz-support 2023-01-27 09:04:16 +11:00
Will Greenberg
b0748b69e7 Replace probot/stale app with a Github Action (#9466)
* Replace probot/stale app with a Github Action

This creates a Github Actions workflow which seems to be the supported
way of automarking issues as stale. Adds a dry-run flag to test it out.

* small fixups

* cron typo

* disable unnecessary permissions

* use friendlier name
2023-01-25 15:59:22 -08:00
Brad Warren
c79a5d4407 Start sending coverage data to codecov (#9544)
* set up codecov

* export coverage data to xml
2023-01-26 08:15:51 +11:00
Brad Warren
4ad71ab5ae Fix tox environments (#9547)
* fix cover tox envs

* make test work on all Pythons

* Remove unused import

Co-authored-by: alexzorin <alex@zorin.id.au>

Co-authored-by: alexzorin <alex@zorin.id.au>
2023-01-25 12:00:06 +11:00
Will Greenberg
81ff6fcc0d acme.messages.Error: add mutability (#9546)
* acme.messages.Error: add mutability

As of Python 3.11, an exception caught within a `with` statement will
update the __traceback__ attribute. Because acme.messages.Error was
immutable, this was causing a knock-on exception, causing certbot to
exit abnormally. This commit hacks in mutability for acme.messages.Error

Fixes #9539

* Add CHANGELOG entry
2023-01-25 09:06:53 +11:00
Brad Warren
613e698199 disable random sleep in lock_test.py (#9545) 2023-01-25 08:05:01 +11:00
Alex Zorin
554143e187 fix lint 2023-01-23 19:43:34 +11:00
Alex Zorin
6505054f62 account: stop storing legacy new_authzr_uri 2023-01-23 18:41:25 +11:00
alexzorin
be3bf316c0 Deprecate {csr, keys} dirs & automatically truncate lineages (#9537)
Based on my design [here](https://docs.google.com/document/d/1jGh_bZPnrhi96KzuIcyCJfnudl4m3pRPGkiK4fTo8e4/edit?usp=sharing). 

Fixes https://github.com/certbot/certbot/issues/4634 and https://github.com/certbot/certbot/issues/4635.

- [x] Deprecate `NamespaceConfig.csr_dir`,`NamespaceConfig.key_dir`, ~~`constants.CSR_DIR` and `constants.KEY_DIR`~~. (`constants` is `_internal` so we can just delete it eventually).
- [x] Update `certbot.crypto_util.generate_csr` and `.generate_key` to make `csr_dir` and `key_dir` optional, respectively.
- [x] Change `certbot._internal.client.Client.obtain_certificate` to no longer include `csr_dir` and `key_dir` to the `.generate_csr` and `.generate_key` calls, respectively.
- Automatically delete unwanted lineage items:
  - [x] In `certbot._internal.storage.RenewableCert`, add a function to truncate the lineage history according to the criteria (keep the current and the 5 prior certificates). 
      - [x] Add a test suite for `truncate` 
  - [x] In `certbot._internal.renewal.renew_cert`, call the lineage truncation function after the symlinks have been updated for the renewal.


* Stop writing new files to /csr and /keys

* storage: add lineage truncation

* remove unused code

* deprecate keys_dir and csr_dir

* update CHANGELOG

* just keep 5 prior certificates, dont be clever with expiry

* docs: remove reference to /archive and /keys

* filter {csr,key}_dir deprecations directly in tests
2023-01-19 17:21:26 -08:00
alexzorin
e7fcd0e08d docs: give webroot and standalone better descriptions (#9536) 2023-01-12 08:03:51 -08:00
alexzorin
8149e255c8 Merge pull request #9534 from certbot/candidate-2.2.0
Update files from 2.2 release
2023-01-12 15:11:23 +11:00
Brad Warren
32a233d93b Bump version to 2.3.0 2023-01-11 13:21:23 -08:00
Brad Warren
a63bf5f88b Add contents to certbot/CHANGELOG.md for next version 2023-01-11 13:21:23 -08:00
Brad Warren
4ab4c9b65d Release 2.2.0 v2.2.0 2023-01-11 13:21:22 -08:00
Brad Warren
b56df2fdd9 Update changelog for 2.2.0 release 2023-01-11 13:20:17 -08:00
Brad Warren
b1f22aa8a2 Add progressive release tooling (#9532)
This is based on what I wrote at https://opensource.eff.org/eff-open-source/pl/k1b4pcxnifyj9m7o4wdq7cka8h.
2023-01-11 12:27:38 -08:00
alexzorin
d641f062f2 limit challenge polling to 30 minutes (#9527)
* limit challenge polling to 30 minutes

* Fix docstring typo

Co-authored-by: Brad Warren <bmw@users.noreply.github.com>

Co-authored-by: Brad Warren <bmw@users.noreply.github.com>
2023-01-06 09:24:58 +11:00
Brad Warren
666e12b25d upgrade shellingham (#9529) 2023-01-05 19:30:47 +11:00
Alex Bouma
b81ef33f33 Add link to dns-dnsmanager third party plugin (#9523) 2022-12-25 09:07:12 +11:00
Brad Warren
8155d60e9a remove setuptools pin (#9520) 2022-12-21 10:59:41 +11:00
Brad Warren
124e6d80c3 separate cover environment to workaround tox bug (#9519) 2022-12-19 13:38:04 -08:00
Brad Warren
ac75977156 update 1.32.x reqs (#9516) 2022-12-18 08:16:36 +11:00
alexzorin
63ff1f2a3a Merge pull request #9517 from certbot/candidate-1.32.2
Update master from 1.32.2 release
2022-12-18 08:13:52 +11:00
Brad Warren
74af586f4b Merge branch 'master' into candidate-1.32.2 2022-12-16 14:16:58 -08:00
Brad Warren
c3e1d7e560 Bump version to 2.2.0 2022-12-16 12:46:36 -08:00