Documentation ¶
Overview ¶
Package factotum encapsulates crypto operations on user's public/private keys.
Index ¶
- Variables
- func KeyHash(p upspin.PublicKey) []byte
- func NewFromDir(dir string) (upspin.Factotum, error)
- func NewFromKeys(public, private, archived []byte) (upspin.Factotum, error)
- func ParsePublicKey(public upspin.PublicKey) (*ecdsa.PublicKey, error)
- func Verify(hash []byte, sig upspin.Signature, key upspin.PublicKey) error
Constants ¶
This section is empty.
Variables ¶
var AllUsersKeyHash = KeyHash(upspin.AllUsersKey)
AllUsersKeyHash is the hash of upspin.AllUsersKey.
Functions ¶
func NewFromDir ¶
NewFromDir returns a new Factotum providing all needed private key operations, loading keys from a directory containing *.upspinkey files. Our desired end state is that Factotum is implemented on each platform by the best local means of protecting private keys. Please do not break the abstraction by hand coding direct generation or use of private keys.
func NewFromKeys ¶
NewFromKeys returns a new Factotum by providing it with the raw representation of an Upspin user's public, private and optionally, archived keys.
func ParsePublicKey ¶
ParsePublicKey takes an Upspin representation of a public key and converts it into an ECDSA public key. The Upspin string representation uses \n as newline no matter what native OS it runs on.
Types ¶
This section is empty.