generated from Firehed/php-library-template
-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Conditional registration support (#85)
This adds a new optional parameter to the credential registration verification procedure (WebAuthn 7.1) to account for conditional mediation. > Verify that the [UP](https://w3c.github.io/webauthn/#authdata-flags-up) bit of the [flags](https://w3c.github.io/webauthn/#authdata-flags) in authData is set, unless options.[mediation](https://w3c.github.io/webappsec-credential-management/#dom-credentialcreationoptions-mediation) is set to [conditional](https://w3c.github.io/webappsec-credential-management/#dom-credentialmediationrequirement-conditional). Note that this is only in the draft spec, but it's likely to remain materially unchanged since this exact tooling was described at WWDC24. Still, I'm going to leave this undocumented for now (besides the actual method signature) in case anything changes before the next published version. Fixes #83.
- Loading branch information
Showing
3 changed files
with
76 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Firehed\WebAuthn\Enums; | ||
|
||
/** | ||
* Credential Management (Level 1) | ||
* §2.3.2 | ||
* @link https://w3c.github.io/webappsec-credential-management/#dom-credentialmediationrequirement-conditional | ||
*/ | ||
enum CredentialMediationRequirement: string | ||
{ | ||
case Silent = 'silent'; | ||
case Optional = 'optional'; | ||
case Conditional = 'conditional'; | ||
case Required = 'required'; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters