Keycloak is a production-grade open-source Identity and Access Management (IAM) server. In production it provides authentication and authorization for applications via OIDC/OAuth2, SAML, and emerging standards including OID4VC verifiable credentials (SD-JWT, mdoc, LDP), Shared Signals Framework (SSF/CAEP/RISC), WebAuthn passkeys, and CIBA. The server is a modular Java monolith running on Quarkus, exposing REST admin APIs (v1 plus a feature-gated v2), protocol endpoints, and React-based admin/account consoles, with a Kubernetes operator for managed deployment and CLI tools (kc.sh, kcadm.sh, kcreg.sh). The architecture is built around a pervasive SPI/provider-factory pattern: nearly every subsystem (authentication flows, password hashing, event listeners, user storage federation, token introspection, crypto providers, theme selection) is pluggable via ProviderFactory + Spi interfaces, making the system highly extensible. Persistence uses JPA/Hibernate with Liquibase migrations across PostgreSQL, MySQL, MariaDB, Oracle, and MSSQL; distributed caching and cluster events use Infinispan. The codebase also ships Java and TypeScript admin client libraries and legacy WildFly SAML adapters. Primary data flows: browser/device authentication flows produce signed tokens (access, refresh, ID, userinfo) via pluggable crypto providers (BouncyCastle, FIPS 140-2, Elytron); user/session state flows between the database and Infinispan caches with invalidation events; identity brokering federates users from LDAP, Kerberos, and social IdPs; admin operations emit admin and audit events. Test infrastructure is extensive: a new JUnit 5 test framework with DI annotations coexists with a legacy Arquillian suite (migration in progress), plus Playwright e2e tests for the admin UI. This is purely an application repository - no data pipelines or research artifacts. Notable reusable components include a self-contained SD-JWT implementation, a JOSE/JWS/JWK library, and generic utilities (PathMatcher, Retry) that could be extracted into other Java projects with minimal modification.
Pocket ID is a self-hosted OpenID Connect and OAuth 2.0 identity provider centered on passkey (WebAuthn) authentication. In production it acts as an authentication gateway: it serves the OIDC/OAuth endpoints (authorization code with PKCE, device authorization, client credentials, pushed authorization requests, token introspection, userinfo, end-session), performs WebAuthn registration/login ceremonies, issues and rotates signed JWTs, and exposes a SvelteKit admin console for managing users, groups, OIDC clients, API permissions, API keys, application config, and audit logs. It also supports SCIM 2.0 provisioning, LDAP directory sync, one-time access codes, email verification, signup flows, and transactional email notifications with per-user locale. Architecturally it is a modular monolith: a Go backend (backend/cmd/main.go as the entry point) built on Gin, GORM, and a fork of the Fosite OIDC framework, with the SvelteKit frontend embedded and served by the same process. Data flows are typical of an IdP: browser/SP clients hit OIDC endpoints, the backend persists users, tokens, clients, and audit events to SQLite or PostgreSQL (50+ up/down migrations for each), reads/writes user content through a filesystem/S3/database storage abstraction, and delegates ephemeral state and cron jobs (token cleanup, API key expiry, back-channel logout, rate limiting) to the Francis actor runtime. External dependencies include SMTP servers, LDAP directories, SCIM providers, MaxMind GeoLite2 downloads for audit-log geolocation, optional S3-compatible object storage, and optional standalone Francis. The codebase shows strong engineering discipline: dependency-injected services, a layered DTO mapping and validation layer with stable error codes, an authorization scope catalog enforced at the router level, middleware for CSP/CORS/rate limiting/CSRF, a generic TTL cache with singleflight, SSRF-guarded outbound HTTP with per-purpose host allowlists, field-level encrypted strings, and callback-URL wildcard validation. Tests are extensive and include Go unit tests, migration parity checks between SQLite and PostgreSQL, route-scope coverage tests, and Playwright E2E suites. The main maintenance risks are the forked Fosite dependency, the non-trivial operator complexity of the Francis actor runtime, and a high rate of schema migrations; HA mode is explicitly experimental. This is unambiguously an application repository; its only data-adjacent features are IP-geolocation enrichment and an opt-in analytics heartbeat.
Better Auth is a framework-agnostic authentication and authorization framework for TypeScript, designed as a monorepo with a core library, multiple database adapters (Drizzle, Prisma, Kysely, MongoDB, in-memory), client SDKs (React, Vue, Svelte, Solid, Expo, Electron), and a plugin ecosystem. It supports email/password, OAuth2/OIDC, SAML, SCIM, passkeys, 2FA, phone number OTP, and more. The architecture is modular: the core package provides the `betterAuth()` function, which configures plugins, database adapters, and social providers, and exposes a REST API for authentication flows. Client libraries use nanostores for reactive state management. The CLI offers project scaffolding, migration generation, and schema validation. External dependencies include jose for JWT, zod for validation, and various ORMs for database access. The codebase is well-tested with unit, integration, and e2e tests across all packages, and includes a release tooling package with AI-assisted changelog generation.
opkssh is a production-grade CLI tool that bridges OpenID Connect (OIDC) authentication with SSH access. It allows users to authenticate via any OIDC provider (Google, Azure, GitLab, Keycloak, etc.) and obtain short-lived SSH certificates embedding OpenPubkey PK tokens. The server-side component, invoked as sshd's AuthorizedKeysCommand, verifies these certificates against policy files and grants access based on email, subject, or group membership. The architecture is a single Go binary with client and server modes, using Cobra for CLI commands. Key entry points include `opkssh login` (interactive OIDC flow, SSH key generation, agent integration), `opkssh verify` (server-side certificate validation and policy enforcement), `opkssh add` (policy management), and `opkssh audit` (configuration validation). External dependencies include the openpubkey library for PK token operations, afero for filesystem abstraction, and testcontainers for integration tests. The tool supports Linux, macOS, and Windows, with platform-specific file permission checks and ACL handling. It also features a policy plugin system for custom access control logic via external scripts.
Authorizer is a self-hosted, production-grade authentication and authorization server written in Go. It implements OAuth 2.0 / OIDC, SAML IdP/SP, SCIM 2.0, WebAuthn/passkeys, TOTP, email/SMS OTP, and fine-grained authorization via an embedded OpenFGA engine. The architecture is transport-agnostic: a shared service layer (internal/service) is called by GraphQL resolvers, gRPC handlers, and HTTP handlers (Gin). It supports multiple storage backends (SQL, MongoDB, Cassandra, DynamoDB, Couchbase, ArangoDB) via a unified storage.Provider interface, plus Redis and in-memory stores for sessions and caching. The system includes a React admin dashboard, an end-user login SPA, and an MCP (Model Context Protocol) server for AI tool exposure. Security is a primary focus, with extensive regression tests for CVEs, SSRF protection, constant-time comparisons, and audit logging.
This is a TypeScript library implementing an OpenID Connect (OIDC) and OAuth2 client for browser-based applications. It supports Authorization Code Grant with PKCE, refresh tokens, resource owner password credentials, and DPoP, while explicitly excluding the deprecated implicit grant. The library provides both a low-level `OidcClient` for raw protocol operations and a higher-level `UserManager` with session management, event notifications, and automatic silent token renewal via iframes or pop-ups. It is a fork of the archived `oidc-client-js` project, ported to TypeScript with strict typing, comprehensive testing (vitest, jsdom), and modern build tooling (esbuild, ESLint, Husky). The architecture is cleanly layered: a settings store with defaults, navigator abstraction for browser UI (redirect, popup, iframe), storage abstraction for state persistence (in-memory, localStorage, IndexedDB), and an event system for lifecycle callbacks. The codebase demonstrates high craftsmanship with well-isolated, reusable components such as the generic Event emitter, a sleep-aware Timer, and a strategy-pattern for navigation. DPoP support is implemented with secure key storage in IndexedDB and automatic nonce retry. External runtime dependencies are minimal (only `jwt-decode`). Active maintenance is evidenced by regular commits, dependabot configuration, CI workflows, and a versioned release process. This library is suitable for any browser-based SPA requiring standards-compliant OIDC/OAuth2 authentication.
Pomerium is an identity-aware access proxy that provides zero-trust security for internal web applications and services. It acts as a reverse proxy that authenticates users via OIDC/OAuth2 providers, authorizes access based on policy rules (Pomerium Policy Language evaluated via OPA/Rego), and proxies HTTP, gRPC, WebSocket, and SSH traffic. The system is built as a multi-service architecture with gRPC-based inter-service communication, using Envoy as the underlying proxy engine. Key components include an authentication service, authorization service with policy evaluator, a distributed databroker for session/config storage (with Raft consensus), and a control plane that generates Envoy configuration dynamically. It supports multiple identity providers (Google, Okta, Azure, Auth0, etc.), mTLS client certificates, WebAuthn, and SSH tunneling with a TUI client. The codebase also includes a Model Context Protocol (MCP) implementation for AI tool access control, and a 'Zero' cloud-managed mode for enterprise deployments. External dependencies include Envoy, PostgreSQL, Pebble (RocksDB), and cloud blob storage (S3, GCS, Azure Blob). Architecturally, Pomerium follows a modular design with clear separation of concerns: configuration management (layered sources, validation, envoy config builders), policy engine (parser, generator, criteria matchers), storage abstraction (in-memory, file, postgres, blob with caching and querier patterns), telemetry (OpenTelemetry, Prometheus, health checks), and utility packages (cryptography, HTTP, gRPC, protobuf, retry, fanout). The system is highly configurable with runtime flags and supports hot-reload via config diffing. The codebase demonstrates strong engineering practices with extensive unit, integration, and end-to-end tests (Playwright-based acceptance suites). Data flows: Incoming requests are intercepted by Envoy, which forwards them to the Pomerium proxy service. The proxy authenticates the user via the authenticate service (OIDC/OAuth2 flows), then authorizes via the authorize service (policy evaluation with OPA/Rego). Session and user data are stored in the databroker (distributed key-value store with Raft replication). Configuration is managed centrally and distributed to all services via gRPC streams. Telemetry data (traces, metrics, logs) is exported via OpenTelemetry and Prometheus.
This is a monorepo for Auth.js (formerly NextAuth.js), a framework-agnostic authentication library for web applications. The core engine (`@auth/core`) handles OAuth/OIDC, email/passwordless, credentials, and WebAuthn/Passkey authentication flows. It provides a unified API for session management (JWT or database-backed), CSRF protection, and cookie handling. The library is designed to be integrated into multiple frameworks via separate packages: `@auth/nextjs`, `@auth/sveltekit`, `@auth/express`, `@auth/qwik`, and `@auth/solid-start`. Each framework package adapts the core `Auth` function to the framework's request/response model, offering server-side handlers, middleware, and client-side hooks. The repository also includes over 80 built-in OAuth/OIDC provider definitions (e.g., Google, GitHub, Discord, Auth0) and 20+ database adapters (e.g., Prisma, Drizzle, MongoDB, PostgreSQL, DynamoDB) that implement a standard `Adapter` interface for user persistence. The project is now part of Better Auth, and the README recommends new projects use Better Auth unless specific feature gaps exist. The monorepo contains development apps, example applications, and a comprehensive documentation site built with Nextra.
MSAL Python is a production-grade OAuth2/OIDC client library for the Microsoft identity platform (Entra ID / Azure AD, ADFS, MSA). It implements the full token acquisition lifecycle: authorization code, client credentials, device code, ROPC, on-behalf-of, and managed identity flows, plus WS-Trust for legacy ADFS federation. The library exposes two primary application classes — PublicClientApplication (desktop/mobile) and ConfidentialClientApplication (web apps/daemons) — built on a shared ClientApplication base with an embedded oauth2cli sub-package for low-level OAuth2 protocol handling. It also supports broker integration via pymsalruntime, proof-of-possession tokens, and regional endpoints.
This repository is a Home Assistant custom component that implements a full OpenID Connect (OIDC) Client/Relying Party for authentication. It allows Home Assistant users to log in via an external OIDC Identity Provider (IdP) such as Authentik, Authelia, Keycloak, or any standard OIDC-compliant server. The integration registers a custom auth provider within Home Assistant's auth system, intercepts the default login flow to redirect users to the OIDC provider, and handles the full authorization code flow including PKCE (RFC 7636), ID token validation with configurable signing algorithms, and userinfo retrieval. It supports both public and confidential clients, device code flow for mobile app login, automatic user linking, role-based access mapping from IdP groups, and a multi-step UI configuration wizard for easy setup.
Rustical is an open-source CalDAV and CardDAV server written in Rust, providing a lightweight, self-hosted alternative for calendar and addressbook synchronization. It implements the core WebDAV extensions (RFC 4791, 6352) with support for CalDAV scheduling, CardDAV group membership, WebDAV Push (web-push) notifications, and a built-in web frontend for management. The architecture is a modular Rust workspace with separate crates for DAV infrastructure, protocol handlers (caldav, carddav), storage abstraction, SQLite backend, XML serialization, OIDC authentication, and a Lit-based web UI. The server exposes RESTful HTTP endpoints via Axum, uses SQLite for persistence with `sqlx`, and supports app tokens, OIDC, and Nextcloud login for authentication. The codebase demonstrates solid engineering with thorough integration tests, snapshot testing, CI/CD pipelines, and a clear separation of concerns. However, it contains some workarounds and TODOs indicating active development rather than a polished final product. The custom XML derive macros and store trait pattern are particularly well-crafted and potentially reusable.
oidc-spa is a production-grade OpenID Connect (OIDC) client library designed for browser-first single-page applications. It implements the Authorization Code + PKCE flow with security-first defaults including in-memory token storage, DPoP (Demonstration of Proof-of-Possession) support, token substitution to prevent token leakage, and browser runtime freezing to resist monkey-patching attacks. The library provides framework-specific adapters for React, Angular, Next.js, Nuxt, TanStack Start, and React Router, each offering hooks, guards, and middleware for seamless authentication integration. It also includes a Vite plugin for build-time injection, a mock OIDC adapter for testing, and server-side utilities for access token validation (RFC 9068). The core is framework-agnostic, with a custom reactive event system (Evt) for state management and cross-tab synchronization via BroadcastChannel. The repository contains extensive example applications demonstrating login/logout, protected routes, role-based access, and auto-logout overlays across multiple frameworks.
This is an Angular SDK library (`@auth0/auth0-angular`) that integrates Auth0 authentication (OAuth2/OIDC) into Angular single-page applications. It wraps the Promise-based `@auth0/auth0-spa-js` into Angular's reactive ecosystem using RxJS Observables, dependency injection, and Angular Router. The library provides core authentication flows (redirect/popup login, logout, token management), route protection via guards, automatic bearer token injection via HTTP interceptors, and additional features such as MFA, passkeys (WebAuthn), enterprise account linking, custom token exchange, and a MyAccount API client. It supports both traditional NgModule-based and modern standalone (functional) Angular patterns. The playground application included serves as a development and e2e test harness with a local OIDC provider. The architecture is clean, well-tested, and follows Angular best practices, though the core logic is delegated to the underlying Auth0 SPA SDK.
VoucherVault is a self-hosted Django web application for digitally managing vouchers, gift cards, coupons, and loyalty cards. It provides a full CRUD interface with features like barcode/QR code scanning, expiry notifications via Apprise, multi-currency support via Fixer.io, offline-first capabilities (service worker + IndexedDB sync), OIDC authentication, item sharing between users, and a PWA manifest for mobile installation. The architecture is a monolithic Django app with Celery for background tasks (expiry checks), Redis as a message broker, and optional PostgreSQL or SQLite databases. The frontend uses the NiceAdmin Bootstrap template with custom dark mode and charting via ECharts. The codebase is well-organized with clear separation of concerns (models, views, forms, templates, static assets) and includes internationalization for English, German, French, and Italian. While the application is feature-rich and actively maintained, it lacks automated tests and has some code duplication in templates, which limits its quality score.
ThinkWatch is a Rust workspace implementing an AI gateway platform that fronts multiple model providers and MCP (Model Context Protocol) servers. It exposes OpenAI-compatible chat/completion endpoints, streaming, MCP tool-call routing, content filtering, and provider failover. The backend is split into crates: `common` (shared lifecycle/limits/access), `auth` (PoW login, API keys), `gateway` (model routing), `mcp-gateway` (MCP server proxying), `server` (REST admin/audit/trace endpoints), and `test-support` (integration test client). A React/TypeScript frontend in `web/` provides an admin console, setup wizard, limits panels, and MCP server management. Data flows: requests enter the gateway, pass through `check_limits`, `check_budget`, `check_access`, then `run_post_invoke`; `trace_id` is propagated across gateway, MCP, audit, and app logs stored in ClickHouse; Postgres holds users, API keys, budgets, and MCP server configs; Redis/Lua scripts enforce rate limits.
This repository is a Payload CMS authentication plugin (payload-auth-plugin) that provides OAuth2, OIDC, password, and passkey authentication strategies. It is designed to be used with Payload CMS v3+ and integrates deeply with Payload's admin panel and frontend via custom API endpoints, collection field injection, and a client-side library. The plugin supports multiple providers (Google, GitHub, Apple, etc.) via a clean provider factory pattern and manages its own session cookies, credential hashing (PBKDF2), and account linking. The architecture is a plugin that hooks into Payload's lifecycle, extending the CMS with authentication endpoints and database collections. The example application (examples/with-website/) demonstrates a full Payload CMS + Next.js website with admin and public authentication flows. Despite being pre-1.0, the codebase exhibits solid engineering patterns: strategy pattern for endpoint registration, collection helper functions that merge user-defined configs, and a reusable AuthClient class for browser-side authentication. However, it lacks automated tests, has several FIXME comments in passkey and password protocols, and is tightly coupled to Payload's internal DB and cookie mechanisms, which introduces technical drift risk as Payload evolves. The plugin is actively maintained with frequent releases and a changelog documenting 50+ versions.