Package io.webfolder.cdp.command
Interface WebAuthnAsync
public interface WebAuthnAsync
This domain allows configuring virtual authenticators to test the WebAuthn API.
-
Method Summary
Modifier and TypeMethodDescriptionaddCredential
(String authenticatorId, Credential credential) Adds the credential to the specified authenticator.Creates and adds a virtual authenticator.clearCredentials
(String authenticatorId) Clears all the credentials from the specified device.disable()
Disable the WebAuthn domain.enable()
Enable the WebAuthn domain and start intercepting credential storage and retrieval with a virtual authenticator.Enable the WebAuthn domain and start intercepting credential storage and retrieval with a virtual authenticator.getCredential
(String authenticatorId, String credentialId) Returns a single credential stored in the given virtual authenticator that matches the credential ID.getCredentials
(String authenticatorId) Returns all the credentials stored in the given virtual authenticator.removeCredential
(String authenticatorId, String credentialId) Removes a credential from the authenticator.removeVirtualAuthenticator
(String authenticatorId) Removes the given authenticator.setAutomaticPresenceSimulation
(String authenticatorId, Boolean enabled) Sets whether tests of user presence will succeed immediately (if true) or fail to resolve (if false) for an authenticator.setUserVerified
(String authenticatorId, Boolean isUserVerified) Sets whether User Verification succeeds or fails for an authenticator.
-
Method Details
-
addCredential
Adds the credential to the specified authenticator. -
addVirtualAuthenticator
Creates and adds a virtual authenticator. -
clearCredentials
Clears all the credentials from the specified device. -
disable
CompletableFuture<Void> disable()Disable the WebAuthn domain. -
enable
CompletableFuture<Void> enable()Enable the WebAuthn domain and start intercepting credential storage and retrieval with a virtual authenticator. -
enable
Enable the WebAuthn domain and start intercepting credential storage and retrieval with a virtual authenticator.- Parameters:
enableUI
- Whether to enable the WebAuthn user interface. Enabling the UI is recommended for debugging and demo purposes, as it is closer to the real experience. Disabling the UI is recommended for automated testing. Supported at the embedder's discretion if UI is available. Defaults to false.
-
getCredential
Returns a single credential stored in the given virtual authenticator that matches the credential ID. -
getCredentials
Returns all the credentials stored in the given virtual authenticator. -
removeCredential
Removes a credential from the authenticator. -
removeVirtualAuthenticator
Removes the given authenticator. -
setAutomaticPresenceSimulation
Sets whether tests of user presence will succeed immediately (if true) or fail to resolve (if false) for an authenticator. The default is true. -
setUserVerified
Sets whether User Verification succeeds or fails for an authenticator. The default is true.
-