pub enum Output<'machine> {
Authenticate {
client: &'machine str,
passdata: &'machine [u8],
},
Binding {
client_id: &'machine str,
},
Extend,
Negotiate {
bound_client: &'machine BoundClient<'static>,
scope: Option<Scope>,
},
Ok {
pre_grant: &'machine PreGrant,
extensions: &'machine Extensions,
},
Err(Box<Error>),
}
Expand description
A request by the statemachine to the executor.
Each variant is fulfilled by certain variants of the next inputs as an argument to
AccessToken::advance
. The output of most states is simply repeated if Input::None
is
provided instead but note that the successful bearer token response is not repeated.
Variants§
Authenticate
The registrar should authenticate a client.
Fulfilled by Input::Authenticated
. In an unsuccessful case, the executor should not
continue and discard the flow.
Fields
Binding
Ask registrar to bind the client. There is no redirect URI provided from the request, so the registrar will have to pick one arbitrarily (or return an invalid one). Ths redirect URL will not be followed.
Fulfilled by Input::Bound
Extend
The extension (if any) should provide the extensions
Fullfilled by Input::Extended
Negotiate
Ask registrar to negotiate.
Fulfilled by Input::Negotiated
Fields
bound_client: &'machine BoundClient<'static>
The current bound client
Ok
The state machine finished and the frontend should assign an owner ID and then issue the token.
Fullfilled by Input::Issued
Fields
extensions: &'machine Extensions
The extensions to include
Err(Box<Error>)
The state machine finished in an error.
The error will be repeated on any following input.