allow vendord
All checks were successful
Build, Push and Deploy / build-and-push (push) Successful in 3m3s
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 16s
Build, Push and Deploy / deploy-staging (push) Successful in 32s
Build, Push and Deploy / deploy-production (push) Has been skipped
Build, Push and Deploy / cleanup (push) Successful in 1s
All checks were successful
Build, Push and Deploy / build-and-push (push) Successful in 3m3s
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 16s
Build, Push and Deploy / deploy-staging (push) Successful in 32s
Build, Push and Deploy / deploy-production (push) Has been skipped
Build, Push and Deploy / cleanup (push) Successful in 1s
This commit is contained in:
18
vendor/kreait/firebase-tokens/src/JWT/Error/CustomTokenCreationFailed.php
vendored
Normal file
18
vendor/kreait/firebase-tokens/src/JWT/Error/CustomTokenCreationFailed.php
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Kreait\Firebase\JWT\Error;
|
||||
|
||||
use RuntimeException;
|
||||
use Throwable;
|
||||
|
||||
final class CustomTokenCreationFailed extends RuntimeException
|
||||
{
|
||||
public static function because(string $reason, ?int $code = null, ?Throwable $previous = null): self
|
||||
{
|
||||
$code = $code ?: 0;
|
||||
|
||||
return new self($reason, $code, $previous);
|
||||
}
|
||||
}
|
||||
18
vendor/kreait/firebase-tokens/src/JWT/Error/FetchingGooglePublicKeysFailed.php
vendored
Normal file
18
vendor/kreait/firebase-tokens/src/JWT/Error/FetchingGooglePublicKeysFailed.php
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Kreait\Firebase\JWT\Error;
|
||||
|
||||
use RuntimeException;
|
||||
use Throwable;
|
||||
|
||||
final class FetchingGooglePublicKeysFailed extends RuntimeException
|
||||
{
|
||||
public static function because(string $reason, ?int $code = null, ?Throwable $previous = null): self
|
||||
{
|
||||
$code = $code ?: 0;
|
||||
|
||||
return new self($reason, $code, $previous);
|
||||
}
|
||||
}
|
||||
28
vendor/kreait/firebase-tokens/src/JWT/Error/IdTokenVerificationFailed.php
vendored
Normal file
28
vendor/kreait/firebase-tokens/src/JWT/Error/IdTokenVerificationFailed.php
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Kreait\Firebase\JWT\Error;
|
||||
|
||||
use RuntimeException;
|
||||
|
||||
use const PHP_EOL;
|
||||
|
||||
final class IdTokenVerificationFailed extends RuntimeException
|
||||
{
|
||||
/**
|
||||
* @param array<non-empty-string> $reasons
|
||||
*/
|
||||
public static function withTokenAndReasons(string $token, array $reasons): self
|
||||
{
|
||||
if (mb_strlen($token) > 18) {
|
||||
$token = mb_substr($token, 0, 15).'...';
|
||||
}
|
||||
|
||||
$summary = implode(PHP_EOL.'- ', $reasons);
|
||||
|
||||
$message = "The value '{$token}' is not a verified ID token:".PHP_EOL.'- '.$summary.PHP_EOL;
|
||||
|
||||
return new self($message);
|
||||
}
|
||||
}
|
||||
28
vendor/kreait/firebase-tokens/src/JWT/Error/SessionCookieVerificationFailed.php
vendored
Normal file
28
vendor/kreait/firebase-tokens/src/JWT/Error/SessionCookieVerificationFailed.php
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Kreait\Firebase\JWT\Error;
|
||||
|
||||
use RuntimeException;
|
||||
|
||||
use const PHP_EOL;
|
||||
|
||||
final class SessionCookieVerificationFailed extends RuntimeException
|
||||
{
|
||||
/**
|
||||
* @param array<int|string, string> $reasons
|
||||
*/
|
||||
public static function withSessionCookieAndReasons(string $token, array $reasons): self
|
||||
{
|
||||
if (mb_strlen($token) > 18) {
|
||||
$token = mb_substr($token, 0, 15).'...';
|
||||
}
|
||||
|
||||
$summary = implode(PHP_EOL.'- ', $reasons);
|
||||
|
||||
$message = "The value '{$token}' is not a verified session cookie:".PHP_EOL.'- '.$summary.PHP_EOL;
|
||||
|
||||
return new self($message);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user