Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Browser integration doesn't respect XDG_CONFIG_HOME #4121

Closed
NikolausDemmel opened this issue Dec 16, 2019 · 5 comments · Fixed by #4680
Closed

Browser integration doesn't respect XDG_CONFIG_HOME #4121

NikolausDemmel opened this issue Dec 16, 2019 · 5 comments · Fixed by #4680

Comments

@NikolausDemmel
Copy link

I migrated from an Ubuntu 16.04 machine to a new machine with 18.04. KeepassXC is working, and the browser integration for Firefox as well, but for Chrome it is not. It was working before migration.

I've enabled the browser support in the KeepassXC settings and installed the Chrome Extension. Both should be up to date.

If I click on the KeepassXC icon in Chrome it shows:

KeePassXC-Browser has encountered an error:

Cannot connect to KeePassXC. Check that browser integration is enabled in KeePassXC settings.

If I click "Reload", the error message changes to

Key exchange was not successful.

In the extension settings, under "connected databases", there are no entries, and if I click "Connect", nothing happens. After migration, there were two entries, but since it wasn't working, I have removed them in the meantime.

One thing that is different to the previous machine, is that now I have XDG_CONFIG_HOME set up, and I copied my chrome user profile to the new location. It is now in ~/bionic/.config/google-chrome/Profile 1, whereas before it was in the more default ~/.config/google-chrome/Profile 1. Could that be a reason for the issue? Note that Firefox doesn't respect XDG_CONFIG_HOME and the firefox profile is still under ~/.mozilla like on the old machine.

Debug info

There seem to be no keepassxc related error messages in the JS console (depending on the site I have open no messages at all)
KeePassXC - 2.5.1
KeePassXC-Browser - 1.5.4
Operating system: Linux
Browser: Chrome

@droidmonkey
Copy link
Member

Is chrome running as a snap?

@NikolausDemmel
Copy link
Author

Thanks for the quick response.

No, should be from apt package:

google-chrome-stable:
  Installed: 79.0.3945.79-1
  Candidate: 79.0.3945.79-1
  Version table:
 *** 79.0.3945.79-1 500
        500 http://dl.google.com/linux/chrome/deb stable/main amd64 Packages
        100 /var/lib/dpkg/status

@varjolintu
Copy link
Member

The NativeMessagingHosts directory should be under the main configuration path of the browser, can you check it out? It's ~/.config/google-chrome/NativeMessagingHosts.

@NikolausDemmel
Copy link
Author

It was empty for my new install. As described above, due to the use of XDG_CONFIG_HOME, the path is ~/bionic/.config/google-chrome/NativeMessagingHosts/. I copied the file org.keepassxc.keepassxc_browser.json from the old path, and now I could connect again. KeepassXC is working.

Is that the native KeepassXC application that is supposed to setup this file, or the chrome extension? Looks like this would need a patch to deal with XDG_CONFIG_HOME properly.

But anyway. My immediate issue is solve, thanks!

@droidmonkey droidmonkey changed the title Browser integration with chrome not working after migration to new PC Browser integration doesn't respect XDG_CONFIG_HOME Dec 16, 2019
@varjolintu
Copy link
Member

KeePassXC setups the file and currently it doesn't respect XDG_CONFIG_HOME.

@varjolintu varjolintu transferred this issue from keepassxreboot/keepassxc-browser Jan 7, 2020
droidmonkey added a commit that referenced this issue May 1, 2020
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
droidmonkey added a commit that referenced this issue May 1, 2020
* Removed option to attach KeePassXC to the browser extension. Users must use the proxy application to communicate with KeePassXC.
* Significantly streamlined proxy code. Used same implementation of stdin/stdout interface across all platforms.
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
droidmonkey added a commit that referenced this issue May 1, 2020
* Removed option to attach KeePassXC to the browser extension. Users must use the proxy application to communicate with KeePassXC.
* Significantly streamlined proxy code. Used same implementation of stdin/stdout interface across all platforms.
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
droidmonkey added a commit that referenced this issue May 11, 2020
* Removed option to attach KeePassXC to the browser extension. Users must use the proxy application to communicate with KeePassXC.
* Significantly streamlined proxy code. Used same implementation of stdin/stdout interface across all platforms.
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
droidmonkey added a commit that referenced this issue May 11, 2020
* Removed option to attach KeePassXC to the browser extension. Users must use the proxy application to communicate with KeePassXC.
* Significantly streamlined proxy code. Used same implementation of stdin/stdout interface across all platforms.
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
droidmonkey added a commit that referenced this issue May 13, 2020
* Removed option to attach KeePassXC to the browser extension. Users must use the proxy application to communicate with KeePassXC.
* Significantly streamlined proxy code. Used same implementation of stdin/stdout interface across all platforms.
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
droidmonkey added a commit that referenced this issue May 13, 2020
* Removed option to attach KeePassXC to the browser extension. Users must use the proxy application to communicate with KeePassXC.
* Significantly streamlined proxy code. Used same implementation of stdin/stdout interface across all platforms.
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
droidmonkey added a commit that referenced this issue May 14, 2020
* Removed option to attach KeePassXC to the browser extension. Users must use the proxy application to communicate with KeePassXC.
* Significantly streamlined proxy code. Used same implementation of stdin/stdout interface across all platforms.
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
droidmonkey added a commit that referenced this issue May 14, 2020
* Removed option to attach KeePassXC to the browser extension. Users must use the proxy application to communicate with KeePassXC.
* Significantly streamlined proxy code. Used same implementation of stdin/stdout interface across all platforms.
* Moved browser service entry point to BrowserService class instead of NativeMessagingHost. BrowserService now coordinates the communication to/from clients.
* Moved settings page definition out of MainWindow
* Decoupled BrowserService from DatabaseTabWidget
* Reduced complexity of various functions and cleaned the ABI (public vs private).
* Eliminated BrowserClients class, moved functionality into the BrowserService
* Renamed HostInstaller to NativeMessageInstaller and renamed NativeMessageHost to BrowserHost.
* Recognize XDG_CONFIG_HOME when installing native message file on Linux. Fix #4121 and fix #4123.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants