krl

package
v0.0.0-...-ff5f600 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 30, 2016 License: BSD-3-Clause Imports: 2 Imported by: 0

Documentation

Overview

Package krl implements a trivial, in-memory key revocation list. It is a placeholder for a real key revocation mechanism.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KRL

type KRL struct {
	// contains filtered or unexported fields
}

A KRL is a key revocation list. It maps the hashes of keys that have been revoked to revocation times.

func New

func New() *KRL

New() returns a pointer to a new, empty key recovation list.

func (*KRL) RevocationTime

func (krl *KRL) RevocationTime(key []byte) (whenRevoked time.Time)

RevocationTime() returns the revocation time for key[]. If key[] is not in the list, a time in the far future is returned.

func (*KRL) Revoke

func (krl *KRL) Revoke(key []byte, when time.Time)

Revoke() inserts an entry into *krl recording that key[] was revoked at time "when".

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL