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

KeePassXC Flatpak Integration Does Not Function #381

Open
AManNeedsAMaid opened this issue Jun 14, 2023 · 3 comments
Open

KeePassXC Flatpak Integration Does Not Function #381

AManNeedsAMaid opened this issue Jun 14, 2023 · 3 comments

Comments

@AManNeedsAMaid
Copy link

Hello,

I'm experiencing an issue where Flatpak KeepassXC and Flatpak Brave browser will not communicate with each other as expected. I've tried many solutions in other github issues and forum posts, and none work.

Shouldn't the default permissions of both the Brave flatpak and KeePassXC flatpak be altered so that they work together out of the box?

Also, what can I do as a temporary solution?

@MrQvest
Copy link

MrQvest commented Jul 5, 2023

This is an issue with the flatpak browser. See: keepassxreboot/keepassxc#2656

@puccaso
Copy link

puccaso commented Jan 10, 2024

I have been having this issue for quite some time now. i have run both keepassxc and brave with debug output and i see a Lack of Direct References to KeePassXC's Unix Domain Socket: There is no explicit reference to the KeePassXC's Unix Domain socket (e.g., /run/user/1000/app/org.keepassxc.KeePassXC/org.keepassxc.KeePassXC.BrowserServer). This could be important because Brave needs access to this socket for the KeePassXC extension to work properly.
i have attempted to add this, but maybe im doing it wrong, because it still doesnt work.

adding using:

sudo flatpak override --filesystem=/run/user/1000/app/org.keepassxc.KeePassXC com.brave.Browser

also i have seen references to a proxy daemon of sorts that is expected by keepassxc, but i cant find that on my system either.

hope we can think through this and find a solution!

puc

@repsac-by
Copy link

repsac-by commented May 20, 2024

@puccaso,
When you enable Brave integration, keepassxc puts the native messagine file ~/.config/BraveSoftware/Brave-Browser/NativeMessagingHosts/org.keepassxc.keepassxc_browser.json

This is incorrect for flatpak applications, this file should be placed at path
~/.var/app/com.brave.Browser/config/BraveSoftware/Brave-Browser/NativeMessagingHosts/org.keepassxc.keepassxc_browser.json.

Also in this file you should specify the path to the keepassxc-proxy executable file, and the keepassxc-proxy itself should also be placed in the specified location.

This is what I got in the end:

$ flatpak override --user com.brave.Browser --filesystem=xdg-run/app/org.keepassxc.KeePassXC
$ cat > ~/.var/app/com.brave.Browser/config/BraveSoftware/Brave-Browser/NativeMessagingHosts/org.keepassxc.keepassxc_browser.json <<EOF
{
  "allowed_origins": [
    "chrome-extension://pdffhmdngciaglkoonimfcmckehcpafo/",
    "chrome-extension://oboonakemofpalcgghocfoadofidjkkk/"
  ],
  "description": "KeePassXC integration with native messaging support",
  "name": "org.keepassxc.keepassxc_browser",
  "path": "/var/config/BraveSoftware/Brave-Browser/NativeMessagingHosts/keepassxc-proxy",
  "type": "stdio"
}
EOF
$ git clone https://github.com/varjolintu/keepassxc-proxy-rust.git
$ cd keepassxc-proxy-rust
$ RUSTFLAGS="$RUSTFLAGS -C target-feature=+crt-static" cargo build --release
$ cp target/release/keepassxc-proxy ~/.var/app/com.brave.Browser/config/BraveSoftware/Brave-Browser/NativeMessagingHosts

Good luck

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants