Sha256: c60313a544ab148958bc419849b369616304a87d859ca35449ace47048299cb9

Contents?: true

Size: 1.99 KB

Versions: 7

Compression:

Stored size: 1.99 KB

Contents

require 'doorkeeper'
require 'active_model'
require 'json/jwt'

require 'doorkeeper/request'
require 'doorkeeper/request/id_token'
require 'doorkeeper/request/id_token_token'
require 'doorkeeper/oauth/id_token_request'
require 'doorkeeper/oauth/id_token_token_request'
require 'doorkeeper/oauth/id_token_response'
require 'doorkeeper/oauth/id_token_token_response'

require 'doorkeeper/openid_connect/claims_builder'
require 'doorkeeper/openid_connect/claims/claim'
require 'doorkeeper/openid_connect/claims/normal_claim'
require 'doorkeeper/openid_connect/config'
require 'doorkeeper/openid_connect/response_types_config'
require 'doorkeeper/openid_connect/engine'
require 'doorkeeper/openid_connect/errors'
require 'doorkeeper/openid_connect/id_token'
require 'doorkeeper/openid_connect/id_token_token'
require 'doorkeeper/openid_connect/user_info'
require 'doorkeeper/openid_connect/version'

require 'doorkeeper/openid_connect/helpers/controller'

require 'doorkeeper/openid_connect/oauth/authorization/code'
require 'doorkeeper/openid_connect/oauth/authorization_code_request'
require 'doorkeeper/openid_connect/oauth/password_access_token_request'
require 'doorkeeper/openid_connect/oauth/pre_authorization'
require 'doorkeeper/openid_connect/oauth/token_response'

require 'doorkeeper/openid_connect/orm/active_record'

require 'doorkeeper/openid_connect/rails/routes'

module Doorkeeper
  module OpenidConnect
    def self.signing_algorithm
      configuration.signing_algorithm.to_s.upcase.to_sym
    end

    def self.signing_key
      key =
        if [:HS256, :HS384, :HS512].include?(signing_algorithm)
          configuration.signing_key
        else
          OpenSSL::PKey.read(configuration.signing_key)
        end
      JSON::JWK.new(key)
    end

    def self.signing_key_normalized
      key = signing_key
      case key[:kty].to_sym
      when :RSA
        key.slice(:kty, :kid, :e, :n)
      when :EC
        key.slice(:kty, :kid, :x, :y)
      when :oct
        key.slice(:kty, :kid)
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
doorkeeper-openid_connect-1.5.4 lib/doorkeeper/openid_connect.rb
doorkeeper-openid_connect-1.5.3 lib/doorkeeper/openid_connect.rb
doorkeeper-openid_connect-1.5.2 lib/doorkeeper/openid_connect.rb
doorkeeper-openid_connect-1.5.1 lib/doorkeeper/openid_connect.rb
doorkeeper-openid_connect-1.5.0 lib/doorkeeper/openid_connect.rb
doorkeeper-openid_connect-1.4.0 lib/doorkeeper/openid_connect.rb
doorkeeper-openid_connect-1.3.0 lib/doorkeeper/openid_connect.rb