[GH-ISSUE #641] Unable to register FIDO U2F #435

Closed
opened 2026-03-03 01:29:06 +03:00 by kerem · 2 comments
Owner

Originally created by @targodan on GitHub (Oct 2, 2019).
Original GitHub issue: https://github.com/dani-garcia/vaultwarden/issues/641

I can't register my YubiKey for FIDO U2F. When I click the Read Key button in the vault UI it says There was a problem reading the security key. Try again. (Firefox 69.0.1 64-bit on Windows 10) I have used the very same YubiKey successfully with this Firefox version on other websites before.

Here's what the JS-Console says:

listening for key...                   two-factor-u2f.component.ts:126:16
error: 2                               two-factor-u2f.component.ts:138:28

I'm running the docker image in swarm mode bitwardenrs/server:alpine (healthchecks disabled, see #618), behind a caddy proxy. Here's my caddy file for bitwarden:

[REDACTED_URL].de {
    header / {
        Strict-Transport-Security "max-age=31536000;"
        X-XSS-Protection "1; mode=block"
        X-Frame-Options "DENY"
    }

    proxy /notifications/hub bitwarden.web:3012 {
        websocket
    }
    proxy /notifications/hub/negotiate bitwarden.web:8080 {
        transparent
    }
    proxy / bitwarden.web:8080 {
        transparent
    }
}

I am accessing the vault via HTTPS with a valid letsencrypt certificate and I've set the DOMAIN variable accordingly. The container logs only yield successful request, no errors or warnings.

Originally created by @targodan on GitHub (Oct 2, 2019). Original GitHub issue: https://github.com/dani-garcia/vaultwarden/issues/641 I can't register my YubiKey for FIDO U2F. When I click the `Read Key` button in the vault UI it says `There was a problem reading the security key. Try again.` (Firefox 69.0.1 64-bit on Windows 10) I have used the very same YubiKey successfully with this Firefox version on other websites before. Here's what the JS-Console says: ``` listening for key... two-factor-u2f.component.ts:126:16 error: 2 two-factor-u2f.component.ts:138:28 ``` I'm running the docker image in swarm mode `bitwardenrs/server:alpine` (healthchecks disabled, see #618), behind a caddy proxy. Here's my caddy file for bitwarden: ``` [REDACTED_URL].de { header / { Strict-Transport-Security "max-age=31536000;" X-XSS-Protection "1; mode=block" X-Frame-Options "DENY" } proxy /notifications/hub bitwarden.web:3012 { websocket } proxy /notifications/hub/negotiate bitwarden.web:8080 { transparent } proxy / bitwarden.web:8080 { transparent } } ``` I am accessing the vault via HTTPS with a valid letsencrypt certificate and I've set the `DOMAIN` variable accordingly. The container logs only yield successful request, no errors or warnings.
kerem closed this issue 2026-03-03 01:29:06 +03:00
Author
Owner

@targodan commented on GitHub (Oct 2, 2019):

Ok, sorry. I figured it out. I had the variable DOMAIN=REDACTED_DOMAIN.de, but instead it needs to be DOMAIN=https://REDACTED_DOMAIN.de

<!-- gh-comment-id:537461308 --> @targodan commented on GitHub (Oct 2, 2019): Ok, sorry. I figured it out. I had the variable `DOMAIN=REDACTED_DOMAIN.de`, but instead it needs to be `DOMAIN=https://REDACTED_DOMAIN.de`
Author
Owner

@whoo commented on GitHub (May 5, 2021):

Hi,
I've got the same issue with docker vaultwarden.

docker run -d --name vaultwarden -e DOMAIN=https://wizz:5000 -v /vw-data/:/data/ -p 80:80 vaultwarden/server:latest
socat openssl-listen:5000,reuseaddr,fork,cert=wizz.pem,verify=0 tcp4:127.0.0.1:80

listening for key... 
error: 2

Probably websocket error... but there is no listening port on 3012 on container.

<!-- gh-comment-id:832622420 --> @whoo commented on GitHub (May 5, 2021): Hi, I've got the same issue with docker vaultwarden. `docker run -d --name vaultwarden -e DOMAIN=https://wizz:5000 -v /vw-data/:/data/ -p 80:80 vaultwarden/server:latest` `socat openssl-listen:5000,reuseaddr,fork,cert=wizz.pem,verify=0 tcp4:127.0.0.1:80` ``` listening for key... error: 2 ``` Probably websocket error... but there is no listening port on 3012 on container.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/vaultwarden#435
No description provided.