Module: Puppet::Network::Authorization

Included in:
HTTP::API::IndirectedRoutes, HTTP::API::Master::V3::Authorization
Defined in:
lib/puppet/network/authorization.rb

Constant Summary collapse

@@authconfigloader_class =
nil

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.authconfigloader_class=(klass) ⇒ Object



26
27
28
# File 'lib/puppet/network/authorization.rb', line 26

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

Instance Method Details

#authconfigObject



30
31
32
33
# File 'lib/puppet/network/authorization.rb', line 30

def authconfig
  authconfigloader = @@authconfigloader_class || AuthConfigLoader
  authconfigloader.authconfig
end

#check_authorization(method, path, params) ⇒ Object

Verify that our client has access.



36
37
38
# File 'lib/puppet/network/authorization.rb', line 36

def check_authorization(method, path, params)
  authconfig.check_authorization(method, path, params)
end