I'm working on a widget that uses password data to access a server via
ssh. I want to save the passwords in the Keychain, and there's a
great tool called "security" that allows me to do this from the
command line. While I can add and retrieve a password, I can't find
any command to update or delete a password, and add-generic-password
returns an error if I ask it to add a different password with the same
identifiers.
The error is this:
security: SecKeychainAddGenericPassword <NULL>: The specified item
already exists in the keychain.
is there maybe an override?
Scanning the internet indicates that the full KeychainServices version
of this api supports the commands SecKeychainItemDelete and
SecKeychainItemModifyContent, which are what i'm looking for. Does
the command line version have support for these methods?
Many thanks,
Austin