smorks / keepassnatmsg

KeePass plugin to expose credentials securely to a browser using Native Messaging
GNU General Public License v3.0
271 stars 26 forks source link

KeePassXC-Browser will only work if KeePass2 is launched beforehand #35

Closed zinalili closed 5 years ago

zinalili commented 5 years ago

KeePassXC-Browser can only see KeePass 2 when KeePass 2 was already running before the extension started. So in order to make the extension work, I need to shut the browser down, run KeePass and then launch browser again.

smorks commented 5 years ago

Clicking the "Reload" button in the KeePassXC-Browser extension should fix the problem without restarting the browser.

If that isn't working for you, does it give any kind of error when clicking the Reload button?

zinalili commented 5 years ago

I remember seeing "Reload" button but now I have only "Reopen the database" instead and "cannot decrypt message" error. Anyway both Reload and Reopen did nothing when I clicked them. If I disable/enable the extension it starts working right away.

zinalili commented 5 years ago

And when I get it to work and then close KeePass and click the toolbar icon KeepassNatmsg crashes.

smorks commented 5 years ago

can you tell me the versions of everything that you're using? (OS, browser, KeePassXC-Browser, KeePass, KeePassNatMsg)

I'll look into it.

zinalili commented 5 years ago

Windows 7 Opera 60.0.3255.59 KeePassXC-Browser Version: 1.4.3 KeePass 2.41 KeePassNatMsg 0.0.6.36827

smorks commented 5 years ago

thanks, i'll do some testing and see what i can find.

smorks commented 5 years ago

the behavior i'm seeing is strange.

  1. Start Browser
  2. Extension says "Cannot connect..."
  3. Open KeePass
  4. Click "Reload"
  5. Nothing appears to happen
  6. Click the extesion button again, it says it's connected

so it appears that when i'm pressing "Reload", it's working, but it's just not refreshing properly. i'll look into if this is a problem with the extension or with my plugin.

in the meantime, can you try those steps and see if you're getting the same behavior?

zinalili commented 5 years ago

I see "Message encryption failed. Is KeePassXC running?" instead of "Cannot connect..." The rest is the same.

smorks commented 5 years ago

and even though the button appears to not do anything, it does start working after pressing "Reload"?

zinalili commented 5 years ago

and even though the button appears to not do anything, it does start working after pressing "Reload"?

yes, it does

smorks commented 5 years ago

i tested with KeePassXC, and it does the same thing as well, so I believe it's just a display issue with the KeePassXC-Browser extension. I see you reported the issue in their repo (keepassxreboot/keepassxc-browser#523), i'll add my findings there as well.