Skip to content

metatoaster/axum-login-bearer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CI crates.io docs.rs

axum-login-bearer

Leverage well-established patterns provided by axum-login, but also with bearer tokens.

Overview

This crate provides a BearerTokenAuthManager that can either operate on its own, which sets up the AuthManager from the axum-login crate to provide the AuthSession to provide the familiar interface to deal with the identification, authentication and authorization of users. It can also be set up with the usual SessionmanagerLayer to also provide the typical cookie-backed sessions should both be desired.

The end result is that a bearer token provided with a request will be able to function in place of the session cookie to identify the user's session.

There are configuration options that changes how it behaves, please refer to the documentation and the sqlite-bearer example.

About

Enable axum-login to support bearer tokens

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages