Commit Graph

41 Commits

Author SHA1 Message Date
Rudolf Mayerhofer c3736c0838 Allow multiple sets of the same domain to defined in a single config file (necessary for multiple certs using different key_algorithm) in a list style notation (lists of maps) 2023-07-12 16:10:21 +02:00
Rudolf Mayerhofer 1a98f86aad Fix idna conversion for force-renew (probably broken since the IDNA cleanup) 2023-07-12 16:10:21 +02:00
Rudolf Mayerhofer ef81ea62d1 Unify key_algorithm handling for elipic curves (change naming to ECC but stay backwards compatible) 2023-07-12 16:10:21 +02:00
Rudolf Mayerhofer ba644d44f1 Update config id if we have a key algorithm set to allow for multiple certs with different algorithms for the same set of domains
This is a breaking change!
Changes the id for configurations with a key algorithm set, which by default results in changes to serveral dependent configuration values as well,
such as cert_file/key_file/csr_file. This will require existing ECC setups to append the ecc suffix to files in the acertmgr configuration directory
2023-07-12 16:10:21 +02:00
Kishi85 460b0119ac configuration: Simplify too complex IDNA conversion 2021-09-13 09:00:59 +02:00
Kishi85 b37d0cad94 acertmgr: Add a OCSP validation to certificate verification 2020-03-04 14:50:05 +01:00
Kishi85 f5f038d47b configuration: global config is now relative to config_dir 2019-10-26 19:11:33 +02:00
Kishi85 ba4dda154b acertmgr: Remove legacy configuration directives (#30) 2019-09-06 16:07:16 +02:00
Kishi85 258855c5b4 legacy: fix ToS agreement value 2019-05-13 20:48:44 +02:00
Kishi85 7a019d1ac9 idna: unify usage as tools function 2019-05-06 21:24:24 +02:00
Kishi85 6a07ab1188 tools/configuration: Add support for EC/Ed25519/Ed448 generation 2019-04-19 15:29:44 +02:00
Kishi85 79b625619a acertmgr: try using a fallback configuration for revoke
If no configuration matching the domains in the given certificate exist
use the globalconfig/default settings for an authority to revoke the
certificate (which might still fail if things do not match up, but the
authority will decide on that)

Configuration parsing for the authority settings is therefore split into
a seperate function which will be called for the 'fallback_authority'
element in runtimeconfig.
2019-04-07 15:31:07 +02:00
Kishi85 b63a0bc424 tools: add log function, update log messages mentioning certificates
This simple implementation writes log messages to stdout/err and flushes
the buffers immediately after the message has been written.

Also update log messages with the certificate CN to a better readable format
Introduce functions for get_cert_cn and get_cert_valid_until to
encapsulate all cryptographic functions consistently in tools.
2019-04-07 15:31:06 +02:00
Kishi85 54cb334600 acertmgr: add support for the ocsp must-staple extension
Introduces a new config directive and requires at least cryptography 2.1
2019-04-04 13:39:05 +02:00
Kishi85 0a5356a302 configuration: fix broken idna handling 2019-03-31 23:17:02 +02:00
Kishi85 7e4c350a4f configuration: remove redundant 'domains' parameter, just use domainlist 2019-03-28 14:52:18 +01:00
Kishi85 fa3fc196f3 configuration: unify how ca_file and ca_static are determined
ensure legacy compatibility (also include defaults case) and update README.md
2019-03-28 13:41:27 +01:00
Kishi85 99d9e41322 configuration: cleanup for legacy removal and improve readability 2019-03-28 12:38:53 +01:00
Kishi85 75f597ac36 configuration: put all authority related directives into sub-dict 2019-03-28 09:48:54 +01:00
Kishi85 f01140e89b acertmgr: Add option to supersede previous cert on renewal
Add option to automatically revoke the previous certificate with reason
superseded after deployment and all actions have been successful.
2019-03-28 09:48:54 +01:00
Kishi85 737578159b acertmgr: Add support for account.key based certificate revocation 2019-03-28 00:53:54 +01:00
Kishi85 bd27db4ebd acertmgr: add force renew option to immediately renew a cert 2019-03-27 18:37:03 +01:00
Kishi85 dfaca3b58f configuration: put idna handling into function 2019-03-27 18:34:48 +01:00
Kishi85 52f5584dc0 configuration: add seperate configuration for runtime options 2019-03-27 15:32:49 +01:00
Kishi85 a71ab0f31a configuration: fix specific domain config not overriding global+defaults 2019-03-25 15:09:19 +01:00
Kishi85 ed96f2bbf2 acertmgr: store CSR and support static CSR usage
Store the generated CSR for later review/usage and allow the stored
CSR to be used for future request. Configuration directives csr_file
(path) and csr_static (=true) have been added for this.

This allows simplified deployment of DANE/TLSA due the former requiring
updates to DNS with every public key change, which will not be the case
with a static CSR. A new CSR can be triggered manually by deleting the
CSR file upon which the next certificate will require an update of any
TLSA records in DNS.

This may also be used to specify a custom CSR to use, as long as the
csr_file path and the domains in the CSR match the ones given in the
acertmgr configuration.
2019-03-25 10:13:02 +01:00
Kishi85 7ee34912c1 acertmgr: rework how files are handled in general
- Remove unnecessary tempfiles and keep as much in memory as possible
- Unify the way PEM files are written and read
2019-03-25 10:12:59 +01:00
Kishi85 1e5b1defa7 configuration: fixes and print warnings on certain options (prepares #30)
- Print warnings when certain configuration options are used
- Print warnings when old file/directory paths are used
- Fix compatibility with old configurations expecting v1 API for now
2019-03-23 10:12:17 +01:00
Kishi85 17dfaa08f0 configuration: Translate unicode names to IDNA (fixes #24) 2019-03-21 18:43:41 +01:00
Kishi85 316ecdba2e configuration: Force user to agree to the authorities Terms of Service
Authorities (e.g. Let's Encrypt) usually have Terms of Serivce (ToS)
that have to be agreed to. Up until this point we automatically
indicated agreement to those ToS and sent the necessary value.

This commit changes the behaviour to be in line with recommendations
from Let's Encrypt that the user themselves have to indicate their
agreement by no longer automatically doing so (except for cases of
legacy configuration files to provide compatibility).

The user can now indicate ToS agreement by either setting the associated
configuration variable (authority_tos_agreement) to the required value
and/or providing the required value via a command-line parameter
(--authority-tos-agreement=<value>/--tos-agreement=<value>/--tos=<value>)
2019-03-20 15:31:53 +01:00
Kishi85 f2567da7fa configuration: Change default API to v2 with Let's Encrypt Endpoint 2019-03-20 15:31:53 +01:00
Kishi85 530256ecec authority.v2: Add ACMEv2 API implementation 2019-03-20 15:31:48 +01:00
Kishi85 d272f9ada3 configuration: fix global config file detection 2019-03-19 12:08:53 +01:00
Kishi85 a93b047275 configuration: use legacy workdir with legacy configuration only 2019-03-19 12:08:53 +01:00
Kishi85 57e955d1f0 configuration: Change default TTL to Let's Encrypt recommendation 2019-03-18 13:13:22 +01:00
Kishi85 3f59bb4061 configuration: unify config value parsing 2019-03-07 13:51:08 +01:00
Kishi85 8e0639f62c authority.v1: remove hardcoded agreement data 2019-02-24 19:48:24 +01:00
Markus d6f8f29e82 configuration: use yaml.safe_load instead of load 2019-02-22 10:31:28 +01:00
Kishi85 67c83d8fce configuration: cleanup handling+defaults and add commandline options
This adds a few basic command line parameters to allow further
customization of the configuration locations. As well as defining new
default locations for the acertmgr config files and updating the parser
with missing values, so that the config dictionary provided to the
acertmgr process after parsing is complete and no cross reference to the
configuration module is necessary. The parser error handling is also
improved.
2019-02-20 12:03:40 +01:00
Kishi85 5d8b0134ea fix broken references from move and add legacy run script 2019-02-20 11:49:30 +01:00
Kishi85 f1f2d5c7cd move everything to package 'acertmgr' 2019-02-20 11:43:44 +01:00