doorkeeper-gem/doorkeeper
60.1
Adequate · 25 October 2026
10.4k
lines of production code
Ruby
primary language
6
measurements over time
What this system is
This system is the Doorkeeper gem, a comprehensive OAuth 2.0 authorization server library for Ruby on Rails applications. It provides the core infrastructure for managing client applications, issuing and validating access tokens, and handling various OAuth grant flows such as Authorization Code, Client Credentials, and Refresh Token. The system includes a configurable web interface for administrators to manage OAuth clients and for end-users to authorize and revoke application access, alongside robust support for modern security standards like PKCE, Private Key JWT, and token introspection.
How it got here
2011 — Doorkeeper 6.0 architectural refactor
30 changes.
This period centered on the major v6.0.0 release of Doorkeeper, which replaced the monolithic model-based architecture with a modular, strategy-based design to support modern OAuth 2.0 standards like PKCE, token introspection, and private key JWT. The work involved restructuring core controllers and libraries, introducing new generators for optional features, and completely redesigning the user interface for authorization and application management. Comprehensive test infrastructure, including a dummy Rails application and extensive spec coverage, was built to validate the new security hardening and configuration systems.
2012 — OAuth architecture refactoring and RFC compliance
20 changes.
The project underwent a comprehensive architectural refactoring to improve modularity and enforce strict RFC 6749/8707/9207 compliance. This involved restructuring core OAuth flows, client authentication, and request handling into dedicated strategy and helper classes, while significantly expanding test coverage across models, endpoints, and routing logic. The period also included updating the UI vendor dependency to Bootstrap 4.
2014–2020 — ORM abstraction and Grape integration
20 changes.
This period focused on refactoring Doorkeeper's model layer into ORM-agnostic mixins to support multiple database backends, alongside introducing a dedicated integration module for Grape APIs. The work also included significant improvements to configuration validation, security features like PKCE and secret rotation, and comprehensive test coverage for these new components.
2021–2026 — OAuth authentication modernization and test expansion
9 changes.
The project modernized its OAuth client authentication system by introducing a registry-based strategy pattern and adding built-in support for private\_key\_jwt, while hardening existing strategies for security compliance. This period also focused on significantly expanding test coverage across database role handling, ORM integration, and the new authentication mechanisms, alongside broadening the Rails version compatibility matrix.
Features
Add Grape integration helpers and authorization decorator
Introduces a new Grape integration module that provides \doorkeeper\_authorize!\ and \doorkeeper\_render\_error\_with\ helpers for Grape applications (version 0.10 and above). The integration includes an \AuthorizationDecorator\ to normalize access token retrieval from various HTTP headers (including \X-HTTP\_AUTHORIZATION\ variants) and implements logic to refuse requests that transmit an access token by more than one method, ensuring consistent and secure authorization behavior within Grape endpoints.
lib/doorkeeper/grape · high confidence
Add authorized applications management view
Users can now view a list of their authorized OAuth applications and revoke access. This change introduces the index page displaying application names and creation dates, along with a delete form that allows users to revoke specific application authorizations via a confirmation dialog.
_app/views/doorkeeper/authorized\applications · high confidence
Add dedicated layouts for Doorkeeper admin and application views
The application now includes specific layout templates for the Doorkeeper OAuth2 engine: \doorkeeper/admin.html.erb\ provides a Bootstrap-styled navigation bar with links to OAuth applications and the home page (conditionally rendered if \root\_path\ is available), while \doorkeeper/application.html.erb\ offers a simpler container layout for standard user-facing OAuth pages. These layouts replace the previous default layout usage, ensuring consistent styling and navigation structure for the authentication provider's interface.
app/views/layouts · high confidence
Add development tooling and configuration files
The repository now includes standard development configuration files to streamline local setup and code quality enforcement. This includes \.rubocop.yml\ and \.rubocop\_todo.yml\ for Ruby linting, \.editorconfig\ for editor consistency, \.gitignore\ and \.dockerignore\ for build artifacts, and configuration for CI/CD and coverage tools (\.codeclimate.yml\, \.coveralls.yml\, \.hound.yml\, \.rspec\). Additionally, \AGENTS.md\ provides a guide for AI agents interacting with the codebase, and \.gitattributes\ configures a union merge driver for \CHANGELOG.md\ to prevent merge conflicts when multiple PRs add changelog entries simultaneously.
(repo-wide) · high confidence
Added Ruby client credentials benchmark
A new Ruby benchmark script has been added to measure the performance of the client credentials grant flow using the Doorkeeper library. The script sets up an in-memory SQLite database, configures Doorkeeper with the necessary grant flows, and uses the benchmark-ips gem to report throughput for token request authorization.
benchmark · high confidence
New generators for optional Doorkeeper features and configuration
Doorkeeper now provides dedicated Rails generators to add optional capabilities and configuration to your application without requiring manual migration writing. These include generators for polymorphic resource owners, PKCE support, resource indicators (RFC 8707), confidential applications, and application ownership. Additional generators handle security and compliance behaviors such as revoking tokens on authorization code reuse, revoking refresh tokens after access token use, and preserving granted scopes on refresh tokens during narrowed refreshes. A new install generator sets up the initializer, routes, and locales, while a views generator allows copying default UI templates. A generator also exists to remove the NOT NULL constraint on application secrets for public clients.
lib/generators/doorkeeper · high confidence
New interactive console for Doorkeeper development and testing
A new \bin/console\ script has been added, allowing developers to launch an interactive IRB session pre-configured with the Doorkeeper gem, Rails, and an in-memory SQLite database loaded with the dummy schema. This environment automatically logs Doorkeeper and Rails versions and configures the ORM to Active Record, facilitating easier debugging and experimentation without needing a full application setup.
bin · high confidence
New rake tasks for cleaning up stale Doorkeeper database records
Users can now run \rake doorkeeper:db:cleanup\ to remove stale data from Doorkeeper tables. This task orchestrates four sub-tasks: removing revoked and expired access tokens, and revoked and expired access grants. The cleanup of expired access tokens is specifically limited to those without a refresh token, ensuring that active sessions are not inadvertently cleared while still allowing for the removal of orphaned or expired credentials.
lib/doorkeeper/rake · high confidence
Architecture
Refactor models into ORM-agnostic mixins
The model implementations in lib/doorkeeper/models have been refactored into standalone mixin modules (AccessGrantMixin, AccessTokenMixin, ApplicationMixin) that encapsulate core OAuth behaviors such as token lookup, secret matching, PKCE support, and scope validation. This change separates the domain logic from specific ORM dependencies, allowing Doorkeeper to support multiple database backends (e.g., ActiveRecord, Mongoid) by providing ORM-specific adapters that include these mixins, rather than embedding database-specific code directly in the models.
lib/doorkeeper/models · high confidence
Refactored request handling into dedicated strategy classes
The request processing logic for OAuth flows (Authorization Code, Client Credentials, Password, Refresh Token, and Pre-authorization) has been restructured into specific strategy classes under \Doorkeeper::Request\. Each flow now has its own class (e.g., \AuthorizationCode\, \Password\) that delegates to the server context and constructs the corresponding \OAuth::Request\ object. This change isolates the logic for each grant type, making the codebase more modular and easier to maintain, while introducing a base \Strategy\ class to standardize initialization and request construction.
lib/doorkeeper/request · high confidence
Behavioural changes
Active Record-specific redirect URI validation and stale token cleanup
This change introduces two new Active Record-specific components: a RedirectUriValidator that enforces OAuth standards by rejecting script schemes, fragments, relative URIs, and unsecured HTTP URis (when SSL is forced), and a StaleRecordsCleaner that provides rake-task support for cleaning revoked and expired tokens, including logic to handle expiration time math and nil TTLs. Users will see stricter validation on redirect URIs and the ability to clean up stale database records via the new cleaner.
_lib/doorkeeper/orm/active\record · high confidence
Bootstrap 4-compatible form error rendering in Doorkeeper dashboard
The Doorkeeper dashboard helper now renders validation errors using Bootstrap 4's 'invalid-feedback' CSS class instead of previous styling, ensuring form error messages display correctly with the updated Bootstrap 4.0 framework. The helper also provides a submit path method that dynamically determines the correct OAuth application path based on whether the application is persisted.
app/helpers · high confidence
Configure Claude to use shared agent skills
The .claude directory now uses symlinks to point CLAUDE.md to ../AGENTS.md and the skills directory to ../.agents/skills. This change allows the Claude tooling to access the project's central agent definitions and skills without duplicating content, ensuring that updates to the main agent configuration are automatically reflected in the Claude environment.
.claude · high confidence
Cursor rules now reference AGENTS.md
The .cursor/rules file has been added as a symbolic link pointing to the project root's AGENTS.md file, ensuring that Cursor AI configuration is centralized in a single location.
.cursor · high confidence
Doorkeeper 6.0 introduces a new OAuth architecture with hardened security and modernized configuration
Doorkeeper 6.0 replaces the legacy \client\_credentials\ configuration with a new \client\_authentication\ registry (RFC 6749 §2.3), allowing developers to explicitly define and order authentication methods like \client\_secret\_basic\ and \private\_key\_jwt\. The authorization and token endpoints are now driven by a new \GrantFlow\ registry, which decouples request handling from hardcoded logic. Security is significantly improved with a new \HttpFetcher\ that prevents Server-Side Request Forgery (SSRF) by validating DNS resolutions against RFC 6890 special-use ranges and pinning connections to vetted addresses. The gem also introduces a thread-safe \DocumentCache\ for JWKS fetching, a new \SecretStoring\ strategy system (supporting BCrypt, SHA256, and plain text), and stricter validation that rejects requests using multiple client authentication methods or multiple access token transmission methods.
lib/doorkeeper · high confidence
Doorkeeper v6.0.0: Major architectural refactor and new OAuth features
This release introduces a complete internal restructuring of the Doorkeeper library, moving from a monolithic model-based approach to a modular, strategy-based architecture. Key changes include the extraction of ORM logic into separate adapters (defaulting to ActiveRecord), the introduction of a new request/response object model for OAuth flows (Authorization Code, Client Credentials, Password, Refresh Token), and support for modern OAuth 2.0 standards such as RFC 7523 (Private Key JWT client authentication), RFC 8414 (OAuth 2.0 Authorization Server Metadata), and RFC 7662 (Token Introspection). The configuration system has been rewritten to support lazy evaluation and granular setup, while deprecated methods like \doorkeeper\_for\ have been removed in favor of new helpers. This is a breaking change that requires users to update their configuration blocks and potentially adjust custom ORM implementations.
lib · high confidence
New built-in private\_key\_jwt client authentication and hardened authentication strategies
Doorkeeper now includes a built-in implementation of the private\_key\_jwt client authentication method (RFC 7523), allowing clients to authenticate using JWT assertions signed with asymmetric keys instead of shared secrets. This feature includes configurable JWKS caching and replay protection to prevent assertion reuse. Additionally, the library introduces a structured client authentication registry with dedicated strategies for client\_secret\_basic, client\_secret\_post, and none (public clients). The none strategy has been hardened to strictly reject requests carrying header-based authentication (like Basic auth) unless they are explicitly Bearer-token authorized for the endpoint, preventing public clients from being silently misidentified. The client\_secret\_basic strategy now enforces RFC 7521 §4.2 by requiring the client\_id in the request body to match the identity established by the Basic header, rejecting mismatched credentials.
_lib/doorkeeper/oauth/client\authentication · high confidence
New controller helper module for authentication and request handling
A new \Doorkeeper::Helpers::Controller\ module is introduced to provide shared methods for controllers inheriting from \Doorkeeper::ApplicationMetalController\ or \Doorkeeper::ApplicationController\. This module exposes \current\_resource\_owner\ as a view helper, implements \authenticate\_resource\_owner!\ and \authenticate\_admin!\ using configured blocks, and adds \doorkeeper\_token\ which safely handles multiple access token transmission errors by returning nil instead of raising. It also includes \skip\_authorization?\ to check pre-authorization settings, \enforce\_content\_type\ to reject non-form-urlencoded PUT/PATCH/POST requests, and error handling methods \get\_error\_response\_from\_exception\ and \handle\_token\_exception\ to standardize OAuth error responses.
lib/doorkeeper/helpers · high confidence
New extensible routing architecture with controller customization and skipping
The route generation logic has been refactored into a reusable mapping system that allows users to customize which controllers are used, change route name aliases, and skip specific controllers entirely. This change introduces new internal classes (Mapper, Mapping, AbstractRouter, Registry) to handle route definition, enabling extensions to register additional routes and giving application developers finer control over the Doorkeeper routing setup without modifying core code.
lib/doorkeeper/rails/routes · high confidence
New styling for Doorkeeper authorization pages
The application now includes a dedicated stylesheet for Doorkeeper's authorization and management interfaces. This change introduces a centered, card-style layout with a light gray background, rounded corners, and shadow effects for the main container, ensuring that OAuth permission forms and authorized application lists are displayed with a consistent, modern visual design.
app/assets/stylesheets/doorkeeper · high confidence
Redesigned OAuth application management interface
The web frontend for managing OAuth applications has been completely rewritten with a modern, responsive layout. Users can now create, edit, and view applications through a structured form that includes validation feedback for fields like name, redirect URI, confidentiality, and scopes. The application detail page provides a clear overview of the client ID, secret (with support for hashed secrets), assigned scopes, and callback URLs, while the index page lists all applications with quick actions to edit or delete them.
app/views/doorkeeper/applications · high confidence
Redesigned OAuth authorization flow with form\_post support and resource indicators
The authorization views have been completely rewritten to support modern OAuth 2.0 flows. Users now see a dedicated consent screen (new.html.erb) that explicitly lists requested scopes and any resource indicators, along with custom access token attributes. The flow now supports the 'form\_post' response mode via a new view (form\_post.html.erb) that automatically submits the authorization response via a hidden form, improving compatibility with certain clients. Additionally, a new error view (error.html.erb) provides clearer error descriptions to users, and the authorization code display (show.html.erb) has been updated with accessibility improvements. These changes enhance security (via PKCE support fields), usability, and compliance with OAuth 2.0 specifications.
app/views/doorkeeper/authorizations · high confidence
Refactor client authentication into a registry-based strategy system
Client authentication is now managed through a new registry and strategy pattern, replacing the previous monolithic logic. This change introduces a \Registry\ to register and look up authentication methods, a \FallbackMethod\ to preserve existing behavior for unauthenticated requests, and a \LegacyCallable\ adapter to ensure backward compatibility with custom \client\_credentials\ extractors during the deprecation window. Additionally, a \VerifiedCredentials\ class is added to handle pre-authenticated clients (such as those using private\_key\_jwt) by skipping secret comparisons, ensuring that identity proofs verified by specific strategies are respected without redundant checks.
_lib/doorkeeper/client\authentication · high confidence
Refactor model concerns and add polymorphic resource owner support
The model concerns in lib/doorkeeper/models/concerns have been reorganized into distinct modules (Accessible, Expirable, Orderable, Ownership, PolymorphicResourceOwner, ResourceOwnerable, Reusable, Revocable, Scopes, SecretStorable, and WriteToPrimary) to improve code structure and maintainability. A key behavioral change is the introduction of polymorphic resource owner support, allowing access grants and access tokens to associate with any model type via a polymorphic belongs\_to relationship when the polymorphic\_resource\_owner configuration is enabled. Additionally, the Reusable concern now enforces token reuse limits based on the token\_reuse\_limit configuration, and the SecretStorable concern includes logic to conditionally upgrade fallback secrets to the new storage strategy while ensuring writes target the primary database when multiple database roles are enabled.
lib/doorkeeper/models/concerns · high confidence
Refactored Active Record model mixins with improved secret handling and performance
The Active Record model mixins for AccessGrant, AccessToken, Application, and SecretStorable have been rewritten to improve security, performance, and configurability. Secret storage now uses a conditional upgrade strategy that prevents race conditions during secret rotation, and applications support custom secret generators. Access token refresh logic has been optimized to support a 'revoke-on-use' pattern via a new \previous\_refresh\_token\ column, reducing database lock contention. Additionally, strict loading is disabled by default for these models, and serialization now correctly uses \as\_json\ to respect privacy settings and custom application classes.
_lib/doorkeeper/orm/active\record/mixins · high confidence
Refactored ActiveRecord ORM model loading to use standard Ruby autoload
The ActiveRecord ORM implementation now uses standard Ruby \autoload\ for all model classes (AccessGrant, AccessToken, Application, RedirectUriValidator) and mixins, replacing the previous reliance on \ActiveSupport.on\_load(:active\_record)\. This change ensures that model concerns are included at the correct time during class loading, preventing issues with deferred loading and configuration application, while keeping the \run\_hooks\ method as a no-op for compatibility.
lib/doorkeeper/orm · high confidence
Refactored Client Credentials flow with token reuse and revocation controls
The Client Credentials grant flow has been restructured into dedicated Creator, Issuer, and Validator components. This change introduces configurable token reuse logic, allowing existing valid tokens to be returned instead of issuing new ones, and adds a \revoke\_previous\_client\_credentials\_token\ configuration option to control whether previous tokens are revoked upon reuse. The implementation also ensures that token matching considers custom access token attributes and resource indicators, and validates that the client application explicitly supports the Client Credentials grant flow.
_lib/doorkeeper/oauth/client\credentials · high confidence
Refactored OAuth controllers into a modular, API-mode-aware architecture
The Doorkeeper controllers have been restructured into a clear inheritance hierarchy: \ApplicationController\ serves as the base (handling admin authentication, CSRF protection, and API-mode mime negotiation), while \ApplicationMetalController\ provides a lightweight base for API-only endpoints. \ApplicationsController\ now explicitly forces JSON format in API mode to prevent HTML negotiation failures, and \AuthorizationsController\ introduces pre-authorization client validation and supports form\_post responses. New endpoints include \MetadataController\ for OAuth 2.0 Authorization Server Metadata (RFC 8414), \AuthorizedApplicationsController\ for listing and revoking user-authorised apps, and \TokenInfoController\ for token introspection (RFC 7662). The \TokensController\ now implements RFC 7009 token revocation with strict client ownership checks and supports both access and refresh token revocation via a unified hint-based lookup.
app/controllers · high confidence
Refactored OAuth helper modules for scope, token, and URI validation
The OAuth helper logic has been reorganized into three new dedicated modules: ScopeChecker, UniqueToken, and URIChecker. ScopeChecker now validates scopes against server and application-level configurations, including support for grant-type restrictions. UniqueToken centralizes access token generation, allowing configuration of the generator method and token size. URIChecker implements stricter URI validation, including blocking script schemes (javascript, vbscript, data), enforcing RFC 6749 simple string comparison for redirect URIs, and handling loopback interface variations per RFC 8252.
lib/doorkeeper/oauth/helpers · high confidence
Refactored OAuth request handling and added RFC 8707 resource indicator support
The OAuth request logic in \lib/doorkeeper/oauth\ has been restructured into a class-based hierarchy (e.g., \AuthorizationCodeRequest\, \BaseRequest\) to improve maintainability and consistency across grant types. This change introduces support for RFC 8707 Resource Indicators, allowing access tokens to be restricted to specific resource audiences via the \resource\ parameter. Additionally, the \PreAuthorization\ class now validates client details before resource owner authentication, enabling earlier error responses for invalid clients or redirect URIs without requiring a login. The \OAuth::Client\ class was also updated to use the new client authentication registry, and various response classes (\ErrorResponse\, \CodeResponse\) were refactored to support RFC 9207 issuer identification and improved error handling.
lib/doorkeeper/oauth · high confidence
Refactored authorization flow with token expiration controls and URI query deduplication
The authorization logic has been restructured into dedicated classes (Context, Token, URIBuilder) to improve maintainability and introduce new security and configuration capabilities. Users can now configure custom access token expiration times via a lambda and enforce shorter lifetimes for public clients using the new \public\_client\_access\_token\_expires\_in\ setting. The authorization callback now correctly handles duplicate query parameters by ensuring response parameters take precedence over existing ones in the redirect URI, preventing potential injection issues. Additionally, the token issuance process now supports resource indicators (RFC 8707) and allows for non-expiring tokens when explicitly configured.
lib/doorkeeper/oauth/authorization · high confidence
Refactored authorization helpers and route generation
Doorkeeper now uses a dedicated \Doorkeeper::Rails::Helpers\ module to manage authorization checks and error rendering, restoring the \doorkeeper\_authorize!\ helper and allowing custom rendering options for unauthorized, forbidden, and bad request errors. The routing layer has been restructured into a modular \Doorkeeper::Rails::Routes\ system that explicitly defines endpoints for authorizations, tokens, revocation, introspection, token info, applications, and OAuth 2.0 Authorization Server Metadata, with introspection routes conditionally disabled based on configuration.
lib/doorkeeper/rails · high confidence
Refactored client authentication, grant flows, and error handling architecture
Doorkeeper has restructured its internal architecture to improve modularity and RFC compliance. Client authentication is now handled via a registry of strategies (lib/doorkeeper/client\_authentication), allowing for more flexible method matching and explicit rejection of requests using multiple authentication methods. Grant flows are now defined by explicit Flow objects (lib/doorkeeper/grant\_flow/flow) that match grant types, response types, and response modes. Error handling has been standardized with a new hierarchy of specific error classes (lib/doorkeeper/errors) that map directly to OAuth error codes and descriptions. Additionally, the library now supports database-specific SQL generation for token expiration times (lib/doorkeeper/models/concerns/expiration\_time\_sql\_math) and introduces a RevocableTokens abstraction to manage token revocation logic.
doorkeeper · high confidence
Refactored configuration DSL and added boot-time validation warnings
The configuration system has been refactored to use a reusable DSL (AbstractBuilder and Option module), allowing extensions to define their own config options. Additionally, the gem now performs comprehensive validation at boot time, issuing warnings or errors for misconfigurations such as unknown client authentication methods, missing issuer identity for private\_key\_jwt, invalid PKCE methods, and the use of deprecated grant flows or secret fallback strategies.
lib/doorkeeper/config · high confidence
Separate admin layout styles for Doorkeeper
The Doorkeeper admin interface now uses a dedicated stylesheet to manage its layout independently from the user-facing views. This change introduces a specific rule to constrain the width of error fields within form groups to 16.66667%, ensuring consistent styling for validation messages in the admin section.
app/assets/stylesheets/doorkeeper/admin · high confidence
Updated Doorkeeper generator templates with new migration files and configuration options
The generator templates for Doorkeeper have been updated to support new database schema features and configuration options. New migration templates have been added to enable polymorphic resource owners (allowing applications to be owned by different model types), PKCE (Proof Key for Code Exchange) support via code challenge columns, resource indicators, and the tracking of previous refresh tokens and refresh token scopes. The main migration template now includes a \confidential\ boolean column for applications and an index on \access\_token\_id\ in the access grants table to support authorization code reuse revocation. Additionally, the initializer template has been refreshed with documentation and configuration options for multiple database roles, public client token expiration limits, token reuse settings, and custom access token expiration logic.
lib/generators/doorkeeper/templates · high confidence
Upgrade to Bootstrap 4.0
The vendorized Bootstrap CSS has been updated to version 4.0.0. This change brings modern CSS features such as CSS custom properties (variables), a new flexbox-based grid system, and updated component styles for forms, buttons, and tables, which may alter the visual appearance and layout of the application's UI.
vendor · high confidence
Test coverage
Add ActiveRecord ORM support for test suite; Add dummy Rails application initializer templates for testing; Add dummy app schema.rb for test database setup; Add test environment configuration for the dummy application; Added FactoryBot support file; Added RSpec support helpers for configuration inspection and view rendering assertions; Added User model for dummy application testing; Added comprehensive test coverage for OAuth request and response classes; Added controller specs for Doorkeeper components; Added dummy Rails application for testing; Added dummy application controllers for testing OAuth integration; Added dummy application views for testing; Added integration tests for Grape API support; Added integration tests for protected resource access and token validation; Added model specs for AccessGrant, AccessToken, Application, and PolymorphicResourceOwner; Added request specs for OAuth endpoints; Added request specs for applications and authorized applications endpoints; Added routing specs for custom controllers, scoped routes, and defaults; Added shared test contexts and examples for token and hashing specs; Added test coverage for OAuth authorization flows and URI handling; Added test coverage for OAuth client authentication strategies; Added test coverage for OAuth helper modules; Added test coverage for OAuth hooks context and Rails router components; Added test coverage for Sprockets 4 asset compilation; Added test coverage for core library components; Added test coverage for grant flow registration and matching logic; Added test coverage for model concerns; Added test coverage for redirect URI validation, server strategy handling, stale record cleaning, and version reporting; Added test coverage for the Client Credentials flow components; Added test fixture for generated routes file; Added test helper for user session management; Added test infrastructure with factories and coverage tracking; Added tests for ActiveRecord ORM integration and rake tasks; Added tests for Doorkeeper dashboard helper error rendering; Added tests for Doorkeeper generator specs; Added tests for database role support and SQL expiration math; Added unit tests for the Strategy base class; Comprehensive request specs for OAuth grant flows and authentication methods; New test helper modules for OAuth flows and configuration; Updated dummy app database schema for testing.
Dependencies
Expanded test matrix for Rails 7.0 through 8.1 and edge
The gemfile configuration has been updated to include dedicated Appraisal files for Rails versions 7.0, 7.1, 7.2, 8.0, 8.1, and the Rails edge branch, significantly broadening the supported test matrix. This change ensures compatibility testing across these specific Rails releases, with Rails 8.0 and 8.1 configurations also pinning the sqlite3 gem to version 2.3 and constraining the json gem to below version 3.0 to address Active Support compatibility issues.
gemfiles · high confidence
Update Rails support to 7.0–8.2 and modernize development dependencies
The gem now requires Ruby 3.2 or higher and supports Rails versions from 7.0 up to (but not including) 8.2. Development tooling has been updated to use RSpec 8, Rubocop 1.72 with its associated linter extensions, FactoryBot 6, Database Cleaner 2, and the modern Ruby 'debug' gem, while pinning the 'json' gem below version 3 to maintain compatibility with Active Support's JSON handling.
(dependencies) · high confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 64 → 60 (-4.1)
Lenses
- Code Health 75 → 75 (+0.0)
- Architecture 83 → 81 (-1.5)
- Maturity 57 → 63 (+5.1)
- Readiness 71 → 71 (+0.0)
- Security 81 → 81 (+0.0)
- Domain Modelling 100 → 100 (+0.0)
- Accessibility 64 → 49 (-14.7)
- Performance 80 → 80 (+0.0)
Resolved (4)
- Ambiguous naming for configuration accessors. 'client_authentication' and 'client_authentication_methods' are semantically very close. It is unclear if one returns the configured strategy object(s) and the other returns the list of supported methods, or if they are aliases. This lack of distinct naming convention (e.g., 'supported_methods' vs 'active_strategy') creates cognitive load.
- Inconsistent naming pattern for token-related configuration. 'client_credentials_methods' refers to the grant type flow, while 'access_token_methods' likely refers to the strategy for generating/accessing tokens. The parallel structure is broken; one uses the grant name, the other uses the resource name. This makes it hard to predict the name of other similar config options.
- Off-boarding risk: anonymized user #1
- Redundant configuration entry points. Both methods appear to initialize or configure the library's state. 'configure' suggests a block-based DSL (common in Rails engines), while 'setup' is a generic imperative method. Having both exposes two ways to achieve the same result, confusing users about which is the canonical entry point.
New (1)
- Off-boarding risk: anonymized user #1
Changes since last survey
- 8 commits — 8 feature/other, 0 fixes
By area
- (repo) — 3 commits
- lib/doorkeeper — 2 commits
- (root) — 1 commit
- spec/lib — 1 commit
- spec/requests — 1 commit
Notable commits
- change: Accept client ID metadata documents for public clients (#1956)
- change: Assert per rejected client_id that no metadata document was fetched
- change: Document Client ID Metadata Documents in the README
- change: Let operators limit client ID metadata documents with an allow hook
- change: Let the concurrent-row helper create the application like a request would
- change: Merge pull request #1973 from eglitobias/feature/cimd-allowlist
- change: Merge pull request #1974 from doorkeeper-gem/chore/codeql-cimd-spec-alerts
- change: Merge pull request #1976 from doorkeeper-gem/docs/client-id-metadata-documents-readme
Architecture
- Unchanged — 0 containers · 1 contexts · 0 edges
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
doorkeeper-gem/doorkeeper was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 25 October 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit c3df01d0651e06cf940865c5ba0752a6eb211cee — the exact code this score is about.
- Scored under rubric-2026.10.5 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer measure-2026.10.31+preprod-85beac5a16f3.