Decision Workspace
nornir-auth-oauth2 vs mailrs-oauth-client vs casdoor-sdk-rust
Side-by-side comparison of Rust crates
OAuth 2.0 / 2.1 auth PROVIDER for the nordisk servers — verify a presented access token via RFC 7662 token introspection (SP side) and drive the service-to-service client-credentials grant + interactive authorization-code + PKCE flow. Beyond `nornir-auth-oidc`'s offline JWT-vs-JWKS: this covers opaque access tokens introspected against the IdP and the pure-OAuth2 M2M grant. Enables Entra ID / Okta / Auth0 / Google / AWS IAM Identity Center as OAuth providers. REUSES the `oauth2` crate (does NOT hand-roll the protocol). Implements the shared `nornir_service::AuthProvider` seam via `verify_bearer`. Feature-gated sub-crate: the HTTP-egress (`reqwest`) closure is linked ONLY when a tier pins `online` — the offline/mini bearer tier links none of it. Consumed by holger (reference impl), korp, dwarves.
OAuth 2.0 / OIDC relying-party primitives: authorization URLs with PKCE, token exchange, and identity extraction across providers that disagree about how to describe a person. Pure apart from two HTTP calls, so the URL building, the PKCE derivation and the claim reading are testable without a network.
A Casdoor SDK (contain APIs) with more complete interfaces and better usability.
Core Metrics
| nornir-auth-oauth2 | mailrs-oauth-client | casdoor-sdk-rust | |
|---|---|---|---|
| Health Score | 47 | 40 | 35 |
| Total Downloads | 162 | 18 | 3.9K |
| 30d Downloads | 0 | 0 | 0 |
| Dependents | 5 | 0 | 0 |
| Releases | 2 | 1 | 5 |
| Last Updated | 53d ago | 66d ago | 624d ago |
| Age | 2m | 2m | 1y 9m |
Health Breakdown
Technical Details
| nornir-auth-oauth2 | mailrs-oauth-client | casdoor-sdk-rust | |
|---|---|---|---|
| Version | 0.1.1 | 0.1.0 | 1.1.0 |
| Stable (≥1.0) | ✗ No | ✗ No | ✓ Yes |
| License | MIT OR Apache-2.0 | MIT OR Apache-2.0 | Apache-2.0 |
| Dependencies | 7 | 6 | 16 |
| Crate Size | 19KB | 10KB | 58KB |
| Features | 2 | 0 | 0 |
| Yanked % | 0.0% | 0.0% | 20.0% |
| Edition | 2021 | 2024 | 2021 |
| MSRV | — | — | — |
| Owners | 1 | 1 | 1 |
Links
Quick Verdict
- •nornir-auth-oauth2 leads with a health score of 47/100, but none of the options score above 80.
- •casdoor-sdk-rust has the most downloads (3.9K), suggesting wider adoption.
- •⚠ casdoor-sdk-rust has not been updated in over a year.
- •nornir-auth-oauth2, mailrs-oauth-client are pre-1.0 — API may change.