primo commit
This commit is contained in:
36
libraries/vendor/web-auth/metadata-service/src/Exception/CertificateChainException.php
vendored
Normal file
36
libraries/vendor/web-auth/metadata-service/src/Exception/CertificateChainException.php
vendored
Normal file
@ -0,0 +1,36 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
use Throwable;
|
||||
|
||||
class CertificateChainException extends MetadataServiceException
|
||||
{
|
||||
/**
|
||||
* @param array<string> $untrustedCertificates
|
||||
* @param array<string> $trustedCertificates
|
||||
*/
|
||||
public function __construct(
|
||||
public readonly array $untrustedCertificates,
|
||||
public readonly array $trustedCertificates,
|
||||
string $message,
|
||||
?Throwable $previous = null
|
||||
) {
|
||||
parent::__construct($message, $previous);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array<string> $untrustedCertificates
|
||||
* @param array<string> $trustedCertificates
|
||||
*/
|
||||
public static function create(
|
||||
array $untrustedCertificates,
|
||||
array $trustedCertificates,
|
||||
string $message = 'Unable to validate the certificate chain.',
|
||||
?Throwable $previous = null
|
||||
): self {
|
||||
return new self($untrustedCertificates, $trustedCertificates, $message, $previous);
|
||||
}
|
||||
}
|
||||
18
libraries/vendor/web-auth/metadata-service/src/Exception/CertificateException.php
vendored
Normal file
18
libraries/vendor/web-auth/metadata-service/src/Exception/CertificateException.php
vendored
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
use Throwable;
|
||||
|
||||
class CertificateException extends MetadataServiceException
|
||||
{
|
||||
public function __construct(
|
||||
public readonly string $certificate,
|
||||
string $message,
|
||||
?Throwable $previous = null
|
||||
) {
|
||||
parent::__construct($message, $previous);
|
||||
}
|
||||
}
|
||||
23
libraries/vendor/web-auth/metadata-service/src/Exception/CertificateRevocationListException.php
vendored
Normal file
23
libraries/vendor/web-auth/metadata-service/src/Exception/CertificateRevocationListException.php
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
use Throwable;
|
||||
|
||||
final class CertificateRevocationListException extends MetadataServiceException
|
||||
{
|
||||
public function __construct(
|
||||
public readonly string $url,
|
||||
string $message,
|
||||
?Throwable $previous = null
|
||||
) {
|
||||
parent::__construct($message, $previous);
|
||||
}
|
||||
|
||||
public static function create(string $url, string $message, ?Throwable $previous = null): self
|
||||
{
|
||||
return new self($url, $message, $previous);
|
||||
}
|
||||
}
|
||||
18
libraries/vendor/web-auth/metadata-service/src/Exception/ExpiredCertificateException.php
vendored
Normal file
18
libraries/vendor/web-auth/metadata-service/src/Exception/ExpiredCertificateException.php
vendored
Normal file
@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
use Throwable;
|
||||
|
||||
final class ExpiredCertificateException extends CertificateException
|
||||
{
|
||||
public static function create(
|
||||
string $certificate,
|
||||
string $message = 'Expired certificate',
|
||||
?Throwable $previous = null
|
||||
): self {
|
||||
return new self($certificate, $message, $previous);
|
||||
}
|
||||
}
|
||||
23
libraries/vendor/web-auth/metadata-service/src/Exception/InvalidCertificateException.php
vendored
Normal file
23
libraries/vendor/web-auth/metadata-service/src/Exception/InvalidCertificateException.php
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
use Throwable;
|
||||
|
||||
final class InvalidCertificateException extends MetadataServiceException
|
||||
{
|
||||
public function __construct(
|
||||
public readonly string $certificate,
|
||||
string $message,
|
||||
?Throwable $previous = null
|
||||
) {
|
||||
parent::__construct($message, $previous);
|
||||
}
|
||||
|
||||
public static function create(string $certificate, string $message, ?Throwable $previous = null): self
|
||||
{
|
||||
return new self($certificate, $message, $previous);
|
||||
}
|
||||
}
|
||||
16
libraries/vendor/web-auth/metadata-service/src/Exception/MetadataServiceException.php
vendored
Normal file
16
libraries/vendor/web-auth/metadata-service/src/Exception/MetadataServiceException.php
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
use Exception;
|
||||
use Throwable;
|
||||
|
||||
class MetadataServiceException extends Exception
|
||||
{
|
||||
public function __construct(string $message, ?Throwable $previous = null)
|
||||
{
|
||||
parent::__construct($message, 0, $previous);
|
||||
}
|
||||
}
|
||||
9
libraries/vendor/web-auth/metadata-service/src/Exception/MetadataStatementException.php
vendored
Normal file
9
libraries/vendor/web-auth/metadata-service/src/Exception/MetadataStatementException.php
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
class MetadataStatementException extends MetadataServiceException
|
||||
{
|
||||
}
|
||||
15
libraries/vendor/web-auth/metadata-service/src/Exception/MetadataStatementLoadingException.php
vendored
Normal file
15
libraries/vendor/web-auth/metadata-service/src/Exception/MetadataStatementLoadingException.php
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
use Throwable;
|
||||
|
||||
final class MetadataStatementLoadingException extends MetadataStatementException
|
||||
{
|
||||
public static function create(string $message, ?Throwable $previous = null): self
|
||||
{
|
||||
return new self($message, $previous);
|
||||
}
|
||||
}
|
||||
26
libraries/vendor/web-auth/metadata-service/src/Exception/MissingMetadataStatementException.php
vendored
Normal file
26
libraries/vendor/web-auth/metadata-service/src/Exception/MissingMetadataStatementException.php
vendored
Normal file
@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
use Throwable;
|
||||
|
||||
final class MissingMetadataStatementException extends MetadataStatementException
|
||||
{
|
||||
public function __construct(
|
||||
public readonly string $aaguid,
|
||||
string $message,
|
||||
?Throwable $previous = null
|
||||
) {
|
||||
parent::__construct($message, $previous);
|
||||
}
|
||||
|
||||
public static function create(
|
||||
string $aaguid,
|
||||
string $message = 'The Metadata Statement is missing',
|
||||
?Throwable $previous = null
|
||||
): self {
|
||||
return new self($aaguid, $message, $previous);
|
||||
}
|
||||
}
|
||||
9
libraries/vendor/web-auth/metadata-service/src/Exception/RevokedCertificateException.php
vendored
Normal file
9
libraries/vendor/web-auth/metadata-service/src/Exception/RevokedCertificateException.php
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Webauthn\MetadataService\Exception;
|
||||
|
||||
final class RevokedCertificateException extends CertificateException
|
||||
{
|
||||
}
|
||||
Reference in New Issue
Block a user