[][src]Struct acme_lib::order::NewOrder

pub struct NewOrder<P: Persist> { /* fields omitted */ }

A new order created by Account::new_order.

An order is created using one or many domains (a primary CN and possible multiple alt names). All domains in the order must have authorizations (confirmed ownership) before the order can progress to submitting a CSR.

This order façade provides calls to provide such authorizations and to progress the order when ready.

The ACME API provider might "remember" for a time that you already own a domain, which means you might not need to prove the ownership every time. Use appropriate methods to first check whether you really need to handle authorizations.

Methods

impl<P: Persist> NewOrder<P>[src]

pub fn is_validated(&self) -> bool[src]

Tell if the domains in this order have been authorized.

This doesn't do any calls against the API. You must manually call refresh.

In ACME API terms, the order can either be ready or valid, which both would mean we have passed the authorization stage.

pub fn confirm_validations(&self) -> Option<CsrOrder<P>>[src]

If the order is_validated progress it to a CsrOrder.

This doesn't do any calls against the API. You must manually call [refresh].

pub fn refresh(&mut self) -> Result<()>[src]

Refresh the order state against the ACME API.

The specification calls this a "POST-as-GET" against the order URL.

pub fn authorizations(&self) -> Result<Vec<Auth<P>>>[src]

Provide the authorizations. The number of authorizations will be the same as the number of domains requests, i.e. at least one (the primary CN), but possibly more (for alt names).

If the order includes new domain names that have not been authorized before, this list might contain a mix of already valid and not yet valid auths.

pub fn api_order(&self) -> &ApiOrder[src]

Access the underlying JSON object for debugging.

Auto Trait Implementations

impl<P> Send for NewOrder<P> where
    P: Sync

impl<P> Sync for NewOrder<P> where
    P: Sync

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.