Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to get secret by key #34

Open
1 task
toksdotdev opened this issue Apr 18, 2023 · 8 comments
Open
1 task

Unable to get secret by key #34

toksdotdev opened this issue Apr 18, 2023 · 8 comments
Labels
bug Something isn't working

Comments

@toksdotdev
Copy link

toksdotdev commented Apr 18, 2023

Steps To Reproduce

At the moment, getting a secret is only possible by the id:

client.secrets().get(&SecretGetRequest { id: "some uuid".to_owned() }).await;

Expected Result

I should be able to retrieve secrets by the key I provided at creation. I feel the key should be honored as a means of retrieval since that’s what’ll be known to the caller and not necessarily the secret id.

Actual Result

At the moment, a work around is to:

  • Fetch all the secrets,
  • Filter by the key, and
  • Refetch the clear secret.

Not having to filter manually by the secrets will be a huge improvement.

Screenshots or Videos

No response

Additional Context

No response

Operating System

macOS

Operating System Version

No response

Build Version

0.2.1

Issue Tracking Info

  • I understand that work is tracked outside of Github. A PR will be linked to this issue should one be opened to address it, but Bitwarden doesn't use fields like "assigned", "milestone", or "project" to track progress.
@toksdotdev toksdotdev added the bug Something isn't working label Apr 18, 2023
@larivierec
Copy link

larivierec commented Apr 23, 2023

i second this, i just recently tried to use this and integrate with external-secrets and since we can only go by ID, it's a little harder to read if i were to deploy the helm-release + i'd need to know the exact secret id by listing them all first.

ideally, with a key, it would be easier

@Cubea01
Copy link

Cubea01 commented Jul 17, 2023

i second this, i just recently tried to use this and integrate with external-secrets and since we can only go by ID, it's a little harder to read if i were to deploy the helm-release + i'd need to know the exact secret id by listing them all first.

ideally, with a key, it would be easier

I'm trying to configure this as well. Do you still have your helm/flux yamls for your attempt I can use as a reference?

@larivierec
Copy link

larivierec commented Jul 17, 2023

i second this, i just recently tried to use this and integrate with external-secrets and since we can only go by ID, it's a little harder to read if i were to deploy the helm-release + i'd need to know the exact secret id by listing them all first.
ideally, with a key, it would be easier

I'm trying to configure this as well. Do you still have your helm/flux yamls for your attempt I can use as a reference?

yes, however, i've used bw cli to expose the restapi.
https://github.com/larivierec/home-cluster/tree/main/kubernetes/apps/kube-system/external-secrets

@CanRau
Copy link

CanRau commented Jul 28, 2023

Asked basically the same over at bitwarden/sm-action#20 I think this is a really necessary feature, at least for me to really adopt, the ids are too ambiguous, having to manually map them is unnecessary maintenance and having to list all, filter etc is also unneeded work.

@akash07k
Copy link

I too vote for this, accessing the secrets via ID is a very clunky way and not efficient at all

@CanRau
Copy link

CanRau commented Oct 2, 2023

Getting closer:

The team is currently evaluating the retrieval of secrets by name for consideration in a future release.
As an initial improvement, the process of retrieving the UUID has been streamlined and is now conveniently displayed below every secret.

From https://twitter.com/Bitwarden/status/1708894990766895280?t=8IAjXjcBB8uNHGOcSMvp9w&s=19

@akmalharith
Copy link

Recently moved my personal lab environment secrets to Bitwarden Secrets Manager, and suddenly noticed this limitation. I uploaded my wrapper script here https://gist.github.com/akmalharith/60c1b90e69dc622131d74c4311e6015c

But it will not be efficient if you have too many secrets.

@CanRau
Copy link

CanRau commented Feb 21, 2024

interesting approach, maybe it could accept multiple keys and make them available? not tooo proficient in bash 😅 just a thought, currently no time to play around

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants