CoreFiles by mySites.guru
AuthenticatorAssertionResponse.php41 lines, 953 bytes, from Joomla_6.2.0-Stable-Full_Package.zip
Raw History Compare with 6.1.4
md5
02527bfd977f161d8cbf6e4370c1637f
sha1
25ca526d83e77cc1101e60fbcdf75c10fa209983
sha256
6f494385f35351df7f058c962531a72fd2a877fc201575a197c1855f4a9a36df
<?php

declare(strict_types=1);

namespace Webauthn;

use Webauthn\Util\Base64;

/**
 * @see https://www.w3.org/TR/webauthn/#authenticatorassertionresponse
 */
class AuthenticatorAssertionResponse extends AuthenticatorResponse
{
    public function __construct(
        CollectedClientData $clientDataJSON,
        private readonly AuthenticatorData $authenticatorData,
        private readonly string $signature,
        private readonly ?string $userHandle
    ) {
        parent::__construct($clientDataJSON);
    }

    public function getAuthenticatorData(): AuthenticatorData
    {
        return $this->authenticatorData;
    }

    public function getSignature(): string
    {
        return $this->signature;
    }

    public function getUserHandle(): ?string
    {
        if ($this->userHandle === null || $this->userHandle === '') {
            return $this->userHandle;
        }

        return Base64::decode($this->userHandle);
    }
}

The same content is in 149 releases, Joomla 5.0.0-beta3 to 6.2.1-rc1. See them all, or every version of this file.