aboutsummaryrefslogtreecommitdiff
path: root/crypto.c
AgeCommit message (Collapse)Author
2024-01-21convert remaining code to the imsg gettersOmar Polo
Now gmid doesn't touch anymore the internals of the imsg structs.
2024-01-21convert the remaining bit of crypto.c to the ibuf_* APIsOmar Polo
2024-01-21convert crypto.c to the new imsg APIOmar Polo
2024-01-21rename ibuf to imsgbuf in cryptoOmar Polo
soon we'll be using a struct ibuf and it'll be confusing.
2023-08-29fix typo; the size computation is done using len, not retOmar Polo
2023-08-28don't let crypto_dispatch_server handle IMSG_CRYPTO_ECDSA_SIGNOmar Polo
in this codepath. otherwise we end up with a mismatch where we expect a request but were sent a response.
2023-08-28pre-increment reqidOmar Polo
otherwise we send the request id N and expect to receive N+1
2023-08-28typo; was filling the wrong iov_len...Omar Polo
2023-07-22fmtOmar Polo
2023-07-22drop engine supportOmar Polo
2023-07-22remove the useless logging methodsOmar Polo
it makes more clear where the magic is. adapted from the smtpd' ca.c diff.
2023-06-23macos' clang is retardedOmar Polo
thinks rsa and ecdsa may be used un-initialized... if we enter the branch with fatalx(). sigh
2023-06-23drop debug logOmar Polo
2023-06-13simplify checkOmar Polo
brought to my attention by gcc who isn't smart enough to figure out that `ret' is always set.
2023-06-13avoid arithmetic on void pointers (GNU extension)Omar Polo
not really sold on this one, I don't see what other interpretation could be given, but it's not standard so...
2023-06-11fixes for -Wpointer-signOmar Polo
2023-06-11cast uint64_t to unsigned long longOmar Polo
2023-06-11work around different signature for ecdsae_compute_keyOmar Polo
2023-06-11add a privsep crypto engineOmar Polo
Incorporate the OpenSMTPD' privsep crypto engine. The idea behind it is to never load the certificate' private keys in a networked process, instead they are loaded in a separate process (the `crypto' one) which signs payloads on the behalf of the server processes. This way, we greatly reduce the risk of leaking the certificate' private key should the server process be compromised. This currently compiles only on LibreSSL (portable fix is in the way).