Documentation ¶
Overview ¶
Package composite provides a composite signer.
Index ¶
Constants ¶
View Source
const SignerName = "composite"
SignerName is the name used to identify the composite signer.
Variables ¶
This section is empty.
Functions ¶
func NewFactory ¶
func NewFactory(config interface{}, roles ...signature.SignerRole) (signature.SignerFactory, error)
NewFactory creates a new factory with the specified roles, with the specified pre-created SignerFactory(s).
Types ¶
type FactoryConfig ¶
type FactoryConfig map[signature.SignerRole]signature.SignerFactory
FactoryConfig is the composite factory configuration.
type SignerFactory ¶
type SignerFactory struct {
// contains filtered or unexported fields
}
SignerFactory is a SignerFactory that is a composite of multiple other SignerFactory(s).
func (*SignerFactory) EnsureRole ¶
func (sf *SignerFactory) EnsureRole(role signature.SignerRole) error
EnsureRole ensures that the SignerFactory is configured for the given role.
func (*SignerFactory) Generate ¶
func (sf *SignerFactory) Generate(role signature.SignerRole, rng io.Reader) (signature.Signer, error)
Generate will generate and persist an new private key corresponding to the provided role, and return a Signer ready for use.
func (*SignerFactory) Load ¶
func (sf *SignerFactory) Load(role signature.SignerRole) (signature.Signer, error)
Load will load the private key corresponding to the role, and return a Signer ready for use.
Click to show internal directories.
Click to hide internal directories.