KeePassXC Browser Extension
Find a file
Céleste Wouters d3cc7ee925
Fix TOTP fill missing digits on some sites (fixes #2215)
Fixes Authelia and Epic Games OTP fill by addressing
two underlying problems:

1. Incorrect DOM event ordering and data
- So far only empty key events were sent, which may confuse OTP input
  implementations that rely on the text from those events instead of
  input field value.
- The "beforeinput" event was missing altogether.
- Reorder the events to comply to the UIEvents spec
  (https://w3c.github.io/uievents/#keypress-event-order)
  and change field.value at the expected moment in that order.

2. Focus events were not sent
As described in
https://github.com/keepassxreboot/keepassxc-browser/issues/2215#issuecomment-3629070227,
the extension focuses fields sequentially when filling in the OTP digits, but
this does not trigger focus/blur events as this is performed within the same
window event loop cycle, throwing off certain implementations of
multi-textfield OTP input; in the cause of Authelia filling an internal digit
buffer starting from nonexistent index -1.

Sending those events manually was attempted but did not yield satisfactory
results as some frameworks like React use Promise objects to schedule
their state update, resulting in the problem still being present.

Instead, makes kpxcFill.setValueWithChange async so it can await on an empty
Promise of its own, giving time for the user agent to trigger the
appropriate focus events as well as for pages' scripts to settle.
2025-12-09 23:05:17 +01:00
.github Add CONTRIBUTING markdown document (#2755) 2025-11-12 14:03:18 +02:00
.tx Update Transifex configuration file 2022-12-19 16:49:53 +02:00
.vscode Update editor configs 2023-12-19 11:45:55 +02:00
dev-resources Add optional monochrome toolbar icon (#1938) 2023-07-31 18:10:35 +03:00
dist Update to 1.9.11 2025-11-26 06:48:36 +02:00
keepassxc-browser Fix TOTP fill missing digits on some sites (fixes #2215) 2025-12-09 23:05:17 +01:00
tests Upgrade eslint to latest (#2763) 2025-11-17 11:34:52 +02:00
.editorconfig Update editor configs 2023-12-19 11:45:55 +02:00
.gitignore Update Playwright and improve tests 2024-07-14 18:50:01 +03:00
.prettierignore Update eslint rules, add .prettierignore file, fix some formatting, and fix some bugs (#1756) 2022-11-16 13:11:13 +02:00
.prettierrc Update editor configs 2023-12-19 11:45:55 +02:00
build.js Prevent build script for creating a parent folder 2024-08-11 21:50:03 +03:00
CHANGELOG Update to 1.9.11 2025-11-26 06:48:36 +02:00
eslint.config.mjs Upgrade eslint to latest (#2763) 2025-11-17 11:34:52 +02:00
keepassxc-protocol.md Add configuration option for default passkeys group 2024-09-14 17:57:01 +03:00
LICENSE Initial commit 2017-03-27 07:28:17 +03:00
package-lock.json Update to 1.9.11 2025-11-26 06:48:36 +02:00
package.json Update to 1.9.11 2025-11-26 06:48:36 +02:00
playwright.config.ts Update Playwright and improve tests 2024-07-14 18:50:01 +03:00
README.md Add CONTRIBUTING markdown document (#2755) 2025-11-12 14:03:18 +02:00

KeePassXC-Browser

Browser extension for KeePassXC with native messaging.

Download and use

This browser extension was first supported in KeePassXC 2.3.0 (release end of 2017). In general it is advised to only use the latest available release.

Get the extension for Firefox or Chrome/Chromium or Microsoft Edge.

Please see this document for instructions how to configure KeePassXC in order to connect the database correctly.

How it works

KeePassXC-Browser communicates with KeePassXC through keepassxc-proxy. The proxy handles listening to STDIN/STDOUT and transfers these messages through Unix domain sockets / named pipes to KeePassXC. This means KeePassXC can be used and started normally without inteference from Native Messaging API. KeePassXC-Browser starts only the proxy application and there's no risk of shutting down KeePassXC or losing any unsaved changes. You don't need to install keepassxc-proxy separately. It is included in the KeePassXC application package. Alternatively you can use keepassxc-proxy-rust as a proxy if you prefer a non-Qt solution.

Requested permissions

KeePassXC-Browser extension requests the following permissions:

Name Reason
activeTab To get URL of the current tab
contextMenus To show context menu items
cookies To access browser's internal Public Suffix List
clipboardWrite Allows password to be copied from password generator to clipboard
nativeMessaging Allows communication with KeePassXC application
notifications To show browser notifications
offscreen For accessing system theme when setting icon colors (Chrome only)
privacy For setting the extension as default password manager
storage For storing extension settings (always stored locally in the browser, they are never synced)
tabs To request tab URL's and other info
webNavigation To show browser notifications on install or update
webRequest For handling HTTP Basic Auth
webRequestAuthProvider For handling HTTP Basic Auth for Chromium based browsers
webRequestBlocking For handling HTTP Basic Auth
http://*/* To allow using KeePassXC-Browser on all websites
https://*/* To allow using KeePassXC-Browser on all websites
https://api.github.com/ For checking the latest KeePassXC version from GitHub

Protocol

Check keepassxc-protocol for the details about the messaging protocol used between the browser extension and KeePassXC.

Translations

Translations are managed on Transifex which offers a web interface. Please join an existing language team or request a new one if there is none.

Contributing

You may directly contribute your own code by submitting a pull request. Please read the CONTRIBUTING document for further information.

Development and testing

See wiki.

Help!

See our Troubleshooting Guide for solving problems if previously listed issues and solutions are not working.