Boruta.Oauth (Boruta core v1.0.0) View Source
Boruta OAuth entrypoint, handles OAuth requests.
Note : this module works in association with Boruta.Oauth.Application
behaviour
Link to this section Summary
Functions
Process an authorize request and returns a token as stated in RFC 6749 - The OAuth 2.0 Authorization Framework.
Process a introspect request as stated in RFC 7662 - OAuth 2.0 Token Introspection.
Process an authorize request as stated in RFC 6749 - The OAuth 2.0 Authorization Framework.
Process a revoke request as stated in RFC 7009 - OAuth 2.0 Token Revocation.
Process an token request as stated in RFC 6749 - The OAuth 2.0 Authorization Framework.
Link to this section Functions
Specs
authorize( conn :: Plug.Conn.t() | map(), resource_owner :: Boruta.Oauth.ResourceOwner.t(), module :: atom() ) :: any()
Process an authorize request and returns a token as stated in RFC 6749 - The OAuth 2.0 Authorization Framework.
Triggers authorize_success
in case of success and authorize_error
in case of failure from the given module
. Those functions are described in Boruta.Oauth.Application
behaviour.
Specs
introspect(conn :: Plug.Conn.t() | map(), module :: atom()) :: any()
Process a introspect request as stated in RFC 7662 - OAuth 2.0 Token Introspection.
Triggers introspect_success
in case of success and introspect_error
in case of failure from the given module
. Those functions are described in Boruta.Oauth.Application
behaviour.
Specs
preauthorize( conn :: Plug.Conn.t() | map(), resource_owner :: Boruta.Oauth.ResourceOwner.t(), module :: atom() ) :: any()
Process an authorize request as stated in RFC 6749 - The OAuth 2.0 Authorization Framework.
Triggers preauthorize_success
in case of success and preauthorize_error
in case of failure from the given module
. Those functions are described in Boruta.Oauth.Application
behaviour.
Specs
revoke(conn :: Plug.Conn.t() | map(), module :: atom()) :: any()
Process a revoke request as stated in RFC 7009 - OAuth 2.0 Token Revocation.
Triggers revoke_success
in case of success and revoke_error
in case of failure from the given module
. Those functions are described in Boruta.Oauth.Application
behaviour.
Specs
token(conn :: Plug.Conn.t() | map(), module :: atom()) :: any()
Process an token request as stated in RFC 6749 - The OAuth 2.0 Authorization Framework.
Triggers token_success
in case of success and token_error
in case of failure from the given module
. Those functions are described in Boruta.Oauth.Application
behaviour.