Secret Key Storage
ℹ️ This page is just a rough outline of what I want to cover.
This page will talk about how "device keys" are stored on computers.
-
foks skm infoTfield values - fromproto/lib/common.goconst ( SecretKeyStorageType_PLAINTEXT SecretKeyStorageType = 0 SecretKeyStorageType_ENC_PASSPHRASE SecretKeyStorageType = 1 SecretKeyStorageType_ENC_MACOS_KEYCHAIN SecretKeyStorageType = 2 SecretKeyStorageType_ENC_NOISE_FILE SecretKeyStorageType = 3 SecretKeyStorageType_ENC_KEYCHAIN SecretKeyStorageType = 4 )- other fields will depend on
T
-
0 = Plain text
- is this used at all?
-
1 = Passphrase
foks passphrasecommand- difference between
setandchange?
- difference between
-
2 = macOS Keychain
- default on macOS
- has
f2dictionary withAccount,Service, andSecretBoxkeys - explain: item containing device key is flagged to allow
foksto access it without additional authorization- this allows FOKS to log into acct without asking for auth
- this also allows
foks key switchwithout asking for auth, which can seem insecure
- how to change this
- find item in keychain
- click "Access Control"
- remove
foksfrom list ⇒ require approval via GUI pop-up (clicking "always allow" will addfoksback to the list) - maybe turn on "Ask for Keychain password" ⇒ when the GUI pop-up appears, it will require you to enter the "keychain password" (usually same as macOS login password) before clicking "allow" or "always allow"
-
3 = Noise File
- default on linux if no GUI is present
- has
f3dictionary withFilename, andSecretBoxkeys - filename is in
$HOME/.config/foks/, contains random garbage - presumably used to decryptfoks-secretsfile in same directory
-
4 = Keychain
- linux/gnome keychain?
Generated
2025-09-22 03:40:19
74d4feb
2025-09-22 03:38:41 +0000