bitwarden-keyring
bitwarden-keyring copied to clipboard
Feature Request: Add session passing to functions
Hey Joachim,
Thanks for the module, I have been using it to build out a utility to allow me to easily search and copy my bitwarden passwords to clipboard with fzf for search.
I ran into a small issue while using the module where I want to built a username/password cache using the bw() function, then using those results I call the get_password() func. The issue I am having is it is repeatedly calling for a new session on each function call (which asks me for password each time to unlock), and there doesn't seem to be a way to pass the session to the get_password, set_password, or del_password functions.
I am proposing the following, add a function input session=None, then add a small check inside the function. If session == None, it will grab the session from users password, else it will use the session passed to it.
I have created https://github.com/ewjoachim/bitwarden-keyring/pull/4 with the additions, tests, and minor version bump. Wanted to write my thoughts out here as well.
Let me know if you know a better way.
- Sam
Hey Sam!
I just realized I forgot to watch this repo. Sorry for the 2 year lag...
I'll review your PR :)