[][src]Trait interledger::http::HttpStore

pub trait HttpStore: 'static + Send + Sync + Clone {
    type Account: HttpAccount;
    fn get_account_from_http_auth(
        &self,
        username: &Username,
        token: &str
    ) -> Box<dyn Future<Error = (), Item = Self::Account> + 'static + Send>; }

The interface for Stores that can be used with the HttpServerService.

Associated Types

Loading content...

Required methods

fn get_account_from_http_auth(
    &self,
    username: &Username,
    token: &str
) -> Box<dyn Future<Error = (), Item = Self::Account> + 'static + Send>

Load account details based on the full HTTP Authorization header received on the incoming HTTP request.

Loading content...

Implementors

impl HttpStore for RedisStore[src]

type Account = Account

fn get_account_from_http_auth(
    &self,
    username: &Username,
    token: &str
) -> Box<dyn Future<Error = (), Item = <RedisStore as HttpStore>::Account> + 'static + Send>
[src]

Checks if the stored token for the provided account id matches the provided token, and if so, returns the account associated with that token

Loading content...