fix: pki.root_key_warning silences the warning of vpn-router-ca status and /ca about the root key on the router.
Release / release (push) Successful in 24s

This commit is contained in:
slawek committed 2026-10-25 22:20:39 +01:00
1 parent c19b195ea0
commit e11c88f0de
5 files changed
+19 -5

No files matched your search

+9
View File
@@ -1,3 +1,12 @@
vpn-router (0.21.2-1) unstable; urgency=medium
fix: pki.root_key_warning silences the warning of vpn-router-ca status and /ca about the root key on the router.
* pki.root_key_warning, true by default, set to false silences the
warning that the root key is on the router.
-- Slawomir Koszewski <slawek@koszewscy.waw.pl> Sat, 31 Oct 2026 10:00:00 +0100
vpn-router (0.21.1-1) unstable; urgency=medium
fix: vpn-router-ca status and /ca warn about a CRL the router signs only once vpn-router-pki.timer has not renewed it in time.
@@ -55,7 +55,8 @@ SCHEMA = {
'https': {'enabled': True, 'email': '', 'web_port': 7444, 'manager_port': 7443, 'caddy_source': 'ubuntu'},
'pki': {'root_name': 'VPN Router Root CA', 'root_days': 7300, 'ca_days': 3650, 'key': 'rsa-4096',
'crl_days': 7, 'root_crl_days': 180, 'publish': ['http'], 'p2s_name': 'VPN Router P2S CA',
's2s_name': 'VPN Router Site-to-Site CA', 'issuing_cas': {}, 'templates': {}},
's2s_name': 'VPN Router Site-to-Site CA', 'issuing_cas': {}, 'templates': {},
'root_key_warning': True},
'metrics': {'enabled': True, 'listen': 'internal', 'port': 9464, 'https_port': 9465, 'service_account': 'metrics',
'otlp_endpoint': '', 'otlp_username': '', 'otlp_password': '',
'keep_details': '24 hours', 'keep_hourly': '1 month', 'keep_daily': '3 months',
@@ -931,7 +931,8 @@ def acme_url(cfg, name):
def status(cfg):
"""The root, the issuing CAs, the retired CAs and the warnings, as /ca and vpn-router-ca status show them."""
"""The root, the issuing CAs, the retired CAs and the warnings, as /ca and vpn-router-ca status show them; the root
key on the router is a warning while pki.root_key_warning is true."""
moment = now()
soon = moment + datetime.timedelta(days=WARN_DAYS)
state = read_state()
@@ -956,7 +957,7 @@ def status(cfg):
root = {'subject': common_name(root_cert), 'expires': iso(utc(root_cert, 'not_valid_after')), 'key': key,
'crl_next_update': crl_of('root') if key or (ROOT_DIR / 'crl.pem').is_file() else None,
'crl_source': state['root_crl']}
if key:
if key and cfg['pki']['root_key_warning']:
warnings.append('the root key is on the router; export it with vpn-router-ca root export-key and remove it '
'with vpn-router-ca root remove-key to keep the root offline')
elif not (ROOT_DIR / 'crl.pem').is_file():
@@ -91,7 +91,8 @@
"server": {
"days": 397
}
}
},
"root_key_warning": true
},
"metrics": {
"enabled": true,