aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/spomky-labs
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/spomky-labs')
-rw-r--r--vendor/spomky-labs/otphp/README.md1
-rw-r--r--vendor/spomky-labs/otphp/composer.json10
-rw-r--r--vendor/spomky-labs/otphp/src/Factory.php4
-rw-r--r--vendor/spomky-labs/otphp/src/OTP.php10
-rw-r--r--vendor/spomky-labs/otphp/src/ParameterTrait.php2
-rw-r--r--vendor/spomky-labs/otphp/src/TOTP.php34
-rw-r--r--vendor/spomky-labs/otphp/src/Url.php2
7 files changed, 31 insertions, 32 deletions
diff --git a/vendor/spomky-labs/otphp/README.md b/vendor/spomky-labs/otphp/README.md
index b23282ea1..542de6fbd 100644
--- a/vendor/spomky-labs/otphp/README.md
+++ b/vendor/spomky-labs/otphp/README.md
@@ -2,6 +2,7 @@ TOTP / HOTP library in PHP
==========================
![Build Status](https://github.com/spomky-labs/otphp/workflows/Integrate/badge.svg)
+![Build Status](https://github.com/spomky-labs/otphp/workflows/Infection/badge.svg)
[![Latest Stable Version](https://poser.pugx.org/spomky-labs/otphp/v/stable.png)](https://packagist.org/packages/spomky-labs/otphp)
[![Total Downloads](https://poser.pugx.org/spomky-labs/otphp/downloads.png)](https://packagist.org/packages/spomky-labs/otphp)
diff --git a/vendor/spomky-labs/otphp/composer.json b/vendor/spomky-labs/otphp/composer.json
index 080df371a..33901f793 100644
--- a/vendor/spomky-labs/otphp/composer.json
+++ b/vendor/spomky-labs/otphp/composer.json
@@ -22,17 +22,17 @@
},
"require-dev": {
"ekino/phpstan-banned-code": "^1.0",
- "infection/infection": "^0.26",
+ "infection/infection": "^0.26|^0.27|^0.28",
"php-parallel-lint/php-parallel-lint": "^1.3",
"phpstan/phpstan": "^1.0",
"phpstan/phpstan-deprecation-rules": "^1.0",
"phpstan/phpstan-phpunit": "^1.0",
"phpstan/phpstan-strict-rules": "^1.0",
- "phpunit/phpunit": "^9.5.26",
+ "phpunit/phpunit": "^9.5.26|^10.0|^11.0",
"qossmic/deptrac-shim": "^1.0",
- "rector/rector": "^0.15",
- "symfony/phpunit-bridge": "^6.1",
- "symplify/easy-coding-standard": "^11.0"
+ "rector/rector": "1.0",
+ "symfony/phpunit-bridge": "^6.1|^7.0",
+ "symplify/easy-coding-standard": "^12.0"
},
"autoload": {
"psr-4": { "OTPHP\\": "src/" }
diff --git a/vendor/spomky-labs/otphp/src/Factory.php b/vendor/spomky-labs/otphp/src/Factory.php
index 409d8751e..f58e8385c 100644
--- a/vendor/spomky-labs/otphp/src/Factory.php
+++ b/vendor/spomky-labs/otphp/src/Factory.php
@@ -4,10 +4,10 @@ declare(strict_types=1);
namespace OTPHP;
-use function assert;
-use function count;
use InvalidArgumentException;
use Throwable;
+use function assert;
+use function count;
/**
* This class is used to load OTP object from a provisioning Uri.
diff --git a/vendor/spomky-labs/otphp/src/OTP.php b/vendor/spomky-labs/otphp/src/OTP.php
index 4765d49eb..944ed8f62 100644
--- a/vendor/spomky-labs/otphp/src/OTP.php
+++ b/vendor/spomky-labs/otphp/src/OTP.php
@@ -4,14 +4,14 @@ declare(strict_types=1);
namespace OTPHP;
-use function assert;
-use function chr;
-use function count;
use Exception;
use InvalidArgumentException;
-use function is_string;
use ParagonIE\ConstantTime\Base32;
use RuntimeException;
+use function assert;
+use function chr;
+use function count;
+use function is_string;
use const STR_PAD_LEFT;
abstract class OTP implements OTPInterface
@@ -100,7 +100,7 @@ abstract class OTP implements OTPInterface
$this->hasColon($label) === false || throw new InvalidArgumentException('Label must not contain a colon.');
$options = [...$options, ...$this->getParameters()];
$this->filterOptions($options);
- $params = str_replace(['+', '%7E'], ['%20', '~'], http_build_query($options));
+ $params = str_replace(['+', '%7E'], ['%20', '~'], http_build_query($options, '', '&'));
return sprintf(
'otpauth://%s/%s?%s',
diff --git a/vendor/spomky-labs/otphp/src/ParameterTrait.php b/vendor/spomky-labs/otphp/src/ParameterTrait.php
index 3b2641e0c..dc92861c4 100644
--- a/vendor/spomky-labs/otphp/src/ParameterTrait.php
+++ b/vendor/spomky-labs/otphp/src/ParameterTrait.php
@@ -4,10 +4,10 @@ declare(strict_types=1);
namespace OTPHP;
+use InvalidArgumentException;
use function array_key_exists;
use function assert;
use function in_array;
-use InvalidArgumentException;
use function is_int;
use function is_string;
diff --git a/vendor/spomky-labs/otphp/src/TOTP.php b/vendor/spomky-labs/otphp/src/TOTP.php
index 3a7d72870..8a1cfeba1 100644
--- a/vendor/spomky-labs/otphp/src/TOTP.php
+++ b/vendor/spomky-labs/otphp/src/TOTP.php
@@ -4,8 +4,8 @@ declare(strict_types=1);
namespace OTPHP;
-use function assert;
use InvalidArgumentException;
+use function assert;
use function is_int;
/**
@@ -133,23 +133,21 @@ final class TOTP extends OTP implements TOTPInterface
*/
protected function getParameterMap(): array
{
- return array_merge(
- parent::getParameterMap(),
- [
- 'period' => static function ($value): int {
- (int) $value > 0 || throw new InvalidArgumentException('Period must be at least 1.');
-
- return (int) $value;
- },
- 'epoch' => static function ($value): int {
- (int) $value >= 0 || throw new InvalidArgumentException(
- 'Epoch must be greater than or equal to 0.'
- );
-
- return (int) $value;
- },
- ]
- );
+ return [
+ ...parent::getParameterMap(),
+ 'period' => static function ($value): int {
+ (int) $value > 0 || throw new InvalidArgumentException('Period must be at least 1.');
+
+ return (int) $value;
+ },
+ 'epoch' => static function ($value): int {
+ (int) $value >= 0 || throw new InvalidArgumentException(
+ 'Epoch must be greater than or equal to 0.'
+ );
+
+ return (int) $value;
+ },
+ ];
}
/**
diff --git a/vendor/spomky-labs/otphp/src/Url.php b/vendor/spomky-labs/otphp/src/Url.php
index 76919d27a..a97ca6821 100644
--- a/vendor/spomky-labs/otphp/src/Url.php
+++ b/vendor/spomky-labs/otphp/src/Url.php
@@ -4,8 +4,8 @@ declare(strict_types=1);
namespace OTPHP;
-use function array_key_exists;
use InvalidArgumentException;
+use function array_key_exists;
use function is_string;
/**