Matthias Andreas Benkard | b382b10 | 2021-01-02 15:32:21 +0100 | [diff] [blame^] | 1 | <?php |
| 2 | |
| 3 | |
| 4 | namespace WebAuthn\Attestation\Format; |
| 5 | use WebAuthn\WebAuthnException; |
| 6 | |
| 7 | class None extends FormatBase { |
| 8 | |
| 9 | |
| 10 | public function __construct($AttestionObject, \WebAuthn\Attestation\AuthenticatorData $authenticatorData) { |
| 11 | parent::__construct($AttestionObject, $authenticatorData); |
| 12 | } |
| 13 | |
| 14 | |
| 15 | /* |
| 16 | * returns the key certificate in PEM format |
| 17 | * @return string |
| 18 | */ |
| 19 | public function getCertificatePem() { |
| 20 | return null; |
| 21 | } |
| 22 | |
| 23 | /** |
| 24 | * @param string $clientDataHash |
| 25 | */ |
| 26 | public function validateAttestation($clientDataHash) { |
| 27 | return true; |
| 28 | } |
| 29 | |
| 30 | /** |
| 31 | * validates the certificate against root certificates |
| 32 | * @param array $rootCas |
| 33 | * @return boolean |
| 34 | * @throws WebAuthnException |
| 35 | */ |
| 36 | public function validateRootCertificate($rootCas) { |
| 37 | return true; |
| 38 | } |
| 39 | } |