node-keytar icon indicating copy to clipboard operation
node-keytar copied to clipboard

Secret schema on Linux is inconsistent with python, go keyring libraries

Open ccope opened this issue 6 years ago • 0 comments

Prerequisites

Description

Unfortunately it doesn't seem like there are predefined schemas for secrets in the freedesktop secretservice backend, other than for network servers. Keytar chose to use account and keyring chose username. The keychain library for go, keybase/go-keychain, also chose username. Setting both fields would allow the libraries to interoperate.

https://github.com/atom/node-keytar/blob/master/src/keytar_posix.cc#L14-L17 https://github.com/jaraco/keyring/blob/master/keyring/backends/SecretService.py#L84-L87

Steps to Reproduce

  1. Add a secret with either library.
  2. Try to retrieve the secret with the other library.

Expected behavior: The secret should be returned

Actual behavior: It fails

Reproduces how often: 100%

Versions

5.0.0-beta.2 (but all are broken)

Additional Information

ccope avatar Sep 21 '19 00:09 ccope