Class: Gem::Security::Policy

Class | Gem::Security::Policy
In: | lib/rubygems/security.rb
Parent: | Object

A Gem::Security::Policy object encapsulates the settings for verifying signed gem files. This is the base class. You can either declare an instance of this or use one of the preset security policies below.

### Methods

new trusted_cert_path verify_gem

### Attributes

only_signed | [RW] |
only_trusted | [RW] |
verify_chain | [RW] |
verify_data | [RW] |
verify_root | [RW] |
verify_signer | [RW] |

### Public Class methods

new(policy = {}, opt = {})

Create a new Gem::Security::Policy object with the given mode and options.

trusted_cert_path(cert, opt = {})

Get the path to the file for this cert.

### Public Instance methods

verify_gem(signature, data, chain, time = Time.now)

Verify that the gem data with the given signature and signing chain matched this security policy at the specified time.

[Validate]