Class: Puppet::SSL::Validator Deprecated

Inherits:
Object
  • Object
show all
Defined in:
lib/puppet/ssl/validator.rb

Overview

Deprecated.

API for certificate verification

Direct Known Subclasses

NoValidator

Defined Under Namespace

Classes: DefaultValidator, NoValidator

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.default_validatorPuppet::SSL::Validator

Factory method for creating an instance of the default Puppet validator. This method does not have to be implemented by concrete implementations of this API.

Returns:



27
28
29
# File 'lib/puppet/ssl/validator.rb', line 27

def self.default_validator()
  Puppet::SSL::Validator::DefaultValidator.new()
end

.no_validatorPuppet::SSL::Validator

Factory method for creating an instance of a null/no validator. This method does not have to be implemented by concrete implementations of this API.

Returns:



16
17
18
# File 'lib/puppet/ssl/validator.rb', line 16

def self.no_validator()
  @@no_validator_cache ||= Puppet::SSL::Validator::NoValidator.new()
end

Instance Method Details

#peer_certsArray<Puppet::SSL::Certificate>

Array of peer certificates

Returns:

Raises:

  • (NotImplementedError)


36
37
38
# File 'lib/puppet/ssl/validator.rb', line 36

def peer_certs
  raise NotImplementedError, "Concrete class should have implemented this method"
end

#setup_connection(connection) ⇒ void

This method returns an undefined value.

Registers the connection to validate.

Parameters:

  • connection (Net::HTTP)

    The connection to validate

Raises:

  • (NotImplementedError)


57
58
59
# File 'lib/puppet/ssl/validator.rb', line 57

def setup_connection(connection)
  raise NotImplementedError, "Concrete class should have implemented this method"
end

#verify_errorsArray<String>?

Contains the result of validation

Returns:

  • (Array<String>, nil)

    nil, empty Array, or Array with messages

Raises:

  • (NotImplementedError)


45
46
47
# File 'lib/puppet/ssl/validator.rb', line 45

def verify_errors
  raise NotImplementedError, "Concrete class should have implemented this method"
end