pub struct StoredAccount {
pub credentials: AccountCredentials,
pub directory_url: Option<String>,
}Expand description
An ACME account read back off disk, and which directory registered it.
The pair, rather than the credentials alone, because credentials are only usable against the directory that issued them: an account registered at Let’s Encrypt staging can place orders at staging and nowhere else, and the CAA record naming it authorises issuance at staging and nowhere else. A deployment that switches directories has to know which one it is holding before it decides whether to restore it.
Fields§
§credentials: AccountCredentialsThe credentials, ready to restore an instant_acme::Account from.
directory_url: Option<String>The ACME directory URL these credentials record. None for a file
written by a pre-0.4 instant-acme, which recorded the directory’s
individual endpoint URLs instead of the directory itself.
Implementations§
Source§impl StoredAccount
impl StoredAccount
Sourcepub fn issued_by(&self, directory_url: &str) -> bool
pub fn issued_by(&self, directory_url: &str) -> bool
Whether these credentials were registered against directory_url.
A file that records no directory answers false for every one:
registering a fresh account costs one round trip, and using
credentials against a directory that may not have issued them costs
an outage at the next order.