Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions BUILDING.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,25 @@ export GSETTINGS_SCHEMA_DIR=$CREDSD_REPO/build/credentialsd-ui/data
$CREDSD_REPO/build/credentialsd-ui/src/credentialsd-ui
```

## Testing without a security key

For development, credentialsd can offer an in-memory test authenticator as a
USB security key. It is never built by default:

```shell
meson setup -Dprofile=development -Dtest_authenticator=true build
ninja -C build
CREDSD_TEST_AUTHENTICATOR=1 ./build/credentialsd/src/credentialsd
```

It is only offered to `https://webauthn.io` and `https://demo.yubico.com`. It
answers the "touch your key" step and user verification automatically, keeps
its keys in memory only, and forgets them when credentialsd exits. Do not use
it for real accounts.

While it is offered, it answers the device selection step instantly, so a real
security key plugged in at the same time can't be picked on those sites.

## Testing development builds with Firefox Web Add-On

If you are using the Firefox add-on to test during development, follow the instructions for
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
- daemon: Allow clients to cancel requests through xdg-desktop-portal.
- ui: Pass the caller's activation token to the compositor when showing the dialog, so it can take focus when the requesting window is in the background (#152)
- ui: Disable core dumps for the UI process, which handles typed PINs. Build with `-Denable_core_dumps=true` to allow them for debugging (#209)
- daemon: Add an optional in-memory test authenticator for testing without hardware, off by default (`-Dtest_authenticator=true` and `CREDSD_TEST_AUTHENTICATOR=1`, test sites only) (#107)

# 0.4.0 [2026-11-05]

Expand Down
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions credentialsd/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,16 @@ nfc1 = { version = "=0.7.1", default-features = false }
rand = "=0.10.2"
ring = "=0.17.14"
serde_json = "=1.0.151"
serde_cbor_2 = { version = "=0.13.0", optional = true }
tokio = { version = "=1.53.1", features = ["rt-multi-thread"] }
tokio-stream = "=0.1.19"
tokio-util = "=0.7.13"

[features]
# In-memory authenticator for testing without hardware. Never enable in
# distribution builds; see credential_service/test_authenticator.rs.
test-authenticator = ["libwebauthn/virt", "dep:serde_cbor_2"]

[dev-dependencies]
gio = "=0.22.8"
zbus = { version = "=5.18.0", default-features = false, features = ["blocking-api", "tokio"] }
6 changes: 6 additions & 0 deletions credentialsd/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@ endif
if get_option('cargo_offline') == true
cargo_options += ['--offline']
endif
if get_option('test_authenticator')
if get_option('profile') != 'development'
error('test_authenticator requires -Dprofile=development')
endif
cargo_options += ['--features', 'test-authenticator']
endif

subdir('src')
subdir('tests')
2 changes: 2 additions & 0 deletions credentialsd/src/credential_service/mod.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
pub mod hybrid;
pub mod nfc;
#[cfg(feature = "test-authenticator")]
pub(crate) mod test_authenticator;
pub mod usb;

use std::{
Expand Down
Loading