keepassxreboot/keepassxc-browser

can not connect to keepassXC from firefox/windows

Opened this issue · 19 comments

can not connect to keepassXC from firefox version 122 /windows 10
error: Key exchange was not successful.
tried what is mentioned in the troubleshooting guide

it works with edge and brave browsers

Debug info

[Error keepassxc-browser.js:980] KeePassXC-Browser - NotSupportedError: Operation is not supported
firefox downloaded from mozilla.org

KeePassXC - 2.76
KeePassXC-Browser - 1.8.12
Operating system: windows 10
Browser: firefox 122.0.1

Please report your findings based on the Troubleshooting Guide. That error seems strange.

I am not sure what you mean by that.
inside the folder: C:\Users{USER}\AppData\Local\KeePassXC are these files:

org.keepassxc.keepassxc_browser.json
org.keepassxc.keepassxc_browser_brave.json
org.keepassxc.keepassxc_browser_chrome.json
org.keepassxc.keepassxc_browser_chromium.json
org.keepassxc.keepassxc_browser_edge.json
org.keepassxc.keepassxc_browser_firefox.json
org.keepassxc.keepassxc_browser_tor-browser.json
org.keepassxc.keepassxc_browser_vivaldi.json

all chrome based browsers work and can connect
the files:

org.keepassxc.keepassxc_browser.json
org.keepassxc.keepassxc_browser_firefox.json
org.keepassxc.keepassxc_browser_tor-browser.json

contain this:

{
    "allowed_extensions": [
        "keepassxc-browser@keepassxc.org"
    ],
    "description": "KeePassXC integration with native messaging support",
    "name": "org.keepassxc.keepassxc_browser",
    "path": "C:\\Program Files\\KeePassXC\\keepassxc-proxy.exe",
    "type": "stdio"
}

the keepassxc-proxy.exe path is correct.

the registry contains the entries mentioned in the troubleshooter

i dont know what to do with process monitor

in firefox debugging i get these error messages:

KeePassXC-Browser: Connecting to native messaging host org.keepassxc.keepassxc_browser client.js:367:13
[Error ] KeePassXC-Browser - Failed to connect: Unknown error global.js:132:13
[Error ] KeePassXC-Browser - No content script available for this tab. global.js:132:13
[Error keepass.js:256] KeePassXC-Browser - 5: Cannot connect to KeePassXC. Check that browser integration is enabled in KeePassXC settings. global.js:132:13
KeePassXC-Browser: Connecting to native messaging host org.keepassxc.keepassxc_browser client.js:367:13
[Error ] KeePassXC-Browser - Failed to connect: Unknown error global.js:132:13
[Error ] KeePassXC-Browser - No content script available for this tab. global.js:132:13
[Error ] KeePassXC-Browser - 9: Key exchange was not successful. global.js:132:13
[Error ] KeePassXC-Browser - No content script available for this tab. global.js:132:13
[Error keepass.js:256] KeePassXC-Browser - 5: Cannot connect to KeePassXC. Check that browser integration is enabled in KeePassXC settings. global.js:132:13
[Error ] KeePassXC-Browser - No content script available for this tab. 2 global.js:132:13
[Error ] KeePassXC-Browser - Cannot send activated_tab message: Could not establish connection. Receiving end does not exist. 44 global.js:132:13
Uncaught (in promise) Error: Invalid tab ID: 581 undefined
[Error ] KeePassXC-Browser - Cannot send activated_tab message: Could not establish connection. Receiving end does not exist. 6 global.js:132:13
[Error keepass.js:256] KeePassXC-Browser - 5: Cannot connect to KeePassXC. Check that browser integration is enabled in KeePassXC settings. global.js:132:13
KeePassXC-Browser: Connecting to native messaging host org.keepassxc.keepassxc_browser client.js:367:13
[Error ] KeePassXC-Browser - Failed to connect: Unknown error global.js:132:13
[Error ] KeePassXC-Browser - 9: Key exchange was not successful. global.js:132:13
KeePassXC-Browser: Connecting to native messaging host org.keepassxc.keepassxc_browser client.js:367:13
[Error ] KeePassXC-Browser - Failed to connect: Unknown error global.js:132:13
[Error ] KeePassXC-Browser - 9: Key exchange was not successful. global.js:132:13
KeePassXC-Browser: Connecting to native messaging host org.keepassxc.keepassxc_browser client.js:367:13
[Error ] KeePassXC-Browser - Failed to connect: Unknown error global.js:132:13
[Error ] KeePassXC-Browser - 9: Key exchange was not successful. global.js:132:13
[Error ] KeePassXC-Browser - Cannot send activated_tab message: Could not establish connection. Receiving end does not exist. global.js:132:13
[Error keepass.js:256] KeePassXC-Browser - 5: Cannot connect to KeePassXC. Check that browser integration is enabled in KeePassXC settings. global.js:132:13
KeePassXC-Browser: Connecting to native messaging host org.keepassxc.keepassxc_browser client.js:367:13
[Error ] KeePassXC-Browser - Failed to connect: Unknown error global.js:132:13
[Error ] KeePassXC-Browser - 9: Key exchange was not successful. global.js:132:13
KeePassXC-Browser: Connecting to native messaging host org.keepassxc.keepassxc_browser client.js:367:13
[Error ] KeePassXC-Browser - Failed to connect: Unknown error global.js:132:13
[Error ] KeePassXC-Browser - 9: Key exchange was not successful. global.js:132:13
[Error ] KeePassXC-Browser - Cannot send activated_tab message: Could not establish connection. Receiving end does not exist.

