GithubHelp home page GithubHelp logo

conradoplg / axum-login Goto Github PK

View Code? Open in Web Editor NEW

This project forked from maxcountryman/axum-login

0.0 1.0 0.0 218 KB

๐Ÿชช User identification, authentication, and authorization for Axum.

License: MIT License

Rust 100.00%

axum-login's Introduction

axum-login

๐Ÿชช User identification, authentication, and authorization for Axum.

๐ŸŽจ Overview

This crate provides user identification, authentication, and authorization as a tower middleware for axum.

If offers:

  • User Identification, Authentication, and Authorization: Leverage AuthSession to easily manage authentication and authorization. This is also an extractor, so it can be used directly in your axum handlers.
  • Support for Arbitrary Users and Backends: Applications implement a couple of traits, AuthUser and AuthnBackend, allowing for any user type and any user management backend. Your database? Yep. LDAP? Sure. An auth provider? You bet.
  • User and Group Permissions: Authorization is supported via the AuthzBackend trait, which allows applications to define custom permissions. Both user and group permissions are supported.
  • Convenient Route Protection: Middleware for protecting access to routes are provided via the login_required and permission_required macros. Or bring your own by using AuthSession directly with from_fn.
  • Rock-solid Session Management: Uses tower-sessions for high-performing and ergonomic session management. Look ma, no deadlocks!

๐Ÿ“ฆ Install

To use the crate in your project, add the following to your Cargo.toml file:

[dependencies]
axum-login = "0.15.0"

๐Ÿคธ Usage

We recommend reviewing our sqlite example.

Note

See the crate documentation for usage information.

๐Ÿฆบ Safety

This crate uses #![forbid(unsafe_code)] to ensure everything is implemented in 100% safe Rust.

๐Ÿ›Ÿ Getting Help

We've put together a number of examples to help get you started. You're also welcome to open a discussion and ask additional questions you might have.

๐Ÿ‘ฏ Contributing

We appreciate all kinds of contributions, thank you!

axum-login's People

Contributors

maxcountryman avatar czocher avatar czotomo avatar rigellute avatar beckend avatar epilys avatar dave42w avatar bngo92 avatar laskowski avatar weiznich avatar kingsleyh avatar iamsauravsharma avatar maverich avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.