NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
crates.io
crates.io, #1711 most downloaded on crates.io
All-in-One Rust Keyring
Latest stable
4.2.0
Last release 2 months ago
29 Aug 2026
Release timing varies
gaps range from 1 weeks to 4 months
Most releases are documented
notes for 43 of 60 stable releases
7 versions withdrawn
withdrawn after publishing
11 years old
83 releases · first in 2016
Drag across the ruler to compare, or tap a release to open it.
This release updates the dependencies of the CLI feature so that it builds appropriate credential stores on each platform. In particular, the db-keyst
This release updates the dependencies of the CLI feature so that it builds appropriate credential stores on each platform. In particular, the db-keystore requires 64-bit platforms and the Android keystore is included on Android.
Full Changelog: v4.1.6...v4.2.0
Your coding agent can read these notes before it upgrades. Set up the MCP server →
This release fixes #343 , a bug in concurrent initialization of the v1 default credential store (thanks @bbmediaco for reporting this). As part of thi
This release fixes #343, a bug in concurrent initialization of the v1 default credential store (thanks @bbmediaco for reporting this). As part of this fix, there's an added feature: you can now query the exact result of the default credential store creation, as well as force it to happen without creating an entry.
Full Changelog: v4.1.5...v4.1.6
Rust 1.97 introduced a new clippy lint that fired on the CLI example. This release fixes that problem.
Rust 1.97 introduced a new clippy lint that fired on the CLI example. This release fixes that problem.
This release also takes the recent bug fix to the Apple native credential store.
There are no functional changes in this release.
Full Changelog: v4.1.4...v4.1.5
This is an emergency release fixing the DOA bug #335 reported by @raph-ADF (thanks!).
This is an emergency release fixing the DOA bug #335 reported by @raph-ADF (thanks!).
Full Changelog: v4.1.3...v4.1.4
The only functional change is better error reporting on the first call to Entry::new if the default store fails to instantiate (thanks @eirnym ).
The only functional change is better error reporting on the first call to Entry::new if the default store fails to instantiate (thanks @eirnym).
NOTE: This release has been yanked because of #335. It has been replaced by v4.1.4.
AtomicBool to guard initialization and return error if occur on the first call. by @eirnym in #333Full Changelog: v4.1.2...v4.1.3
This release allows use of secret-service crate on all *nix OSes - thanks @eirnym !
This release allows use of secret-service crate on all *nix OSes - thanks @eirnym!
There are no functional changes.
Full Changelog: v4.1.1...v4.1.2
This release allows use of secret-service crate on all *nix OSes - thanks @eirnym!
There are no functional changes.
Full Changelog: https://github.com/open-source-cooperative/keyring-rs/compare/v4.1.1...v4.1.2
This release fixes the problems with documentation and public markers in v4.0. There are no functional changes.
This release fixes the problems with documentation and public markers in v4.0. There are no functional changes.
Full Changelog: v4.1.0...v4.1.1
This release moves the CLI binary out to an example so we can lose a lot of dependencies that aren't needed to use credential stores.
This release moves the CLI binary out to an example so we can lose a lot of dependencies that aren't needed to use credential stores.
In addition, it recreates the v1 (and v2/v3) functionality of providing an Entry object that any app can use (without special features or initialization) to manage text and binary secrets. This is provided by the v1 feature, which is the default. (This change fixes #317.)
The ability to use any credential store is still preserved in the cli module but the cli feature which exposes it is not in the default feature set.
Strictly speaking, these changes are probably SemVer-significant. But since there are few to no clients of the existing library functionality, we're calling this a patch release.
Full Changelog: v4.0.1...v4.1.0
This release has just one change: a bug fix in the sample code for iOS that was preventing use of the protected data store.
This release has just one change: a bug fix in the sample code for iOS that was preventing use of the protected data store.
Full Changelog: v4.0.0...v4.0.1
With keyring-core at 1.0, and all the included credential stores using the 1.0 release, it's finally time to release the "new" keyring which is just a
With keyring-core at 1.0, and all the included credential stores using the 1.0 release, it's finally time to release the "new" keyring which is just a sample app. See the wiki for all the details of the new architecture.
IMPORTANT: Apps that use keyring-compatible credential stores should not be relying on this release! They should instead be relying on the v1 release of keyring-core.
Full Changelog: v3.6.3...v4.0.0
With keyring-core at 1.0, and all the included credential stores using the 1.0 release, it's finally time to release the "new" keyring which is just a sample app. See the wiki for all the details of the new architecture.
IMPORTANT: Apps that use keyring-compatible credential stores should not be relying on this release! They should instead be relying on the v1 release of keyring-core.
Full Changelog: https://github.com/open-source-cooperative/keyring-rs/compare/v3.6.3...v4.0.0
This release adds unit tests to ensure API compliance of all registered stores.
This release adds unit tests to ensure API compliance of all registered stores.
Full Changelog: v4.0.0-rc.2...v4.0.0-rc.3
This release adds the sqlite credential store, based on Turso and contributed by @stevelr (thanks!). This is a cross-platform credential store, runnin
This release adds the sqlite credential store, based on Turso and contributed by @stevelr (thanks!). This is a cross-platform credential store, running on all platforms except (temporarily) Windows aarch64.
Full Changelog: https://github.com/open-source-cooperative/keyring-rs/compare/v4.0.0-beta.3...v4.0.0-rc.2
Nothing published for this version
All the underlying credential store modules have stabilized and the clients (CLI, python module, Tauri app) have stabilized, so we are ready for publi
All the underlying credential store modules have stabilized and the clients (CLI, python module, Tauri app) have stabilized, so we are ready for public beta.
(This is beta.3 because there was an earlier, yanked beta.1 and beta.2)
Full Changelog: https://github.com/open-source-cooperative/keyring-rs/compare/v4.0.0-alpha.5...v4.0.0-beta.3
Nothing published for this version
Nothing published for this version
This release adds two example programs. The first just creates or deletes three credentials with known values so you can see what they look like in th
This release adds two example programs. The first just creates or deletes three credentials with known values so you can see what they look like in the platform native credential GUI. The second does scanning for "leaks" of secret values from the keyring-core and credential stores, to make sure that client supplied or retrieved secrets are not being left in released memory.
Full Changelog: https://github.com/open-source-cooperative/keyring-rs/compare/v4.0.0-alpha.4...v4.0.0-alpha.5
This is a cleanup release. The Rust and Python components have been separated, which makes the keyring crate very clean and the Python module a clean
This is a cleanup release. The Rust and Python components have been separated, which makes the keyring crate very clean and the Python module a clean client of the keyring crate. It also provides the structure in which a Tauri app can be added.
Full Changelog: https://github.com/open-source-cooperative/keyring-rs/compare/v4.0.0-alpha.3...v4.0.0-alpha.4
This looks like a good candidate for beta. Please try it out.
This looks like a good candidate for beta. Please try it out.
Full Changelog: https://github.com/open-source-cooperative/keyring-rs/compare/v4.0.0-alpha.2...v4.0.0-alpha.3
This release converts this crate to being a sample-code/demonstrator/inventory-of-credential-stores crate. It provides a super-simple Rust CLI and a f
This release converts this crate to being a sample-code/demonstrator/inventory-of-credential-stores crate. It provides a super-simple Rust CLI and a far-more-useful Python module wrapper over the keyring-core functionality.
This first alpha has full functionality but the documentation is very light.
Full Changelog: https://github.com/open-source-cooperative/keyring-rs/compare/v3.6.3-republish...v4.0.0-alpha.2
Nothing published for this version
Nothing published for this version
Thanks to @unkcpz, this release fully documents all the platform-specific modules in each platform on docs.rs.
Thanks to @unkcpz, this release fully documents all the platform-specific modules in each platform on docs.rs.
The dev dependencies (used for testing) have been switched from using rand to using the lighter-weight module fastrand.
There are no functional code changes in this release, only test changes.
Two of the dependencies (openssl and whoami) were discovered to have vulnerabilities which were fixed in minor or patch releases. This crate has been…
Two of the dependencies (openssl and whoami) were discovered to have vulnerabilities which were fixed in minor or patch releases. This crate has been updated to insist that the minor/patch release number of these dependencies is high enough to ensure use of a patched version.
There is no reason to think that the vulnerabilities in these dependencies could have been exercised through this crate. In addition, builds of clients done after the dependencies were patched would have already picked up the non-vulnerable versions. So this change is simply to ensure that future builds cannot use the vulnerable versions.
There are no code changes in this release.
This release contains a new credential store for Linux: a combination of keyutils (for use by headless processes) and secret service (for persistence
This release contains a new credential store for Linux: a combination of keyutils (for use by headless processes) and secret service (for persistence of credentials beyond reboot). Thanks very much to @soywod for the contribution!
Add debug logging of internal operations (thanks to @soywod).
As pointed out in #214, it is possible to use both the secret-service and the keyutils credential stores at the same time, so this should be an allowe
As pointed out in #214, it is possible to use both the secret-service and the keyutils credential stores at the same time, so this should be an allowed combination of specified features. This release allows that combination, selecting the secret-service as the default keystore but also loading the keyutils keystore.
Add support for credential-store attributes other than those used by this crate. This allows the creation of credentials that are more compatible with
user@service (or user@service:target if a target was specified).The v3.2.0 release, which fixed #204, had an unfortunate side effect: it broke compatibility with credentials that were originally written by a v1.x r
The v3.2.0 release, which fixed #204, had an unfortunate side effect: it broke compatibility with credentials that were originally written by a v1.x release (see #207). This bug-fix release restores that compatibility.
With this change, the CLI changes in v3.2.0 have been reverted, because they are no longer necessary.
As reported in #201 and now fixed in #204, the secret-service credential store implementation could not disambiguate credentials that were created wit
As reported in #201 and now fixed in #204, the secret-service credential store implementation could not disambiguate credentials that were created with different targets unless the collections containing those targets had already been unlocked.
The fix for this issue introduces a compatibility break: secret-service credentials created by the keyring v1 implementation, which were readable using platform-independent code in keyring v2, are no longer readable without using platform-specific code in v3. The necessary platform-specific code is very simple, and it has been added to the CLI (both for documentation purposes and to allow the CLI to access v1 credentials). The comments in issue #204 explain why the decision was made to add this secret-service-specific compatibility break; these include the fact that keyring v2 was released 18 months ago so only those users who haven't changed their password in a very long time would still have a v1 credential in their secret-service store.
The README has been updated to address this compatibility break and to provide recommendations for keyring clients who want to update their code to make sure users with old credentials are not impacted.
As reported in #201, the CLI had a couple of problems:
As reported in #201, the CLI had a couple of problems:
Ambiguous errors provided no information about the underlying platform credentials.The first issue was just a bug, now fixed.
The second issue stemmed from the fact that platform-independent code couldn't get at the details of the underlying platform-specific credentials. To fix this, the CredentialAPI had to be extended to provide access to the underlying platform credential's implementation of the std::fmt::Debug trait, and each of the keying credential stores extended to implement the new API.
To make this API extension backward-compatible, a default implementation was provided that did what the former code did: it revealed nothing. But that allows this release to be a SerVer-compatible dot release, rather than a major release.
As reported in #132, using the secret-service asynchronously via the keyring wrapper can lead to deadlocks. The docs have been updated to make this cl
As reported in #132, using the secret-service asynchronously via the keyring wrapper can lead to deadlocks. The docs have been updated to make this clear, and a recommendation has been added to use the sync-secret-service feature so as to avoid any issues related to async runtimes, even if the calling app may already be asynchronous.
While this fix was being made, it was discovered that new clippy lints in Rust 1.80 had been added. These lints revealed some dead code related to windows testing, and some documentation that was "legal" per the markdown spec but slightly ambiguous in intent. Both of these other issues were also fixed.
There are no code changes in this release relative to v3.0.4.
As reported in #197, there's no way for a client to access an instance of the default credential builder with platform-independent code. This releases
As reported in #197, there's no way for a client to access an instance of the default credential builder with platform-independent code. This releases fixes that oversight, and provides an example as part of the documentation of the credential module.
Earlier releases didn't correctly use the keyring when the linux-native feature was specified. This release does.
Earlier releases didn't correctly use the keyring when the linux-native feature was specified. This release does.
Thanks to @Brooooooklyn for finding this issue!
This patch release adds in the missing iOS APIs reported in #187 and the missing CHANGELOG entries reported in #189. It also updates the README to be
This patch release adds in the missing iOS APIs reported in #187 and the missing CHANGELOG entries reported in #189. It also updates the README to be a lot clearer about how the new feature system interacts with platforms.
The major functional change between v2 and v3 is the addition of synchronous support for the Secret Service via the dbus-secret-service crate. This me
The major functional change between v2 and v3 is the addition of synchronous support for the Secret Service via the dbus-secret-service crate. This means that keyring users of the Secret Service no longer need to link with an async runtime.
The main API change between v2 and v3 is the addition of support for non-string (i.e., binary) "password" data. To accommodate this, two changes have been made:
There are two new methods on Entry objects: set_secret and get_secret. These are the analogs of set_password and get_password, but instead of taking or returning strings they take or return binary data (byte arrays/vectors).
The v2 method delete_password has been renamed delete_credential, both to clarify what's actually being deleted and to emphasize that it doesn't matter whether it's holding a "password" or a "secret".
Another API change between v2 and v3 is that the notion of a default feature set has gone away: you must now specify explicitly which crate-supported keystores you want included (other than the mock keystore, which is always present). So all keyring client developers will need to update their Cargo.toml file to use the new features correctly.
All v2 data is fully forward-compatible with v3 data; there have been no changes at all in that respect.
The MSRV has been moved to 1.75, and all direct dependencies are at their latest stable versions.
(The original 3.0.0 release had a compile-time issue related to Error traits in some environments; v3.0.1 fixes that.)
Nothing published for this version
This is likely the final RC for the v3 release. Please try it out and provide feedback. From the README:
This is likely the final RC for the v3 release. Please try it out and provide feedback. From the README:
The major functional change between v2 and v3 is the addition of synchronous support for the Secret Service via the dbus-secret-service crate. This means that keyring users of the Secret Service no longer need to link with an async runtime.
The main API change between v2 and v3 is the addition of support for non-string (i.e., binary) "password" data. To accommodate this, two changes have been made:
There are two new methods on Entry objects: set_secret and get_secret. These are the analogs of set_password and get_password, but instead of taking or returning strings they take or return binary data (byte arrays/vectors).
The v2 method delete_password has been renamed delete_credential, both to clarify what's actually being deleted and to emphasize that it doesn't matter whether it's holding a "password" or a "secret".
Another API change between v2 and v3 is that the notion of a default feature set has gone away: you must now specify explicitly which crate-supported keystores you want included (other than the mock keystore, which is always present). So all keyring client developers will need to update their Cargo.toml file to use the new features correctly.
All v2 data is fully forward-compatible with v3 data; there have been no changes at all in that respect.
The MSRV has been moved to 1.75, and all direct dependencies are at their latest stable versions.
The major functional change between v2 and v3 is the addition of synchronous support for the Secret Service via the dbus-secret-service crate. This me
From the README:
The major functional change between v2 and v3 is the addition of synchronous support for the Secret Service via the dbus-secret-service crate. This means that keyring users of the Secret Service no longer need to link with an async runtime.
The only API change between v2 and v3 is that the default feature set has gone away: you must now specify explicitly which crate-supported keystores you want included. So keyring clients will need to update their Cargo.toml file, but not their code.
All v2 data is fully forward-compatible with v3 data; there have been no changes at all in that respect.
The MSRV has been moved to 1.75, and all direct dependencies are at their latest stable versions.
Rust 1.78 introduced a new clippy check and better guards on Windows when making slices from raw bytes. These changes required one small change in the
Rust 1.78 introduced a new clippy check and better guards on Windows when making slices from raw bytes. These changes required one small change in the platform-independent code and two small changes in the Windows-specific code.
Nothing published for this version
This release includes a contribution by @russellbanks which changes windows to use the windows-sys crate instead of winapi, as suggested by @thewh1tea
This release includes a contribution by @russellbanks which changes windows to use the windows-sys crate instead of winapi, as suggested by @thewh1teagle.
Specifies a minimum stable rust version of 1.68, which is the one that was current when this major version was released. Only the library is warranted to build on 1.68. In particular, none of the tests or examples will work; they require 1.70 for dev dependencies.
Thanks to @klemensn, this release should build and run on OpenBSD.
Thanks to @klemensn, this release should build and run on OpenBSD.
PLEASE NOTE: While this behavior is a breaking change on Mac, Windows, and FreeBSD, the behavior on those platforms before was unintended and undefine…
In response to #153 and #148, suppressing the default feature set now suppresses the platform keystore dependencies on all platforms and uses the mock keystore as the default.
PLEASE NOTE: While this behavior is a breaking change on Mac, Windows, and FreeBSD, the behavior on those platforms before was unintended and undefined (suppressing default features did nothing), so this is considered a bug fix rather than a semver-breaking change that requires a major version bump.
This minor release adds support for asking credential stores at runtime about the lifetime of their stored credentials. See the documentation of `Cred
This minor release adds support for asking credential stores at runtime about the lifetime of their stored credentials. See the documentation of CredentialPersistence for details.
This feature was suggested by @benwr in #147.
This release includes the updates to the keyring documentation from @landhb (see #137 and #138).
This release includes the updates to the keyring documentation from @landhb (see #137 and #138).
There are no code changes in this patch release.
There are no code changes in this patch release.
This release integrates two improvements from @phlip9 - thanks!
This release integrates two improvements from @phlip9 - thanks!
This fixes user to be username in the documentation of secret-service attributes. The same sort of typo was in the Mac, iOS, and xplat docs, but it wa
This fixes user to be username in the documentation of secret-service attributes. The same sort of typo was in the Mac, iOS, and xplat docs, but it wasn't as serious there because it didn't affect attribute names used by the underlying implementations.
This is a documentation-only release: no code changes.
The README in v2.0.0 had example code that wouldn't compile. It also had a typo in the doctests that caused the README example to be skipped. This rel
The README in v2.0.0 had example code that wouldn't compile. It also had a typo in the doctests that caused the README example to be skipped. This release fixes that documentation problem. There are no functional code changes since v2.0.0.
Keyring v2 (available on crates.io) is a significant upgrade from v1 while maintaining full backward compatibility on existing platforms. Here's a sum
Keyring v2 (available on crates.io) is a significant upgrade from v1 while maintaining full backward compatibility on existing platforms. Here's a summary of the changes from v1:
mock credential store for easy cross-platform client testing.The README contains instructions for upgrading v1 client code to work with v2. Enjoy!
This release, which is fully compatible with v1 and fully documented, will become the v2 release in a few days unless issues are reported. Please try
This release, which is fully compatible with v1 and fully documented, will become the v2 release in a few days unless issues are reported. Please try it out ASAP.
Here's how the secret-service credential store works now:
Here's how the secret-service credential store works now:
target attribute when creating new items.set-password works by doing get-password and then, if it finds a unique item, setting the password on that item. If there is no matching item, it creates one in a collection labeled by the target (creating that collection if necessary). Note that the default target is the only collection found by alias; all other collections are found by label.This seems to provide the best of all worlds: v1 and v2 are now completely compatible, and we can create collections if the client uses a non-default target. (Note that v1 never created collections, and it always used the target name as an alias, so in effect it was completely restricted to using the default collection.)
If (due to 3rd party items) an ambiguity is found, there are platform-specific entries for getting all the passwords or deleting all the matching items.
This is a complete release of keyring v2 based on the latest secret-service v3. It's marked as a release candidate both to allow external user testing
This is a complete release of keyring v2 based on the latest secret-service v3. It's marked as a release candidate both to allow external user testing and to prevent unwitting upgrades (because good docs that explain how to move code from v1 to v2 have not yet been written). The actual v2 release is expected in about a week.
See the release notes for the alpha and beta versions of v2 for more info about what's in v2 relative to v1.
This release introduces one option in the secret-service credential store builder: a boolean search_all which means to search for credentials in all c
This release introduces one option in the secret-service credential store builder: a boolean search_all which means to search for credentials in all collections (i.e., use service-level search). When you turn on search_all in the builder, it causes all the credentials to include a target attribute (as well as using the target for the collection name in which the credential is created), and it always searches for credentials at service level including the target attribute. This means:
search_all is off (the default), then we are completely compatible with v1 credentials and we have to do the explicit check for a locked credential on get and delete.search_all is on, then we will never see any v1 or search_all=off credentials at all (because none have a target attribute).Note that v1 and search_all=off will find credentials built with search_all=on (because they ignore the target attribute). In addition, because of the way the secret service works, doing a v1 or search_all=off set-password call will remove the target attribute from an existing credential with the same service and user.
Thus, to write a v2 client that always uses service-level search but is compatible with non-service-level search clients, the service-level search client should always delete any existing non-target entry with the same user and service before setting a password. This is very easy to do because you can use two credential stores side-by-side in the same v2 client.
In order to publish this release to crates.io, we have reverted to using v2 of the secret-service, because v3 is not yet released. If v3 is released before we are out of beta, we will integrate it into our release. Otherwise, we should be able to do a single dot release that incorporates it.
Nothing published for this version
Nothing published for this version
Nothing published for this version
The maximum allowed password length was not being checked correctly on Windows, because the check did not take into account the UTF-16 encoding that w
The maximum allowed password length was not being checked correctly on Windows, because the check did not take into account the UTF-16 encoding that would be applied to the password before it was stored (#85). This release fixes that one bug.
As reported in #86, the MacOS platform treats an empty user-name (or service-name) string as a wildcard when doing a password retrieval. Other platfor
As reported in #86, the MacOS platform treats an empty user-name (or service-name) string as a wildcard when doing a password retrieval. Other platforms do not act this way. As it's a tenet of this module to have consistent behavior on all platforms, a bug fix was needed. The resolution (as documented in #86 and #87 and in the docs) is to disallow the use of empty strings for target, service or user names in credentials, causing all attempted uses of such credentials to fail with a "credential not found" error. This resolution does not break the API or any existing API documentation (since the behavior on empty strings was not documented), but as it's a functionality change it merits a minor version bump.
Existing clients of the API who were relying on platform-specific behavior around the user of empty credential strings can still use this module, but they will have to explicitly specify their platform credentials using the new_with_credential call rather than using new or new_with_target as they may have been.
One column per quarter.