You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SMB: Backend for borrowing Finder's saved password (#2, backend half)
Lets Cmdr read the SMB password macOS/Finder already saved in the login keychain, so a yellow os-mount volume can go green (direct smb2) without the user retyping it. Backend only; the FE affordance lands next.
- `secrets/system_keychain_smb.rs` (macOS): silent attribute probe (`account_for_any`, no consent) and consent-gated data read (`read_password`) of Finder's `kSecClassInternetPassword` smb item, via `SecItemCopyMatching`. Tries `server_query_candidates` (the name forms the item might be keyed under) and skips the "No user account" guest sentinel. Spike confirmed the read works on a real NAS.
- `smb_upgrade::system_keychain_aliases`: gathers the mDNS-service-name / hostname forms for a server from the discovery state (Finder keys by the service name; we mount by IP).
- Commands: `system_has_saved_smb_password` (prompt-free probe, drives whether to offer the affordance) and `upgrade_to_smb_volume_using_saved_password` (consent read → direct smb2 → copy the password into Cmdr's own store so future reconnects are silent → fall back to `CredentialsNeeded` if absent/denied). User-initiated only, never at startup.
- Adds `security-framework-sys` (already in the lockfile) for the FFI constants + `SecItemCopyMatching`. macOS-only; non-macOS arms + stubs return false / unsupported.
- Pure helpers unit-tested (candidate ordering, account sentinel, alias gathering).
0 commit comments