class VerifyHandler implements VerifyHandlerInterface (View source)

Traits

Contains logic which is shared between both WebAuthn's RegisterHandler and VerifyHandler, such as the attestation configuration options.

Properties

protected LoggerInterface $logger

Methods

protected
Decoder
getDecoder() deprecated

No description

protected
AttestationStatementSupportManager
getAttestationStatementSupportManager(Decoder $decoder)

No description

protected
AttestationObjectLoader
getAttestationObjectLoader(AttestationStatementSupportManager $attestationStatementSupportManager, Decoder $decoder)

No description

protected
PublicKeyCredentialLoader
getPublicKeyCredentialLoader(AttestationObjectLoader $attestationObjectLoader, Decoder $decoder)

No description

protected
PublicKeyCredentialUserEntity
getUserEntity(Member $member)

No description

public
setLogger(LoggerInterface|null $logger)

Sets the {$logger} member variable

public
array
start(StoreInterface $store, RegisteredMethod $method)

Stores any data required to handle a log in process with a method, and returns relevant state to be applied to the front-end application managing the process.

public
verify(HTTPRequest $request, StoreInterface $store, RegisteredMethod $registeredMethod)

Verify the request has provided the right information to verify the member that aligns with any sessions state that may have been set prior

public
string
getComponent()

Get the key that a React UI component is registered under (with @silverstripe/react-injector on the front-end)

protected
PublicKeyCredentialRequestOptions
getCredentialRequestOptions(StoreInterface $store, RegisteredMethod $registeredMethod = null, bool $reset = false)

No description

protected
AuthenticatorAssertionResponseValidator
getAuthenticatorAssertionResponseValidator(Decoder $decoder, StoreInterface $store)

No description

Details

protected Decoder getDecoder() deprecated

deprecated 4.5.0 Will be removed without equivalent functionality to replace it No longer needed as of v3 of webauthn-lib the Decoder is now created within both: AttestationObjectLoader::__construct() AuthenticatorAssertionResponseValidator::__construct()

No description

Return Value

Decoder

protected AttestationStatementSupportManager getAttestationStatementSupportManager(Decoder $decoder)

No description

Parameters

Decoder $decoder

Return Value

AttestationStatementSupportManager

protected AttestationObjectLoader getAttestationObjectLoader(AttestationStatementSupportManager $attestationStatementSupportManager, Decoder $decoder)

No description

Parameters

AttestationStatementSupportManager $attestationStatementSupportManager
Decoder $decoder

Return Value

AttestationObjectLoader

protected PublicKeyCredentialLoader getPublicKeyCredentialLoader(AttestationObjectLoader $attestationObjectLoader, Decoder $decoder)

No description

Parameters

AttestationObjectLoader $attestationObjectLoader
Decoder $decoder

Return Value

PublicKeyCredentialLoader

protected CredentialRepository getCredentialRepository(StoreInterface $store, RegisteredMethod $registeredMethod = null)

No description

Parameters

StoreInterface $store
RegisteredMethod $registeredMethod

Return Value

CredentialRepository

protected PublicKeyCredentialUserEntity getUserEntity(Member $member)

No description

Parameters

Member $member

Return Value

PublicKeyCredentialUserEntity

VerifyHandler setLogger(LoggerInterface|null $logger)

Sets the {$logger} member variable

Parameters

LoggerInterface|null $logger

Return Value

VerifyHandler

array start(StoreInterface $store, RegisteredMethod $method)

Stores any data required to handle a log in process with a method, and returns relevant state to be applied to the front-end application managing the process.

Parameters

StoreInterface $store

An object that hold session data (and the Member) that can be mutated

RegisteredMethod $method

The RegisteredMethod instance that is being verified

Return Value

array

Props to be passed to a front-end component

Result verify(HTTPRequest $request, StoreInterface $store, RegisteredMethod $registeredMethod)

Verify the request has provided the right information to verify the member that aligns with any sessions state that may have been set prior

Parameters

HTTPRequest $request
StoreInterface $store
RegisteredMethod $registeredMethod

The RegisteredMethod instance that is being verified

Return Value

Result

string getComponent()

Get the key that a React UI component is registered under (with @silverstripe/react-injector on the front-end)

Return Value

string

protected PublicKeyCredentialRequestOptions getCredentialRequestOptions(StoreInterface $store, RegisteredMethod $registeredMethod = null, bool $reset = false)

No description

Parameters

StoreInterface $store
RegisteredMethod $registeredMethod
bool $reset

Return Value

PublicKeyCredentialRequestOptions

Exceptions

AuthenticationFailedException
Exception

protected AuthenticatorAssertionResponseValidator getAuthenticatorAssertionResponseValidator(Decoder $decoder, StoreInterface $store)

No description

Parameters

Decoder $decoder
StoreInterface $store

Return Value

AuthenticatorAssertionResponseValidator