[package]
name = "auth-framework"
version = "0.4.0"
edition = "2024"
authors = ["Eric Evans <ciresnave@gmail.com>"]
description = "A comprehensive, production-ready authentication and authorization framework for Rust applications"
license = "MIT OR Apache-2.0"
repository = "https://github.com/ciresnave/auth-framework"
keywords = ["auth", "authentication", "authorization", "oauth", "jwt"]
categories = ["authentication", "web-programming"]
readme = "README.md"
documentation = "https://docs.rs/auth-framework"
[[bin]]
name = "auth-framework"
path = "src/bin/admin.rs"
required-features = ["admin-binary"]
[dependencies]
tokio = { version = "1.0", features = ["full"] }
jsonwebtoken = "9.2"
reqwest = { version = "0.12", features = ["json"] }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
config = { version = "0.14", default-features = false, features = [
"toml",
"yaml",
"json",
"ron",
"ini",
] }
thiserror = "1.0"
anyhow = "1.0"
async-trait = "0.1"
ring = "0.17"
rand = "0.8"
time = { version = "0.3", features = ["serde", "parsing", "formatting"] }
chrono = { version = "0.4", features = ["serde"] }
uuid = { version = "1.0", features = ["v4", "serde"] }
log = "0.4"
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
url = "2.4"
base64 = "0.21"
maxminddb = "0.24"
ipnetwork = "0.20"
csv = "1.3"
tokio-cron-scheduler = "0.10"
serde_yaml = "0.9"
toml = "0.8"
dirs = "5.0"
hex = "0.4"
sha2 = "0.10"
sha1 = "0.10"
hmac = "0.12"
argon2 = "0.5"
bcrypt = "0.15"
redis = { version = "0.32", optional = true, features = ["aio", "tokio-comp"] }
governor = "0.10"
nonzero_ext = "0.3"
totp-lite = "2.0"
base32 = "0.4"
urlencoding = "2.1"
x509-parser = "0.16"
rustls-webpki = "0.102"
crc32fast = "1.3"
zeroize = { version = "1.8", features = ["zeroize_derive"] }
subtle = "2.5"
dashmap = "6.1"
secrecy = { version = "0.8", features = ["serde"] }
oauth-device-flows = { version = "0.1", optional = true }
openidconnect = { version = "4.0", optional = true }
ldap3 = { version = "0.11", optional = true }
otpauth = { version = "0.5", optional = true }
unicode-normalization = { version = "0.1", optional = true }
clap = { version = "4.0", features = ["derive"], optional = true }
rpassword = { version = "7.0", optional = true }
ratatui = { version = "0.28", optional = true }
crossterm = { version = "0.28", optional = true }
tui-input = { version = "0.10", optional = true }
indicatif = { version = "0.17", optional = true }
console = { version = "0.15", optional = true }
dialoguer = { version = "0.11", optional = true }
colored = { version = "2.0", optional = true }
futures-util = { version = "0.3", optional = true }
askama = { version = "0.12", optional = true }
askama_axum = { version = "0.4", optional = true }
quick-xml = { version = "0.36", features = ["serialize"], optional = true }
passkey = { version = "0.4", optional = true }
coset = { version = "0.3", optional = true }
passkey-client = { version = "0.4", optional = true }
warp = { version = "0.3", optional = true }
actix-web = { version = "4.0", optional = true }
axum = { version = "0.8", features = ["macros"], optional = true }
tower = { version = "0.5", features = ["util"], optional = true }
tower-http = { version = "0.6", features = [
"cors",
"trace",
"fs",
], optional = true }
serde_urlencoded = { version = "0.7", optional = true }
sqlx = { version = "0.8", features = [
"runtime-tokio-rustls",
"postgres",
"mysql",
"chrono",
"uuid",
], optional = true }
tokio-postgres = { version = "0.7", optional = true }
testcontainers = { version = "0.25", optional = true }
html-escape = "0.2.13"
sms-core = { version = "0.2", optional = true }
sms-plivo = { version = "0.2", optional = true }
sms-twilio = { version = "0.2", optional = true }
sms-aws-sns = { version = "0.2", optional = true }
sms-web-generic = { version = "0.2", optional = true }
sms-web-axum = { version = "0.2", optional = true }
[dev-dependencies]
tokio-test = "0.4"
mockito = "1.2"
test-log = "0.2"
criterion = { version = "0.5", features = ["html_reports"] }
[features]
default = ["postgres-storage"]
redis-storage = ["redis"]
postgres-storage = ["sqlx", "tokio-postgres"]
mysql-storage = ["sqlx"]
testing = []
enhanced-device-flow = ["oauth-device-flows"]
openid-connect = ["openidconnect"]
enhanced-crypto = ["chacha20poly1305", "x25519-dalek", "ed25519-dalek"]
fips-compliance = ["aws-lc-rs"]
distributed-rate-limiting = ["redis"]
passkeys = ["passkey", "coset", "passkey-client"]
saml = ["quick-xml"]
cli = [
"clap",
"rpassword",
"tokio-postgres",
"indicatif",
"console",
"dialoguer",
"colored",
]
tui = ["ratatui", "crossterm", "tui-input", "indicatif", "console", "colored"]
web-gui = [
"axum",
"tower",
"tower-http",
"askama",
"askama_axum",
"serde_urlencoded",
]
admin-binary = ["cli", "tui", "web-gui"]
docker-tests = ["testcontainers"]
axum-integration = ["axum", "tower", "tower-http", "serde_urlencoded"]
actix-integration = ["actix-web", "futures-util"]
warp-integration = ["warp"]
ldap-auth = ["ldap3"]
otp-auth = ["otpauth"]
unicode-support = ["unicode-normalization"]
smskit = [
"sms-core",
"sms-plivo",
"sms-twilio",
"sms-aws-sns",
"sms-web-generic",
]
smskit-web-axum = ["smskit", "sms-web-axum", "axum-integration"]
[dependencies.aes-gcm]
version = "0.10"
optional = false
[dependencies.chacha20poly1305]
version = "0.10"
optional = true
[dependencies.x25519-dalek]
version = "2.0"
optional = true
[dependencies.ed25519-dalek]
version = "2.1"
features = ["rand_core"]
optional = true
[dependencies.aws-lc-rs]
version = "1.8"
features = ["aws-lc-sys"]
optional = true
[dependencies.parking_lot]
version = "0.12"
[dependencies.getrandom]
version = "0.2"
features = ["std"]