Sha256: 5093212248d04108fb1db0527e6983db2718c8ac2efde2a080487bdd288a647f

Contents?: true

Size: 1.46 KB

Versions: 13

Compression:

Stored size: 1.46 KB

Contents

module Saml
  module Config
    mattr_accessor :provider_type
    @@provider_type = "service_provider"

    mattr_accessor :max_issue_instant_offset
    @@max_issue_instant_offset = 2

    mattr_accessor :ssl_private_key
    @@ssl_private_key = nil

    mattr_accessor :ssl_certificate
    @@ssl_certificate = nil

    mattr_accessor :http_ca_file
    @@http_ca_file = nil

    mattr_accessor :registered_stores
    @@registered_stores = {}

    mattr_accessor :generate_key_name
    @@generate_key_name = true

    mattr_accessor :default_store

    mattr_accessor :inclusive_namespaces_prefix_list
    @@inclusive_namespaces_prefix_list = "ds saml samlp xs"

    mattr_accessor :include_nested_prefixlist
    @@include_nested_prefixlist = false

    def register_store(name, store, options = {})
      registered_stores[name] = store
      self.default_store = name if options[:default]
    end
    module_function :register_store

    def ssl_private_key_file=(private_key_file)
      if private_key_file.present?
        self.ssl_private_key = OpenSSL::PKey::RSA.new File.read(private_key_file)
      else
        self.ssl_private_key = nil
      end
    end
    module_function :ssl_private_key_file=

    def ssl_certificate_file=(certificate_file)
      if certificate_file.present?
        self.ssl_certificate = OpenSSL::X509::Certificate.new File.read(certificate_file)
      else
        self.ssl_certificate = nil
      end
    end
    module_function :ssl_certificate_file=

  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
libsaml-2.24.3 lib/saml/config.rb
libsaml-2.24.2 lib/saml/config.rb
libsaml-3.0.6 lib/saml/config.rb
libsaml-3.0.5 lib/saml/config.rb
libsaml-3.0.4 lib/saml/config.rb
libsaml-3.0.3 lib/saml/config.rb
libsaml-3.0.2 lib/saml/config.rb
libsaml-3.0.1 lib/saml/config.rb
libsaml-2.24.1 lib/saml/config.rb
libsaml-2.23.2 lib/saml/config.rb
libsaml-2.23.1 lib/saml/config.rb
libsaml-2.22.2 lib/saml/config.rb
libsaml-2.22.1 lib/saml/config.rb