Add support for multiple password managers#2
Open
pinpox wants to merge 17 commits into
Open
Conversation
Author
|
After thinking about it again, using the env var was not a very nice design. I refactored the package again to just build two binaries, one for each manager. The readme still has to be adapted. |
Owner
|
How about checking all password managers that are installed and have one binary? |
Author
How would I check what managers are installed and what should happen if I have multiple? I'm not sure making it explicit is a bad thing here. |
Owner
|
I'm assuming you're talking to Bitwarden through the CLI, if so then I would check If there are multiple, I would try all of them for decryption |
4ce348c to
0521062
Compare
0521062 to
d3cfd88
Compare
Enzime
reviewed
Apr 29, 2025
Co-authored-by: Michael Hoang <Enzime@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR refactors the code to allow for multiple password managers to be used as backend. Additionally, it adds support for
bitwarden.The password manager to be used as backend is specified by setting the environment variableAGE_PW_BACKENDto either1passwordorbitwarden.Adding more backends should now also be easier, as only one interface has to be implemented for it to be supported.
I would recommend renaming the plugin to something along the lines of
age-plugin-pwmanageror similar generic name that is not specific to 1password.I couldn't test the 1password functionality since you need a paid account, but havn't touched the methods much. If you want a bitwarden account on my instance for testing, let me know.