Documentation ¶
Index ¶
- func NewKeyPseudonymResolver(m libkb.MetaContext) saltpack.SymmetricKeyResolver
- func NewRecipientKeyfinderEngineHook(getKBFSKeyfinderForTesting bool) ...
- func NewSaltpackKBFSKeyfinderEngineForTesting(arg libkb.SaltpackRecipientKeyfinderArg) libkb.SaltpackRecipientKeyfinderEngineInterface
- func NewSaltpackRecipientKeyfinderEngineAsInterface(arg libkb.SaltpackRecipientKeyfinderArg) libkb.SaltpackRecipientKeyfinderEngineInterface
- func NewSaltpackRecipientKeyfinderEngineAsInterfaceForTesting(arg libkb.SaltpackRecipientKeyfinderArg) libkb.SaltpackRecipientKeyfinderEngineInterface
- type KeyPseudonymResolver
- type SaltpackKBFSKeyfinderEngineForTesting
- func (e *SaltpackKBFSKeyfinderEngineForTesting) GetPublicKIDs() []keybase1.KID
- func (e *SaltpackKBFSKeyfinderEngineForTesting) GetSymmetricKeys() []libkb.SaltpackReceiverSymmetricKey
- func (e *SaltpackKBFSKeyfinderEngineForTesting) Name() string
- func (e *SaltpackKBFSKeyfinderEngineForTesting) Prereqs() engine.Prereqs
- func (e *SaltpackKBFSKeyfinderEngineForTesting) RequiredUIs() []libkb.UIKind
- func (e *SaltpackKBFSKeyfinderEngineForTesting) Run(m libkb.MetaContext) (err error)
- func (e *SaltpackKBFSKeyfinderEngineForTesting) SubConsumers() []libkb.UIConsumer
- type SaltpackRecipientKeyfinderEngine
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewKeyPseudonymResolver ¶
func NewKeyPseudonymResolver(m libkb.MetaContext) saltpack.SymmetricKeyResolver
func NewRecipientKeyfinderEngineHook ¶
func NewRecipientKeyfinderEngineHook(getKBFSKeyfinderForTesting bool) func(arg libkb.SaltpackRecipientKeyfinderArg) libkb.SaltpackRecipientKeyfinderEngineInterface
func NewSaltpackKBFSKeyfinderEngineForTesting ¶
func NewSaltpackKBFSKeyfinderEngineForTesting(arg libkb.SaltpackRecipientKeyfinderArg) libkb.SaltpackRecipientKeyfinderEngineInterface
NewSaltpackKBFSKeyfinderEngineForTesting creates a SaltpackKBFSKeyfinderEngineForTesting engine.
func NewSaltpackRecipientKeyfinderEngineAsInterface ¶
func NewSaltpackRecipientKeyfinderEngineAsInterface(arg libkb.SaltpackRecipientKeyfinderArg) libkb.SaltpackRecipientKeyfinderEngineInterface
SaltpackRecipientKeyfinderEngine creates a SaltpackRecipientKeyfinderEngine engine.
func NewSaltpackRecipientKeyfinderEngineAsInterfaceForTesting ¶
func NewSaltpackRecipientKeyfinderEngineAsInterfaceForTesting(arg libkb.SaltpackRecipientKeyfinderArg) libkb.SaltpackRecipientKeyfinderEngineInterface
SaltpackRecipientKeyfinderEngineForTesting creates a SaltpackRecipientKeyfinderEngine engine. CORE-8423 remove this after most clients update
Types ¶
type KeyPseudonymResolver ¶
type KeyPseudonymResolver struct {
// contains filtered or unexported fields
}
KeyPseudonymResolver resolves new (team based) Key Pseudonyms, but falls back to old Kbfs Pseudonyms when it cannot find any match. A mock implementation (which does not communicate with the sever and avoids circular dependencies) is available in the saltpackkeysmocks package.
func (*KeyPseudonymResolver) ResolveKeys ¶
func (r *KeyPseudonymResolver) ResolveKeys(identifiers [][]byte) ([]*saltpack.SymmetricKey, error)
type SaltpackKBFSKeyfinderEngineForTesting ¶
type SaltpackKBFSKeyfinderEngineForTesting struct { SaltpackSymmetricKeys []libkb.SaltpackReceiverSymmetricKey // contains filtered or unexported fields }
SaltpackKBFSKeyfinderEngineForTesting is an engine to find kbfs keys to encrypt saltpack messages. These keys have been substituted with implicit team keys in the current version of the keybase app, so this engine is behind a devel only flag and is used only in tests to ensure backwards compatibility.
This engine silently ignores teams and other kinds of keys requested, so be careful! This code used to be part of the SaltpackEncrypt engine in engine/saltpack_encrypt.go.
func (*SaltpackKBFSKeyfinderEngineForTesting) GetPublicKIDs ¶
func (e *SaltpackKBFSKeyfinderEngineForTesting) GetPublicKIDs() []keybase1.KID
func (*SaltpackKBFSKeyfinderEngineForTesting) GetSymmetricKeys ¶
func (e *SaltpackKBFSKeyfinderEngineForTesting) GetSymmetricKeys() []libkb.SaltpackReceiverSymmetricKey
func (*SaltpackKBFSKeyfinderEngineForTesting) Name ¶
func (e *SaltpackKBFSKeyfinderEngineForTesting) Name() string
Name is the unique engine name.
func (*SaltpackKBFSKeyfinderEngineForTesting) Prereqs ¶
func (e *SaltpackKBFSKeyfinderEngineForTesting) Prereqs() engine.Prereqs
Prereqs returns the engine prereqs.
func (*SaltpackKBFSKeyfinderEngineForTesting) RequiredUIs ¶
func (e *SaltpackKBFSKeyfinderEngineForTesting) RequiredUIs() []libkb.UIKind
RequiredUIs returns the required UIs.
func (*SaltpackKBFSKeyfinderEngineForTesting) Run ¶
func (e *SaltpackKBFSKeyfinderEngineForTesting) Run(m libkb.MetaContext) (err error)
func (*SaltpackKBFSKeyfinderEngineForTesting) SubConsumers ¶
func (e *SaltpackKBFSKeyfinderEngineForTesting) SubConsumers() []libkb.UIConsumer
SubConsumers returns the other UI consumers for this engine.
type SaltpackRecipientKeyfinderEngine ¶
type SaltpackRecipientKeyfinderEngine struct { engine.SaltpackUserKeyfinder SymmetricEntityKeyMap map[keybase1.TeamID](keybase1.TeamApplicationKey) SaltpackSymmetricKeys []libkb.SaltpackReceiverSymmetricKey SkipTlfKeysForTesting bool // CORE-8423 remove this after most clients update }
SaltpackRecipientKeyfinderEngine is an engine to find Per User/Per Team Keys. Users can also be loaded by assertions, possibly tracking them if necessary.
SaltpackRecipientKeyfinderEngine extends the functionality of engine.SaltpackUserKeyfinder (which can only find user keys but not team keys). This is a separate object (and also not part of the engine package) to avoid circular dependencies (as teams depends on engine).
func (*SaltpackRecipientKeyfinderEngine) GetSymmetricKeys ¶
func (e *SaltpackRecipientKeyfinderEngine) GetSymmetricKeys() []libkb.SaltpackReceiverSymmetricKey
func (*SaltpackRecipientKeyfinderEngine) Name ¶
func (e *SaltpackRecipientKeyfinderEngine) Name() string
Name is the unique engine name.
func (*SaltpackRecipientKeyfinderEngine) Run ¶
func (e *SaltpackRecipientKeyfinderEngine) Run(m libkb.MetaContext) (err error)