Class: Puppet::Network::AuthConfig

Inherits:
Object
  • Object
show all
Defined in:
lib/puppet/network/authconfig.rb

Constant Summary collapse

@@authprovider_class =
nil

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(rights = nil) ⇒ AuthConfig

Returns a new instance of AuthConfig.



91
92
93
# File 'lib/puppet/network/authconfig.rb', line 91

def initialize(rights=nil)
  @authprovider = self.class.authprovider_class.new(rights)
end

Class Method Details

.authprovider_classObject



87
88
89
# File 'lib/puppet/network/authconfig.rb', line 87

def self.authprovider_class
  @@authprovider_class || Puppet::Network::DefaultAuthProvider
end

.authprovider_class=(klass) ⇒ Object



83
84
85
# File 'lib/puppet/network/authconfig.rb', line 83

def self.authprovider_class=(klass)
  @@authprovider_class = klass
end

Instance Method Details

#check_authorization(method, path, params) ⇒ Object



95
96
97
# File 'lib/puppet/network/authconfig.rb', line 95

def check_authorization(method, path, params)
  @authprovider.check_authorization(method, path, params)
end