Skip to content

ctap2.3: long-touch reset (§6.11.5, §7.7)#69

Merged
robin-nitrokey merged 1 commit into
mainfrom
long-touch
Jun 3, 2026
Merged

ctap2.3: long-touch reset (§6.11.5, §7.7)#69
robin-nitrokey merged 1 commit into
mainfrom
long-touch

Conversation

@robin-nitrokey

Copy link
Copy Markdown
Member

Cherry-picked from #60 and slightly modified to fix the get_info response and to improve the check for supported commands in config.

Comment thread tests/virt/mod.rs
Comment on lines +164 to +167
/// User interface that returns a static value for the user presence check.
struct TestUI {
user_presence: Level,
}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@0x0ece I’ve included this change that replaces TestUp with a UserInterface implementation that returns a static value for discussion. The benefit is that we use the normal UP path through trussed (and also return the correct error code!), the downside is that the test has to wait for the user presence timeout of 30s. If we want to go that way, we could make the timeout configurable so that tests can reduce it to e. g. 1s. What do you think?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

config timeout might be a good idea, I just re-looked at the spec and they say "MUST be at least 10 seconds". so yeah, like we put it 1s for unit tests, leave it 30s for authenticator, and it's still a feature that someone else can tune.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, I’ve added the option and set it to 100 ms for the tests.

@robin-nitrokey robin-nitrokey merged commit 4bd3629 into main Jun 3, 2026
4 checks passed
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

Successfully merging this pull request may close these issues.

2 participants