MCPcopy Create free account
hub / github.com/daodst/chat / ClaimKeys

Method ClaimKeys

keyserver/storage/interface.go:64–64  ·  view source on GitHub ↗

ClaimKeys based on the 3-uple of user_id, device_id and algorithm name. Returns the keys claimed. Returns no error if a key cannot be claimed or if none exist for this (user, device, algorithm), instead it is omitted from the returned slice.

(ctx context.Context, userToDeviceToAlgorithm map[string]map[string]string)

Source from the content-addressed store, hash-verified

62 // ClaimKeys based on the 3-uple of user_id, device_id and algorithm name. Returns the keys claimed. Returns no error if a key
63 // cannot be claimed or if none exist for this (user, device, algorithm), instead it is omitted from the returned slice.
64 ClaimKeys(ctx context.Context, userToDeviceToAlgorithm map[string]map[string]string) ([]api.OneTimeKeys, error)
65
66 // StoreKeyChange stores key change metadata and returns the device change ID which represents the position in the /sync stream for this device change.
67 // `userID` is the the user who has changed their keys in some way.

Callers 2

PerformClaimKeysMethod · 0.65
claimRemoteKeysMethod · 0.65

Calls

no outgoing calls

Tested by

no test coverage detected