fix(link): the app believes only public authorities, only their hosts, and only while a certificate lasts
The review of P15 B3 found the relay could steer three things it must not. - A certificate is now checked against the public roots the program ships, for the app's wildcard, when it is issued and every time it is read from disk; a lifetime over 100 days is refused (no public authority issues one), and the renewal is planned no later than two thirds of the life or 60 days. A kept certificate that fails is ignored and ordered again. Only a test builds a CertTrust of its own roots. - The ACME client sends a request only to a directory on a host compiled into the app (Let's Encrypt production and staging, Google Trust Services, ZeroSSL, Buypass, SSL.com): the relay still picks which and in what order, but cannot name a new host. A kept account is used only if its directory is on the list too. http is a direct dependency now (it was a dev-dependency, and already in the tree): the host is read with the parser the ACME library uses. - The resolver refuses a certificate at its end, sleeps stop at it, and the state stops saying "Connected" when it has ended. - The certificate work waits for the line, so it is for the name the relay accepted (a first claim that finds the name taken picks another); web.rs starts the door only once the name is settled. - A line that held under 60 s does not reset the backoff; one that held is redialled after 0 to 30 s, so a relay restart is not met by every app in the same second. - What the relay and the authority say is shown as a short quoted detail with control and invisible characters removed, in the app's own words. - The kept address is read once, not from the key file every frame; the folder is synced after a private file is renamed into place. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
1 parent
14c1a26bfc
commit
b90df7158a
12 files changed
+1440
-128
No files matched your search
@@ -27,6 +27,7 @@ base64 = "0.22"
|
||||
ring = "0.17"
|
||||
x509-parser = "0.18"
|
||||
zeroize = "1"
|
||||
http = "1"
|
||||
webpki-root-certs = "1"
|
||||
|
||||
# Owner-only DACLs for the key and certificate files (the helper the token
|
||||
@@ -39,7 +40,6 @@ tempfile = "3"
|
||||
rcgen = { version = "0.14", default-features = false, features = ["ring", "pem", "x509-parser"] }
|
||||
hickory-proto = { version = "0.26", default-features = false, features = ["std"] }
|
||||
tokio = { version = "1", features = ["test-util"] }
|
||||
http = "1"
|
||||
http-body-util = "0.1"
|
||||
bytes = "1"
|
||||
async-trait = "0.1"
|
||||
|
||||
Reference in new issue
Block a user