also i dont know what to do with debugging keepassxc-browser.js in the firefox debugger

was that what you were asking for?

A couple of things to check:

  • Is the keepassxc-proxy.exe running?
  • What happens if you run it manually?
  • Have you tried to downgrade Firefox?
  • keepassxc-proxy.exe was running under the edge browser

image

  • if i run keepassxc-proxy.exe manually i get a blank window

image
and keepassxc-proxy.exe is now running under explorer.exe as well as under edge but firefox still cannot connect

  • no I havent tried downgrading, could try in the following days.

but why isnt it working? does it make any sense?

but why isnt it working? does it make any sense?

No it doesn't. This is why I suggested that you try to downgrade.

but why isnt it working? does it make any sense?

No it doesn't. This is why I suggested that you try to downgrade.

Please see this: #2113

ok so i tried a couple of older versions, and some portable ones, also tor browser. nothing seems to work. keepassxc-proxy.exe does not run with firefox. only with other chrome based browsers. what else can i try?

@aombk Can you paste the relevant registry entry here? You can also verify the path Firefox is trying to use with https://docs.microsoft.com/en-us/sysinternals/downloads/procmon

the key name is
HKEY_CURRENT_USER\SOFTWARE\Mozilla\NativeMessagingHosts\org.keepassxc.keepassxc_browser
and the value is
C:/Users/{USER}/AppData/Local/KeePassXC/org.keepassxc.keepassxc_browser.json

will check now with procmon

these are from procmon
i really dont know what to look for.
kpp1
kpp2

the key name is HKEY_CURRENT_USER\SOFTWARE\Mozilla\NativeMessagingHosts\org.keepassxc.keepassxc_browser and the value is C:/Users/{USER}/AppData/Local/KeePassXC/org.keepassxc.keepassxc_browser.json

will check now with procmon

Does this match with the registry entries with Chromium-based browsers?

yes, for edge its this:
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Edge\NativeMessagingHosts\org.keepassxc.keepassxc_browser
C:/Users/{USER}/AppData/Local/KeePassXC/org.keepassxc.keepassxc_browser_edge.json

i would like to note that the issue is still not resolved

A couple of new points/questions:

  • Are you using some anti-virus or anti-malware software that could affect this?
  • Try disabling all other extensions and see if it solved the problem
  • Create a new temporary profile to Firefox and install the extension there, does it work?

I am using the microsoft windows built in security.
I disabled it and all firefox extensions and I also did a new firefox profile
but keepassXC browser plugin still could not connect to keepassxc software

Does re-enabling the "Update native messaging manifest files at startup" help?

I don't know where to re-enable that

I don't know where to re-enable that

Browser Integration -> Advaced. Accept the dialog with OK after doing that.

aombk commented

nope, it does not help unfortunately