Sha256: d60cda19149f3cd128493c67be05cd845b90d509954f3f3fa951e4004e759a06

Contents?: true

Size: 696 Bytes

Versions: 9

Compression:

Stored size: 696 Bytes

Contents

# frozen_string_literal: true

require_relative "identity_mapper/base"
require_relative "identity_mapper/none"
require_relative "identity_mapper/sub"
require_relative "identity_mapper/jwt"
require_relative "identity_mapper/manual"

module Aserto
  module IdentityMapper
    STRATEGY = {
      none: Aserto::IdentityMapper::None,
      manual: Aserto::IdentityMapper::Manual,
      sub: Aserto::IdentityMapper::Sub,
      jwt: Aserto::IdentityMapper::Jwt
    }.freeze

    class << self
      def execute(request)
        STRATEGY.fetch(
          Aserto.config.identity_mapping[:type].to_sym || :none,
          Aserto::IdentityMapper::None
        ).execute(request)
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
aserto-0.31.3 lib/aserto/identity_mapper.rb
aserto-0.31.2 lib/aserto/identity_mapper.rb
aserto-0.31.1 lib/aserto/identity_mapper.rb
aserto-0.31.0 lib/aserto/identity_mapper.rb
aserto-0.30.6 lib/aserto/identity_mapper.rb
aserto-0.30.5 lib/aserto/identity_mapper.rb
aserto-0.30.4 lib/aserto/identity_mapper.rb
aserto-0.30.1 lib/aserto/identity_mapper.rb
aserto-0.30.0 lib/aserto/identity_mapper.rb