Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ api:

- **Authentication**: OIDC device flow - no password ever stored locally
- **File data + metadata**: end to end encrypted with [AGE](https://github.com/FiloSottile/age) post-quantum hybrid keys
- **Private key caching** (Linux only): the decrypted AGE identity in the kernel session keyring (never written to disk). It is scoped to the current terminal session, isolated from other users and sessions, and automatically wiped after a configurable TTL (default: 60sec).
- **Private key caching** (Linux only): the decrypted AGE identity is stored in the kernel session keyring and is never written to disk. It is scoped to the current terminal session, isolated from other users and sessions, and uses a sliding TTL (default: 60 seconds). Each access refreshes the expiration timer.
- **Transport**: TLS enforced by default

---
Expand Down
11 changes: 6 additions & 5 deletions cmd/transfer.go
Original file line number Diff line number Diff line change
Expand Up @@ -358,18 +358,19 @@ func resolveUserIdentity(cfg *config.Config, userKey *api.UserKey) (*age.HybridI
if err != nil {
return nil, fmt.Errorf("wrong key passphrase")
}
if cfg.Keyring.Enabled {
if err := keyring.Store(identityStr, cfg.Keyring.TTL); err != nil {
fmt.Fprintf(os.Stderr, "warning: keyring store: %v\n", err)
}
}
}

identity, err := crypto.ParseIdentity(identityStr)
if err != nil {
return nil, fmt.Errorf("parsing AGE identity: %w", err)
}

if cfg.Keyring.Enabled {
if err := keyring.Store(identityStr, cfg.Keyring.TTL); err != nil {
fmt.Fprintf(os.Stderr, "warning: keyring store: %v\n", err)
}
}
Comment thread
HanXHX marked this conversation as resolved.

return identity, nil
}

Expand Down