doy / rbw

unofficial bitwarden cli
https://git.tozt.net/rbw
Other
663 stars 89 forks source link

Issues with pinentry and running rbw from distrobox #106

Open vinylen opened 1 year ago

vinylen commented 1 year ago

Hi,

I'm using Fedora Sericea 38, which uses Distrobox to export CLI tools since the OS is immutable.

I've created an arch distrobox, install rbw via Yay and exported the rbw binary to my host machine. So rbw is installed in an arch podman container, exported to my host OS to ~/.local/bin.

On my host OS i can access and use rbw just fine, however, i cannot login since i get the following error regarding pinentry:

rbw login: failed to read password from pinentry: failed to parse pinentry output ("S ERROR curses.open_tty_for_read 83918849

This is my config:

{
  "email": "redacted",
  "base_url": "https://bitwarden.example.com",
  "identity_url": null,
  "lock_timeout": 3600,
  "pinentry": "pinentry-curses",
  "client_cert_path": null
}

I've also tried setting "pinentry": "pinentry", but i get the same error.

Please let me know if you need anything else.

Cheers

vinylen commented 1 year ago

I can confirm that Distrobox users can get around this by installing rbw via cargo install rbw

doy commented 1 year ago

this sounds like something in the distrobox container being configured incorrectly (that error is coming from pinentry-curses when it tries to open the terminal to read the user's password), but i don't know anything about distrobox, so i can't really help here. if you figure it out and there's anything that would be helpful for me to change, i'm happy to look into it.