Documentation
¶
Overview ¶
Package opstore keeps SSH keys as items in 1Password, through the op CLI.
The private key is generated inside 1Password and never written to disk: authama only ever reads an item's public key back. Items are found by title (the key name) and then addressed by ID, so an edit or an archive cannot land on a different item that happens to share a title.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrNotFound = errors.New("not found in 1Password")
ErrNotFound means no item in the vault has the title.
Functions ¶
func AgentConfigPath ¶
func AgentConfigPath() string
AgentConfigPath is where the 1Password SSH agent reads agent.toml: $XDG_CONFIG_HOME/1Password/ssh/agent.toml when XDG_CONFIG_HOME is set, else ~/.config/1Password/ssh/agent.toml (on Windows, %LOCALAPPDATA%/1Password/config/ssh/agent.toml).
func AgentServesVault ¶
AgentServesVault reports whether the 1Password SSH agent offers every key in vault, and if not, what to change. Every key in the vault matters, not just today's: a rotation's .staged item has to be served to be verified.
With no agent.toml the agent serves only the default vaults. Once the file exists it serves only what the file lists - even an empty file overrides the default - so the vault then needs its own whole-vault entry.
Types ¶
type Client ¶
Client runs the op CLI. Bin is "op" unless a test points it elsewhere.
func (*Client) Archive ¶
Archive moves the item with id to 1Password's Archive, where it can still be restored. authama never deletes an item outright.
func (*Client) Create ¶
Create generates a new Ed25519 SSH key item titled title in vault and returns it. The private key stays in 1Password.