bakeryutil

package
v0.0.0-...-8ff1004 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2019 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBakeryService

func NewBakeryService(
	st *state.State,
	store bakerystorage.ExpirableStorage,
	locator bakery.PublicKeyLocator,
) (*bakery.Service, *bakery.KeyPair, error)

NewBakeryService returns a new bakery.Service and bakery.KeyPair. The bakery service is identifeid by the model corresponding to the State.

Types

type BakeryServicePublicKeyLocator

type BakeryServicePublicKeyLocator struct {
	Service *bakery.Service
}

BakeryServicePublicKeyLocator is an implementation of bakery.PublicKeyLocator that simply returns the embedded bakery service's public key.

func (BakeryServicePublicKeyLocator) PublicKeyForLocation

func (b BakeryServicePublicKeyLocator) PublicKeyForLocation(string) (*bakery.PublicKey, error)

PublicKeyForLocation implements bakery.PublicKeyLocator.

type ExpirableStorageBakeryService

type ExpirableStorageBakeryService struct {
	*bakery.Service
	Key     *bakery.KeyPair
	Store   bakerystorage.ExpirableStorage
	Locator bakery.PublicKeyLocator
}

ExpirableStorageBakeryService wraps bakery.Service, adding the ExpireStorageAfter method.

func (*ExpirableStorageBakeryService) ExpireStorageAfter

ExpireStorageAfter implements authentication.ExpirableStorageBakeryService.

Jump to

Keyboard shortcuts

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