https://github.com/tmc/keyring
keyring provides a cross-platform keychain/keyring interface
https://github.com/tmc/keyring
Last synced: about 1 year ago
JSON representation
keyring provides a cross-platform keychain/keyring interface
- Host: GitHub
- URL: https://github.com/tmc/keyring
- Owner: tmc
- License: isc
- Created: 2013-09-05T17:08:59.000Z (almost 13 years ago)
- Default Branch: master
- Last Pushed: 2023-04-18T03:23:35.000Z (about 3 years ago)
- Last Synced: 2025-03-31T20:44:25.656Z (about 1 year ago)
- Language: Go
- Homepage: http://godoc.org/github.com/tmc/keyring
- Size: 36.1 KB
- Stars: 122
- Watchers: 8
- Forks: 25
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# keyring provides cross-platform keychain access
http://godoc.org/github.com/tmc/keyring
Keyring provides a common interface to keyring/keychain tools.
License: ISC
Currently implemented:
- OSX
- SecretService
- gnome-keychain (via "gnome_keyring" build flag)
- Windows
Contributions welcome!
Usage example:
```go
err := keyring.Set("libraryFoo", "jack", "sacrifice")
password, err := keyring.Get("libraryFoo", "jack")
fmt.Println(password) //Output: sacrifice
```
## Linux
Linux requirements:
### SecretService provider
- dbus
### gnome-keychain provider
- gnome-keychain headers
- Ubuntu/Debian: `libsecret-dev`
- Fedora: `libsecret-devel`
- Archlinux: `libsecret`
Tests on Linux:
```sh
$ go test github.com/tmc/keyring
$ # for gnome-keyring provider
$ go test -tags gnome_keyring github.com/tmc/keyring
```