mirror of
https://github.com/certbot/certbot.git
synced 2026-06-15 11:39:12 -04:00
we dont care
This commit is contained in:
parent
5e193eb12f
commit
1155e1b0c1
5 changed files with 149 additions and 2 deletions
|
|
@ -921,3 +921,24 @@ def test_preferred_chain(context: IntegrationTestsContext) -> None:
|
|||
with open(conf_path, 'r') as f:
|
||||
assert 'preferred_chain = {}'.format(requested) in f.read(), \
|
||||
'Expected preferred_chain to be set in renewal config'
|
||||
|
||||
|
||||
def test_ancient_rsa_key_type_preserved(context: IntegrationTestsContext) -> None:
|
||||
certname = context.get_domain('newname')
|
||||
context.certbot(['certonly', '-d', certname, '--key-type', 'rsa'])
|
||||
assert_saved_lineage_option(context.config_dir, certname, 'key_type', 'rsa')
|
||||
|
||||
# Remove `key_type = rsa` from the renewal config to emulate a <v1.25.0 Certbot certificate.
|
||||
conf_path = join(context.config_dir, 'renewal', f'{certname}.conf')
|
||||
conf_contents: str = ''
|
||||
with open(conf_path) as f:
|
||||
conf_contents = f.read()
|
||||
conf_contents = conf_contents.replace('key_type = rsa', '')
|
||||
with open(conf_path, 'w') as f:
|
||||
f.write(conf_contents)
|
||||
|
||||
context.certbot(['renew', '--cert-name', certname, '--force-renewal'])
|
||||
|
||||
assert_saved_lineage_option(context.config_dir, certname, 'key_type', 'rsa')
|
||||
key2 = join(context.config_dir, 'archive/{0}/privkey2.pem'.format(certname))
|
||||
assert_rsa_key(key2, 2048)
|
||||
|
|
|
|||
|
|
@ -2,6 +2,113 @@
|
|||
|
||||
Certbot adheres to [Semantic Versioning](https://semver.org/).
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
## 2.5.0 - master
|
||||
|
||||
### Added
|
||||
|
||||
* `acme.messages.OrderResource` now supports being round-tripped
|
||||
through JSON
|
||||
* acme.client.ClientV2 now provides separate `begin_finalization`
|
||||
and `poll_finalization` methods, in addition to the existing
|
||||
`finalize_order` method.
|
||||
|
||||
### Changed
|
||||
|
||||
* `--dns-route53-propagation-seconds` is now deprecated. The Route53 plugin relies on the
|
||||
[GetChange API](https://docs.aws.amazon.com/Route53/latest/APIReference/API_GetChange.html)
|
||||
to determine if a DNS update is complete. The flag has never had any effect and will be
|
||||
removed in a future version of Certbot.
|
||||
|
||||
### Fixed
|
||||
|
||||
* Fixed `renew` sometimes not preserving the key type of RSA certificates.
|
||||
* Users who upgraded from Certbot <v1.25.0 to Certbot >=v2.0.0 may
|
||||
have had their RSA certificates inadvertently changed to ECDSA certificates. If desired,
|
||||
the key type may be changed back to RSA. See the [User Guide](https://eff-certbot.readthedocs.io/en/stable/using.html#changing-a-certificate-s-key-type).
|
||||
* Deprecated flags were inadvertently not printing warnings since v1.16.0. This is now fixed.
|
||||
|
||||
More details about these changes can be found on our GitHub repo.
|
||||
|
||||
## 2.4.0 - 2023-03-07
|
||||
|
||||
### Added
|
||||
|
||||
* We deprecated support for the update_symlinks command. Support will be removed in a following
|
||||
version of Certbot.
|
||||
|
||||
### Changed
|
||||
|
||||
* Docker build and deploy scripts now generate multiarch manifests for non-architecture-specific tags, instead of defaulting to amd64 images.
|
||||
|
||||
### Fixed
|
||||
|
||||
* Reverted [#9475](https://github.com/certbot/certbot/pull/9475) due to a performance regression in large nginx deployments.
|
||||
|
||||
More details about these changes can be found on our GitHub repo.
|
||||
|
||||
## 2.3.0 - 2023-02-14
|
||||
|
||||
### Added
|
||||
|
||||
* Allow a user to modify the configuration of a certificate without renewing it using the new `reconfigure` subcommand. See `certbot help reconfigure` for details.
|
||||
* `certbot show_account` now displays the [ACME Account Thumbprint](https://datatracker.ietf.org/doc/html/rfc8555#section-8.1).
|
||||
|
||||
### Changed
|
||||
|
||||
* Certbot will no longer save previous CSRs and certificate private keys to `/etc/letsencrypt/csr` and `/etc/letsencrypt/keys`, respectively. These directories may be safely deleted.
|
||||
* Certbot will now only keep the current and 5 previous certificates in the `/etc/letsencrypt/archive` directory for each certificate lineage. Any prior certificates will be automatically deleted upon renewal. This number may be further lowered in future releases.
|
||||
* As always, users should only reference the certificate files within `/etc/letsencrypt/live` and never use `/etc/letsencrypt/archive` directly. See [Where are my certificates?](https://eff-certbot.readthedocs.io/en/stable/using.html#where-are-my-certificates) in the Certbot User Guide.
|
||||
* `certbot.configuration.NamespaceConfig.key_dir` and `.csr_dir` are now deprecated.
|
||||
* All Certbot components now require `pytest` to run tests.
|
||||
|
||||
### Fixed
|
||||
|
||||
* Fixed a crash when registering an account with BuyPass' ACME server.
|
||||
* Fixed a bug where Certbot would crash with `AttributeError: can't set attribute` on ACME server errors in Python 3.11. See [GH #9539](https://github.com/certbot/certbot/issues/9539).
|
||||
|
||||
More details about these changes can be found on our GitHub repo.
|
||||
|
||||
## 2.2.0 - 2023-01-11
|
||||
|
||||
### Added
|
||||
|
||||
*
|
||||
|
||||
### Changed
|
||||
|
||||
* Certbot will no longer respect very long challenge polling intervals, which may be suggested
|
||||
by some ACME servers. Certbot will continue to wait up to 90 seconds by default, or up to a
|
||||
total of 30 minutes if requested by the server via `Retry-After`.
|
||||
|
||||
### Fixed
|
||||
|
||||
*
|
||||
|
||||
More details about these changes can be found on our GitHub repo.
|
||||
|
||||
## 1.32.2 - 2022-12-16
|
||||
|
||||
### Fixed
|
||||
|
||||
* Our snaps and Docker images were rebuilt to include updated versions of our dependencies.
|
||||
|
||||
This release was not pushed to PyPI since those packages were unaffected.
|
||||
|
||||
More details about these changes can be found on our GitHub repo.
|
||||
|
||||
## 2.1.1 - 2022-12-15
|
||||
|
||||
### Fixed
|
||||
|
||||
* Our snaps, Docker images, and Windows installer were rebuilt to include updated versions of our dependencies.
|
||||
|
||||
This release was not pushed to PyPI since those packages were unaffected.
|
||||
|
||||
More details about these changes can be found on our GitHub repo.
|
||||
|
||||
>>>>>>> e10e549a9 (renewal: fix key_type not being preserved on <v1.25.0 renewal configs (#9636))
|
||||
## 2.1.0 - 2022-12-07
|
||||
|
||||
### Added
|
||||
|
|
|
|||
|
|
@ -87,6 +87,14 @@ def _reconstitute(config: configuration.NamespaceConfig,
|
|||
logger.error("Renewal configuration file %s does not specify "
|
||||
"an authenticator. Skipping.", full_path)
|
||||
return None
|
||||
|
||||
# Prior to Certbot v1.25.0, the default value of key_type (rsa) was not persisted to the
|
||||
# renewal params. If the option is absent, it means the certificate was an RSA key.
|
||||
# Restoring the option here is necessary to preserve the certificate key_type if
|
||||
# the user has upgraded directly from Certbot <v1.25.0 to >=v2.0.0, where the default
|
||||
# key_type was changed to ECDSA. See https://github.com/certbot/certbot/issues/9635.
|
||||
renewalparams["key_type"] = renewalparams.get("key_type", "rsa")
|
||||
|
||||
# Now restore specific values along with their data types, if
|
||||
# those elements are present.
|
||||
renewalparams = _remove_deprecated_config_elements(renewalparams)
|
||||
|
|
|
|||
|
|
@ -1323,13 +1323,13 @@ class MainTest(test_util.ConfigTestCase):
|
|||
self._test_renewal_common(True, [], args=args, should_renew=True)
|
||||
|
||||
def test_reuse_key(self):
|
||||
test_util.make_lineage(self.config.config_dir, 'sample-renewal.conf')
|
||||
test_util.make_lineage(self.config.config_dir, 'sample-renewal.conf', ec=False)
|
||||
args = ["renew", "--dry-run", "--reuse-key"]
|
||||
self._test_renewal_common(True, [], args=args, should_renew=True, reuse_key=True)
|
||||
|
||||
@mock.patch('certbot._internal.storage.RenewableCert.save_successor')
|
||||
def test_reuse_key_no_dry_run(self, unused_save_successor):
|
||||
test_util.make_lineage(self.config.config_dir, 'sample-renewal.conf')
|
||||
test_util.make_lineage(self.config.config_dir, 'sample-renewal.conf', ec=False)
|
||||
args = ["renew", "--reuse-key"]
|
||||
self._test_renewal_common(True, [], args=args, should_renew=True, reuse_key=True)
|
||||
|
||||
|
|
|
|||
|
|
@ -173,6 +173,17 @@ class RenewalTest(test_util.ConfigTestCase):
|
|||
# value in the renewal conf file
|
||||
self.assertIsInstance(lineage_config.manual_public_ip_logging_ok, mock.MagicMock)
|
||||
|
||||
@mock.patch('certbot._internal.renewal.cli.set_by_cli')
|
||||
def test_absent_key_type_restored(self, mock_set_by_cli):
|
||||
mock_set_by_cli.return_value = False
|
||||
|
||||
rc_path = test_util.make_lineage(self.config.config_dir, 'sample-renewal.conf', ec=False)
|
||||
|
||||
from certbot._internal import renewal
|
||||
lineage_config = copy.deepcopy(self.config)
|
||||
renewal.reconstitute(lineage_config, rc_path)
|
||||
assert lineage_config.key_type == 'rsa'
|
||||
|
||||
|
||||
class RestoreRequiredConfigElementsTest(test_util.ConfigTestCase):
|
||||
"""Tests for certbot._internal.renewal.restore_required_config_elements."""
|
||||
|
|
|
|||
Loading…
Reference in a new issue