Skip to main content

require_encryption_key

Function require_encryption_key 

Source
pub fn require_encryption_key(
    user_id: &str,
) -> Result<[u8; 32], RequireKeyError>
Expand description

E2EE precondition. Returns the user’s AES-256 key, PendingExchange when the device is waiting on a paired peer to share the master key, or Missing when no credential exists at all. Callers map:

  • MissingENCRYPTION_REQUIRED exit code, prompt cinch auth login
  • PendingExchangeENCRYPTION_PENDING exit code, auto-retry key exchange