Expand description
Mail: the services Runlight sends reports through (Amazon SES, SMTP, the HTTP ones, and a webhook), and the sealing of the keys kept for them.
Re-exports§
pub use secret::seal;pub use secret::unseal;pub use transports::MailConfig;pub use transports::MailError;pub use transports::Message;pub use transports::SERVICES;pub use transports::Service;pub use transports::ServiceField;pub use transports::check_config;pub use transports::send;pub use transports::service_message;
Modules§
- secret
- Keys kept in the database (the mail service’s, the AI Assistant’s, and the tokens for connected
installs) are encrypted with AES-GCM, under a key derived from a secret only the server has:
RUNLIGHT_SECRET, or else the dashboard token. A copied database alone does not give them away. The label says “mail” because mail came first; changing it would make every saved key unreadable. - ses
- Amazon SES (API v2) with a hand-rolled Signature Version 4, so there is no AWS SDK to install. https://docs.aws.amazon.com/IAM/latest/UserGuide/create-signed-request.html
- smtp
- A small SMTP client: implicit TLS (465), STARTTLS (587), or plain (local
relays), with AUTH PLAIN, on tokio. TLS comes with the
transportfeature (tokio-rustls, with the platform’s roots); without it only plain relays can be used. - transports
- Every service Runlight can send mail through, and the one call that sends a message through whichever is configured.