From 81aba738410bffe4dc7aa9ea3d8b07264bde63e8 Mon Sep 17 00:00:00 2001 From: Jorijn Schrijvershof Date: Fri, 19 Aug 2022 17:23:01 +0200 Subject: [PATCH 1/3] fixed a bug where in some cases the payee_node_key was wrong the signed message was wrongfully trimmed --- composer.lock | 688 +++++++++++--------- src/Encoder/PaymentRequestDecoder.php | 2 +- tests/Encoder/PaymentRequestDecoderTest.php | 21 +- 3 files changed, 399 insertions(+), 312 deletions(-) diff --git a/composer.lock b/composer.lock index 5fa805d..f1494fb 100644 --- a/composer.lock +++ b/composer.lock @@ -26,12 +26,12 @@ }, "type": "library", "autoload": { - "psr-4": { - "BitWasp\\Bech32\\": "src/" - }, "files": [ "src/bech32.php" - ] + ], + "psr-4": { + "BitWasp\\Bech32\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -102,23 +102,23 @@ }, { "name": "composer/semver", - "version": "3.2.6", + "version": "3.3.2", "source": { "type": "git", "url": "https://github.com/composer/semver.git", - "reference": "83e511e247de329283478496f7a1e114c9517506" + "reference": "3953f23262f2bff1919fc82183ad9acb13ff62c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/83e511e247de329283478496f7a1e114c9517506", - "reference": "83e511e247de329283478496f7a1e114c9517506", + "url": "https://api.github.com/repos/composer/semver/zipball/3953f23262f2bff1919fc82183ad9acb13ff62c9", + "reference": "3953f23262f2bff1919fc82183ad9acb13ff62c9", "shasum": "" }, "require": { "php": "^5.3.2 || ^7.0 || ^8.0" }, "require-dev": { - "phpstan/phpstan": "^0.12.54", + "phpstan/phpstan": "^1.4", "symfony/phpunit-bridge": "^4.2 || ^5" }, "type": "library", @@ -163,7 +163,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/semver/issues", - "source": "https://github.com/composer/semver/tree/3.2.6" + "source": "https://github.com/composer/semver/tree/3.3.2" }, "funding": [ { @@ -179,28 +179,28 @@ "type": "tidelift" } ], - "time": "2021-10-25T11:34:17+00:00" + "time": "2022-04-01T19:23:25+00:00" }, { "name": "fgrosse/phpasn1", - "version": "v2.3.0", + "version": "v2.4.0", "source": { "type": "git", "url": "https://github.com/fgrosse/PHPASN1.git", - "reference": "20299033c35f4300eb656e7e8e88cf52d1d6694e" + "reference": "eef488991d53e58e60c9554b09b1201ca5ba9296" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/fgrosse/PHPASN1/zipball/20299033c35f4300eb656e7e8e88cf52d1d6694e", - "reference": "20299033c35f4300eb656e7e8e88cf52d1d6694e", + "url": "https://api.github.com/repos/fgrosse/PHPASN1/zipball/eef488991d53e58e60c9554b09b1201ca5ba9296", + "reference": "eef488991d53e58e60c9554b09b1201ca5ba9296", "shasum": "" }, "require": { - "php": ">=7.0.0" + "php": "~7.1.0 || ~7.2.0 || ~7.3.0 || ~7.4.0 || ~8.0.0 || ~8.1.0" }, "require-dev": { - "phpunit/phpunit": "~6.3", - "satooshi/php-coveralls": "~2.0" + "php-coveralls/php-coveralls": "~2.0", + "phpunit/phpunit": "^6.3 || ^7.0 || ^8.0" }, "suggest": { "ext-bcmath": "BCmath is the fallback extension for big integer calculations", @@ -252,9 +252,9 @@ ], "support": { "issues": "https://github.com/fgrosse/PHPASN1/issues", - "source": "https://github.com/fgrosse/PHPASN1/tree/v2.3.0" + "source": "https://github.com/fgrosse/PHPASN1/tree/v2.4.0" }, - "time": "2021-04-24T19:01:55+00:00" + "time": "2021-12-11T12:41:06+00:00" }, { "name": "lastguest/murmurhash", @@ -467,12 +467,12 @@ "default-branch": true, "type": "library", "autoload": { - "psr-4": { - "BitWasp\\Bitcoin\\": "src/" - }, "files": [ "src/Script/functions.php" - ] + ], + "psr-4": { + "BitWasp\\Bitcoin\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -494,27 +494,100 @@ } ], "packages-dev": [ + { + "name": "composer/pcre", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/composer/pcre.git", + "reference": "67a32d7d6f9f560b726ab25a061b38ff3a80c560" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/pcre/zipball/67a32d7d6f9f560b726ab25a061b38ff3a80c560", + "reference": "67a32d7d6f9f560b726ab25a061b38ff3a80c560", + "shasum": "" + }, + "require": { + "php": "^5.3.2 || ^7.0 || ^8.0" + }, + "require-dev": { + "phpstan/phpstan": "^1.3", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\Pcre\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "PCRE wrapping library that offers type-safe preg_* replacements.", + "keywords": [ + "PCRE", + "preg", + "regex", + "regular expression" + ], + "support": { + "issues": "https://github.com/composer/pcre/issues", + "source": "https://github.com/composer/pcre/tree/1.0.1" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2022-01-21T20:24:37+00:00" + }, { "name": "composer/xdebug-handler", - "version": "2.0.2", + "version": "2.0.5", "source": { "type": "git", "url": "https://github.com/composer/xdebug-handler.git", - "reference": "84674dd3a7575ba617f5a76d7e9e29a7d3891339" + "reference": "9e36aeed4616366d2b690bdce11f71e9178c579a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/84674dd3a7575ba617f5a76d7e9e29a7d3891339", - "reference": "84674dd3a7575ba617f5a76d7e9e29a7d3891339", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/9e36aeed4616366d2b690bdce11f71e9178c579a", + "reference": "9e36aeed4616366d2b690bdce11f71e9178c579a", "shasum": "" }, "require": { + "composer/pcre": "^1", "php": "^5.3.2 || ^7.0 || ^8.0", "psr/log": "^1 || ^2 || ^3" }, "require-dev": { - "phpstan/phpstan": "^0.12.55", - "symfony/phpunit-bridge": "^4.2 || ^5" + "phpstan/phpstan": "^1.0", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^4.2 || ^5.0 || ^6.0" }, "type": "library", "autoload": { @@ -540,7 +613,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/xdebug-handler/issues", - "source": "https://github.com/composer/xdebug-handler/tree/2.0.2" + "source": "https://github.com/composer/xdebug-handler/tree/2.0.5" }, "funding": [ { @@ -556,20 +629,20 @@ "type": "tidelift" } ], - "time": "2021-07-31T17:03:58+00:00" + "time": "2022-02-24T20:20:32+00:00" }, { "name": "doctrine/annotations", - "version": "1.13.2", + "version": "1.13.3", "source": { "type": "git", "url": "https://github.com/doctrine/annotations.git", - "reference": "5b668aef16090008790395c02c893b1ba13f7e08" + "reference": "648b0343343565c4a056bfc8392201385e8d89f0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/5b668aef16090008790395c02c893b1ba13f7e08", - "reference": "5b668aef16090008790395c02c893b1ba13f7e08", + "url": "https://api.github.com/repos/doctrine/annotations/zipball/648b0343343565c4a056bfc8392201385e8d89f0", + "reference": "648b0343343565c4a056bfc8392201385e8d89f0", "shasum": "" }, "require": { @@ -581,9 +654,10 @@ "require-dev": { "doctrine/cache": "^1.11 || ^2.0", "doctrine/coding-standard": "^6.0 || ^8.1", - "phpstan/phpstan": "^0.12.20", + "phpstan/phpstan": "^1.4.10 || ^1.8.0", "phpunit/phpunit": "^7.5 || ^8.0 || ^9.1.5", - "symfony/cache": "^4.4 || ^5.2" + "symfony/cache": "^4.4 || ^5.2", + "vimeo/psalm": "^4.10" }, "type": "library", "autoload": { @@ -626,35 +700,36 @@ ], "support": { "issues": "https://github.com/doctrine/annotations/issues", - "source": "https://github.com/doctrine/annotations/tree/1.13.2" + "source": "https://github.com/doctrine/annotations/tree/1.13.3" }, - "time": "2021-08-05T19:00:23+00:00" + "time": "2022-07-02T10:48:51+00:00" }, { "name": "doctrine/instantiator", - "version": "1.4.0", + "version": "1.4.1", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b" + "reference": "10dcfce151b967d20fde1b34ae6640712c3891bc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/d56bf6102915de5702778fe20f2de3b2fe570b5b", - "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/10dcfce151b967d20fde1b34ae6640712c3891bc", + "reference": "10dcfce151b967d20fde1b34ae6640712c3891bc", "shasum": "" }, "require": { "php": "^7.1 || ^8.0" }, "require-dev": { - "doctrine/coding-standard": "^8.0", + "doctrine/coding-standard": "^9", "ext-pdo": "*", "ext-phar": "*", - "phpbench/phpbench": "^0.13 || 1.0.0-alpha2", - "phpstan/phpstan": "^0.12", - "phpstan/phpstan-phpunit": "^0.12", - "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0" + "phpbench/phpbench": "^0.16 || ^1", + "phpstan/phpstan": "^1.4", + "phpstan/phpstan-phpunit": "^1", + "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", + "vimeo/psalm": "^4.22" }, "type": "library", "autoload": { @@ -681,7 +756,7 @@ ], "support": { "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/1.4.0" + "source": "https://github.com/doctrine/instantiator/tree/1.4.1" }, "funding": [ { @@ -697,36 +772,32 @@ "type": "tidelift" } ], - "time": "2020-11-10T18:47:58+00:00" + "time": "2022-03-03T08:28:38+00:00" }, { "name": "doctrine/lexer", - "version": "1.2.1", + "version": "1.2.3", "source": { "type": "git", "url": "https://github.com/doctrine/lexer.git", - "reference": "e864bbf5904cb8f5bb334f99209b48018522f042" + "reference": "c268e882d4dbdd85e36e4ad69e02dc284f89d229" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/e864bbf5904cb8f5bb334f99209b48018522f042", - "reference": "e864bbf5904cb8f5bb334f99209b48018522f042", + "url": "https://api.github.com/repos/doctrine/lexer/zipball/c268e882d4dbdd85e36e4ad69e02dc284f89d229", + "reference": "c268e882d4dbdd85e36e4ad69e02dc284f89d229", "shasum": "" }, "require": { - "php": "^7.2 || ^8.0" + "php": "^7.1 || ^8.0" }, "require-dev": { - "doctrine/coding-standard": "^6.0", - "phpstan/phpstan": "^0.11.8", - "phpunit/phpunit": "^8.2" + "doctrine/coding-standard": "^9.0", + "phpstan/phpstan": "^1.3", + "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", + "vimeo/psalm": "^4.11" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, "autoload": { "psr-4": { "Doctrine\\Common\\Lexer\\": "lib/Doctrine/Common/Lexer" @@ -761,7 +832,7 @@ ], "support": { "issues": "https://github.com/doctrine/lexer/issues", - "source": "https://github.com/doctrine/lexer/tree/1.2.1" + "source": "https://github.com/doctrine/lexer/tree/1.2.3" }, "funding": [ { @@ -777,7 +848,7 @@ "type": "tidelift" } ], - "time": "2020-05-25T17:44:05+00:00" + "time": "2022-02-28T11:07:21+00:00" }, { "name": "friendsofphp/php-cs-fixer", @@ -890,37 +961,38 @@ }, { "name": "myclabs/deep-copy", - "version": "1.10.2", + "version": "1.11.0", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220" + "reference": "14daed4296fae74d9e3201d2c4925d1acb7aa614" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/776f831124e9c62e1a2c601ecc52e776d8bb7220", - "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/14daed4296fae74d9e3201d2c4925d1acb7aa614", + "reference": "14daed4296fae74d9e3201d2c4925d1acb7aa614", "shasum": "" }, "require": { "php": "^7.1 || ^8.0" }, - "replace": { - "myclabs/deep-copy": "self.version" + "conflict": { + "doctrine/collections": "<1.6.8", + "doctrine/common": "<2.13.3 || >=3,<3.2.2" }, "require-dev": { - "doctrine/collections": "^1.0", - "doctrine/common": "^2.6", - "phpunit/phpunit": "^7.1" + "doctrine/collections": "^1.6.8", + "doctrine/common": "^2.13.3 || ^3.2.2", + "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" }, "type": "library", "autoload": { - "psr-4": { - "DeepCopy\\": "src/DeepCopy/" - }, "files": [ "src/DeepCopy/deep_copy.php" - ] + ], + "psr-4": { + "DeepCopy\\": "src/DeepCopy/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -936,7 +1008,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.10.2" + "source": "https://github.com/myclabs/DeepCopy/tree/1.11.0" }, "funding": [ { @@ -944,20 +1016,20 @@ "type": "tidelift" } ], - "time": "2020-11-13T09:40:50+00:00" + "time": "2022-03-03T13:19:32+00:00" }, { "name": "nikic/php-parser", - "version": "v4.13.2", + "version": "v4.14.0", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "210577fe3cf7badcc5814d99455df46564f3c077" + "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/210577fe3cf7badcc5814d99455df46564f3c077", - "reference": "210577fe3cf7badcc5814d99455df46564f3c077", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/34bea19b6e03d8153165d8f30bba4c3be86184c1", + "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1", "shasum": "" }, "require": { @@ -998,9 +1070,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.13.2" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.14.0" }, - "time": "2021-11-30T19:35:32+00:00" + "time": "2022-05-31T20:59:12+00:00" }, { "name": "phar-io/manifest", @@ -1064,16 +1136,16 @@ }, { "name": "phar-io/version", - "version": "3.1.0", + "version": "3.2.1", "source": { "type": "git", "url": "https://github.com/phar-io/version.git", - "reference": "bae7c545bef187884426f042434e561ab1ddb182" + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/bae7c545bef187884426f042434e561ab1ddb182", - "reference": "bae7c545bef187884426f042434e561ab1ddb182", + "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", "shasum": "" }, "require": { @@ -1109,9 +1181,9 @@ "description": "Library for handling version information and constraints", "support": { "issues": "https://github.com/phar-io/version/issues", - "source": "https://github.com/phar-io/version/tree/3.1.0" + "source": "https://github.com/phar-io/version/tree/3.2.1" }, - "time": "2021-02-23T14:00:09+00:00" + "time": "2022-02-21T01:04:05+00:00" }, { "name": "php-cs-fixer/diff", @@ -1280,16 +1352,16 @@ }, { "name": "phpdocumentor/type-resolver", - "version": "1.5.1", + "version": "1.6.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "a12f7e301eb7258bb68acd89d4aefa05c2906cae" + "reference": "77a32518733312af16a44300404e945338981de3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/a12f7e301eb7258bb68acd89d4aefa05c2906cae", - "reference": "a12f7e301eb7258bb68acd89d4aefa05c2906cae", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/77a32518733312af16a44300404e945338981de3", + "reference": "77a32518733312af16a44300404e945338981de3", "shasum": "" }, "require": { @@ -1324,22 +1396,22 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.5.1" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.6.1" }, - "time": "2021-10-02T14:08:47+00:00" + "time": "2022-03-15T21:29:03+00:00" }, { "name": "phpspec/prophecy", - "version": "1.14.0", + "version": "v1.15.0", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e" + "reference": "bbcd7380b0ebf3961ee21409db7b38bc31d69a13" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e", - "reference": "d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/bbcd7380b0ebf3961ee21409db7b38bc31d69a13", + "reference": "bbcd7380b0ebf3961ee21409db7b38bc31d69a13", "shasum": "" }, "require": { @@ -1391,22 +1463,22 @@ ], "support": { "issues": "https://github.com/phpspec/prophecy/issues", - "source": "https://github.com/phpspec/prophecy/tree/1.14.0" + "source": "https://github.com/phpspec/prophecy/tree/v1.15.0" }, - "time": "2021-09-10T09:02:12+00:00" + "time": "2021-12-08T12:19:24+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "9.2.10", + "version": "9.2.15", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "d5850aaf931743067f4bfc1ae4cbd06468400687" + "reference": "2e9da11878c4202f97915c1cb4bb1ca318a63f5f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/d5850aaf931743067f4bfc1ae4cbd06468400687", - "reference": "d5850aaf931743067f4bfc1ae4cbd06468400687", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2e9da11878c4202f97915c1cb4bb1ca318a63f5f", + "reference": "2e9da11878c4202f97915c1cb4bb1ca318a63f5f", "shasum": "" }, "require": { @@ -1462,7 +1534,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.10" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.15" }, "funding": [ { @@ -1470,7 +1542,7 @@ "type": "github" } ], - "time": "2021-12-05T09:12:13+00:00" + "time": "2022-03-07T09:28:20+00:00" }, { "name": "phpunit/php-file-iterator", @@ -1715,16 +1787,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.10", + "version": "9.5.21", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "c814a05837f2edb0d1471d6e3f4ab3501ca3899a" + "reference": "0e32b76be457de00e83213528f6bb37e2a38fcb1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c814a05837f2edb0d1471d6e3f4ab3501ca3899a", - "reference": "c814a05837f2edb0d1471d6e3f4ab3501ca3899a", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/0e32b76be457de00e83213528f6bb37e2a38fcb1", + "reference": "0e32b76be457de00e83213528f6bb37e2a38fcb1", "shasum": "" }, "require": { @@ -1740,7 +1812,7 @@ "phar-io/version": "^3.0.2", "php": ">=7.3", "phpspec/prophecy": "^1.12.1", - "phpunit/php-code-coverage": "^9.2.7", + "phpunit/php-code-coverage": "^9.2.13", "phpunit/php-file-iterator": "^3.0.5", "phpunit/php-invoker": "^3.1.1", "phpunit/php-text-template": "^2.0.3", @@ -1754,11 +1826,10 @@ "sebastian/global-state": "^5.0.1", "sebastian/object-enumerator": "^4.0.3", "sebastian/resource-operations": "^3.0.3", - "sebastian/type": "^2.3.4", + "sebastian/type": "^3.0", "sebastian/version": "^3.0.2" }, "require-dev": { - "ext-pdo": "*", "phpspec/prophecy-phpunit": "^2.0.1" }, "suggest": { @@ -1775,11 +1846,11 @@ } }, "autoload": { - "classmap": [ - "src/" - ], "files": [ "src/Framework/Assert/Functions.php" + ], + "classmap": [ + "src/" ] }, "notification-url": "https://packagist.org/downloads/", @@ -1802,11 +1873,11 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.10" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.21" }, "funding": [ { - "url": "https://phpunit.de/donate.html", + "url": "https://phpunit.de/sponsors.html", "type": "custom" }, { @@ -1814,7 +1885,7 @@ "type": "github" } ], - "time": "2021-09-25T07:38:51+00:00" + "time": "2022-06-19T12:14:25+00:00" }, { "name": "psr/cache", @@ -2384,16 +2455,16 @@ }, { "name": "sebastian/environment", - "version": "5.1.3", + "version": "5.1.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "388b6ced16caa751030f6a69e588299fa09200ac" + "reference": "1b5dff7bb151a4db11d49d90e5408e4e938270f7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", - "reference": "388b6ced16caa751030f6a69e588299fa09200ac", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/1b5dff7bb151a4db11d49d90e5408e4e938270f7", + "reference": "1b5dff7bb151a4db11d49d90e5408e4e938270f7", "shasum": "" }, "require": { @@ -2435,7 +2506,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/5.1.3" + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.4" }, "funding": [ { @@ -2443,7 +2514,7 @@ "type": "github" } ], - "time": "2020-09-28T05:52:38+00:00" + "time": "2022-04-03T09:37:03+00:00" }, { "name": "sebastian/exporter", @@ -2524,16 +2595,16 @@ }, { "name": "sebastian/global-state", - "version": "5.0.3", + "version": "5.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "23bd5951f7ff26f12d4e3242864df3e08dec4e49" + "reference": "0ca8db5a5fc9c8646244e629625ac486fa286bf2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/23bd5951f7ff26f12d4e3242864df3e08dec4e49", - "reference": "23bd5951f7ff26f12d4e3242864df3e08dec4e49", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/0ca8db5a5fc9c8646244e629625ac486fa286bf2", + "reference": "0ca8db5a5fc9c8646244e629625ac486fa286bf2", "shasum": "" }, "require": { @@ -2576,7 +2647,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.3" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.5" }, "funding": [ { @@ -2584,7 +2655,7 @@ "type": "github" } ], - "time": "2021-06-11T13:31:12+00:00" + "time": "2022-02-14T08:28:10+00:00" }, { "name": "sebastian/lines-of-code", @@ -2875,28 +2946,28 @@ }, { "name": "sebastian/type", - "version": "2.3.4", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "b8cd8a1c753c90bc1a0f5372170e3e489136f914" + "reference": "b233b84bc4465aff7b57cf1c4bc75c86d00d6dad" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/b8cd8a1c753c90bc1a0f5372170e3e489136f914", - "reference": "b8cd8a1c753c90bc1a0f5372170e3e489136f914", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/b233b84bc4465aff7b57cf1c4bc75c86d00d6dad", + "reference": "b233b84bc4465aff7b57cf1c4bc75c86d00d6dad", "shasum": "" }, "require": { "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^9.5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.3-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -2919,7 +2990,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/2.3.4" + "source": "https://github.com/sebastianbergmann/type/tree/3.0.0" }, "funding": [ { @@ -2927,7 +2998,7 @@ "type": "github" } ], - "time": "2021-06-15T12:49:02+00:00" + "time": "2022-03-15T09:54:48+00:00" }, { "name": "sebastian/version", @@ -2984,23 +3055,23 @@ }, { "name": "symfony/console", - "version": "v5.4.0", + "version": "v5.4.11", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "ec3661faca1d110d6c307e124b44f99ac54179e3" + "reference": "535846c7ee6bc4dd027ca0d93220601456734b10" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/ec3661faca1d110d6c307e124b44f99ac54179e3", - "reference": "ec3661faca1d110d6c307e124b44f99ac54179e3", + "url": "https://api.github.com/repos/symfony/console/zipball/535846c7ee6bc4dd027ca0d93220601456734b10", + "reference": "535846c7ee6bc4dd027ca0d93220601456734b10", "shasum": "" }, "require": { "php": ">=7.2.5", "symfony/deprecation-contracts": "^2.1|^3", "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php73": "^1.8", + "symfony/polyfill-php73": "^1.9", "symfony/polyfill-php80": "^1.16", "symfony/service-contracts": "^1.1|^2|^3", "symfony/string": "^5.1|^6.0" @@ -3063,7 +3134,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v5.4.0" + "source": "https://github.com/symfony/console/tree/v5.4.11" }, "funding": [ { @@ -3079,29 +3150,29 @@ "type": "tidelift" } ], - "time": "2021-11-29T15:30:56+00:00" + "time": "2022-07-22T10:42:43+00:00" }, { "name": "symfony/deprecation-contracts", - "version": "v3.0.0", + "version": "v3.1.1", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "c726b64c1ccfe2896cb7df2e1331c357ad1c8ced" + "reference": "07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/c726b64c1ccfe2896cb7df2e1331c357ad1c8ced", - "reference": "c726b64c1ccfe2896cb7df2e1331c357ad1c8ced", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918", + "reference": "07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918", "shasum": "" }, "require": { - "php": ">=8.0.2" + "php": ">=8.1" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "3.1-dev" }, "thanks": { "name": "symfony/contracts", @@ -3130,7 +3201,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v3.0.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.1.1" }, "funding": [ { @@ -3146,20 +3217,20 @@ "type": "tidelift" } ], - "time": "2021-11-01T23:48:49+00:00" + "time": "2022-02-25T11:15:52+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v5.4.0", + "version": "v5.4.9", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "27d39ae126352b9fa3be5e196ccf4617897be3eb" + "reference": "8e6ce1cc0279e3ff3c8ff0f43813bc88d21ca1bc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/27d39ae126352b9fa3be5e196ccf4617897be3eb", - "reference": "27d39ae126352b9fa3be5e196ccf4617897be3eb", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/8e6ce1cc0279e3ff3c8ff0f43813bc88d21ca1bc", + "reference": "8e6ce1cc0279e3ff3c8ff0f43813bc88d21ca1bc", "shasum": "" }, "require": { @@ -3215,7 +3286,7 @@ "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/event-dispatcher/tree/v5.4.0" + "source": "https://github.com/symfony/event-dispatcher/tree/v5.4.9" }, "funding": [ { @@ -3231,24 +3302,24 @@ "type": "tidelift" } ], - "time": "2021-11-23T10:19:22+00:00" + "time": "2022-05-05T16:45:39+00:00" }, { "name": "symfony/event-dispatcher-contracts", - "version": "v3.0.0", + "version": "v3.1.1", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher-contracts.git", - "reference": "aa5422287b75594b90ee9cd807caf8f0df491385" + "reference": "02ff5eea2f453731cfbc6bc215e456b781480448" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/aa5422287b75594b90ee9cd807caf8f0df491385", - "reference": "aa5422287b75594b90ee9cd807caf8f0df491385", + "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/02ff5eea2f453731cfbc6bc215e456b781480448", + "reference": "02ff5eea2f453731cfbc6bc215e456b781480448", "shasum": "" }, "require": { - "php": ">=8.0.2", + "php": ">=8.1", "psr/event-dispatcher": "^1" }, "suggest": { @@ -3257,7 +3328,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "3.1-dev" }, "thanks": { "name": "symfony/contracts", @@ -3294,7 +3365,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.0.0" + "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.1.1" }, "funding": [ { @@ -3310,20 +3381,20 @@ "type": "tidelift" } ], - "time": "2021-07-15T12:33:35+00:00" + "time": "2022-02-25T11:15:52+00:00" }, { "name": "symfony/filesystem", - "version": "v5.4.0", + "version": "v5.4.11", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "731f917dc31edcffec2c6a777f3698c33bea8f01" + "reference": "6699fb0228d1bc35b12aed6dd5e7455457609ddd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/731f917dc31edcffec2c6a777f3698c33bea8f01", - "reference": "731f917dc31edcffec2c6a777f3698c33bea8f01", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/6699fb0228d1bc35b12aed6dd5e7455457609ddd", + "reference": "6699fb0228d1bc35b12aed6dd5e7455457609ddd", "shasum": "" }, "require": { @@ -3358,7 +3429,7 @@ "description": "Provides basic utilities for the filesystem", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/filesystem/tree/v5.4.0" + "source": "https://github.com/symfony/filesystem/tree/v5.4.11" }, "funding": [ { @@ -3374,20 +3445,20 @@ "type": "tidelift" } ], - "time": "2021-10-28T13:39:27+00:00" + "time": "2022-07-20T13:00:38+00:00" }, { "name": "symfony/finder", - "version": "v5.4.0", + "version": "v5.4.11", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "d2f29dac98e96a98be467627bd49c2efb1bc2590" + "reference": "7872a66f57caffa2916a584db1aa7f12adc76f8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/d2f29dac98e96a98be467627bd49c2efb1bc2590", - "reference": "d2f29dac98e96a98be467627bd49c2efb1bc2590", + "url": "https://api.github.com/repos/symfony/finder/zipball/7872a66f57caffa2916a584db1aa7f12adc76f8c", + "reference": "7872a66f57caffa2916a584db1aa7f12adc76f8c", "shasum": "" }, "require": { @@ -3421,7 +3492,7 @@ "description": "Finds files and directories via an intuitive fluent interface", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/finder/tree/v5.4.0" + "source": "https://github.com/symfony/finder/tree/v5.4.11" }, "funding": [ { @@ -3437,20 +3508,20 @@ "type": "tidelift" } ], - "time": "2021-11-28T15:25:38+00:00" + "time": "2022-07-29T07:37:50+00:00" }, { "name": "symfony/options-resolver", - "version": "v5.4.0", + "version": "v5.4.11", "source": { "type": "git", "url": "https://github.com/symfony/options-resolver.git", - "reference": "b0fb78576487af19c500aaddb269fd36701d4847" + "reference": "54f14e36aa73cb8f7261d7686691fd4d75ea2690" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/options-resolver/zipball/b0fb78576487af19c500aaddb269fd36701d4847", - "reference": "b0fb78576487af19c500aaddb269fd36701d4847", + "url": "https://api.github.com/repos/symfony/options-resolver/zipball/54f14e36aa73cb8f7261d7686691fd4d75ea2690", + "reference": "54f14e36aa73cb8f7261d7686691fd4d75ea2690", "shasum": "" }, "require": { @@ -3490,7 +3561,7 @@ "options" ], "support": { - "source": "https://github.com/symfony/options-resolver/tree/v5.4.0" + "source": "https://github.com/symfony/options-resolver/tree/v5.4.11" }, "funding": [ { @@ -3506,32 +3577,35 @@ "type": "tidelift" } ], - "time": "2021-11-23T10:19:22+00:00" + "time": "2022-07-20T13:00:38+00:00" }, { "name": "symfony/polyfill-ctype", - "version": "v1.23.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce" + "reference": "6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/46cd95797e9df938fdd2b03693b5fca5e64b01ce", - "reference": "46cd95797e9df938fdd2b03693b5fca5e64b01ce", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4", + "reference": "6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4", "shasum": "" }, "require": { "php": ">=7.1" }, + "provide": { + "ext-ctype": "*" + }, "suggest": { "ext-ctype": "For best performance" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3539,12 +3613,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -3569,7 +3643,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.23.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.26.0" }, "funding": [ { @@ -3585,20 +3659,20 @@ "type": "tidelift" } ], - "time": "2021-02-19T12:13:01+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.23.1", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", - "reference": "16880ba9c5ebe3642d1995ab866db29270b36535" + "reference": "433d05519ce6990bf3530fba6957499d327395c2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/16880ba9c5ebe3642d1995ab866db29270b36535", - "reference": "16880ba9c5ebe3642d1995ab866db29270b36535", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/433d05519ce6990bf3530fba6957499d327395c2", + "reference": "433d05519ce6990bf3530fba6957499d327395c2", "shasum": "" }, "require": { @@ -3610,7 +3684,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3618,12 +3692,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Intl\\Grapheme\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Grapheme\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -3650,7 +3724,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.23.1" + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.26.0" }, "funding": [ { @@ -3666,20 +3740,20 @@ "type": "tidelift" } ], - "time": "2021-05-27T12:26:48+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.23.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", - "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8" + "reference": "219aa369ceff116e673852dce47c3a41794c14bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/8590a5f561694770bdcd3f9b5c69dde6945028e8", - "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/219aa369ceff116e673852dce47c3a41794c14bd", + "reference": "219aa369ceff116e673852dce47c3a41794c14bd", "shasum": "" }, "require": { @@ -3691,7 +3765,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3699,12 +3773,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Intl\\Normalizer\\": "" - }, "files": [ "bootstrap.php" ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Normalizer\\": "" + }, "classmap": [ "Resources/stubs" ] @@ -3734,7 +3808,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.23.0" + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.26.0" }, "funding": [ { @@ -3750,32 +3824,35 @@ "type": "tidelift" } ], - "time": "2021-02-19T12:13:01+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.23.1", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "9174a3d80210dca8daa7f31fec659150bbeabfc6" + "reference": "9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9174a3d80210dca8daa7f31fec659150bbeabfc6", - "reference": "9174a3d80210dca8daa7f31fec659150bbeabfc6", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e", + "reference": "9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e", "shasum": "" }, "require": { "php": ">=7.1" }, + "provide": { + "ext-mbstring": "*" + }, "suggest": { "ext-mbstring": "For best performance" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3783,12 +3860,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -3814,7 +3891,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.23.1" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.26.0" }, "funding": [ { @@ -3830,7 +3907,7 @@ "type": "tidelift" } ], - "time": "2021-05-27T12:26:48+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-php70", @@ -3902,16 +3979,16 @@ }, { "name": "symfony/polyfill-php72", - "version": "v1.23.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php72.git", - "reference": "9a142215a36a3888e30d0a9eeea9766764e96976" + "reference": "bf44a9fd41feaac72b074de600314a93e2ae78e2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/9a142215a36a3888e30d0a9eeea9766764e96976", - "reference": "9a142215a36a3888e30d0a9eeea9766764e96976", + "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/bf44a9fd41feaac72b074de600314a93e2ae78e2", + "reference": "bf44a9fd41feaac72b074de600314a93e2ae78e2", "shasum": "" }, "require": { @@ -3920,7 +3997,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3928,12 +4005,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php72\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Php72\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -3958,7 +4035,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php72/tree/v1.23.0" + "source": "https://github.com/symfony/polyfill-php72/tree/v1.26.0" }, "funding": [ { @@ -3974,20 +4051,20 @@ "type": "tidelift" } ], - "time": "2021-05-27T09:17:38+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-php73", - "version": "v1.23.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "fba8933c384d6476ab14fb7b8526e5287ca7e010" + "reference": "e440d35fa0286f77fb45b79a03fedbeda9307e85" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/fba8933c384d6476ab14fb7b8526e5287ca7e010", - "reference": "fba8933c384d6476ab14fb7b8526e5287ca7e010", + "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/e440d35fa0286f77fb45b79a03fedbeda9307e85", + "reference": "e440d35fa0286f77fb45b79a03fedbeda9307e85", "shasum": "" }, "require": { @@ -3996,7 +4073,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4004,12 +4081,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php73\\": "" - }, "files": [ "bootstrap.php" ], + "psr-4": { + "Symfony\\Polyfill\\Php73\\": "" + }, "classmap": [ "Resources/stubs" ] @@ -4037,7 +4114,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.23.0" + "source": "https://github.com/symfony/polyfill-php73/tree/v1.26.0" }, "funding": [ { @@ -4053,20 +4130,20 @@ "type": "tidelift" } ], - "time": "2021-02-19T12:13:01+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-php80", - "version": "v1.23.1", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "1100343ed1a92e3a38f9ae122fc0eb21602547be" + "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/1100343ed1a92e3a38f9ae122fc0eb21602547be", - "reference": "1100343ed1a92e3a38f9ae122fc0eb21602547be", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/cfa0ae98841b9e461207c13ab093d76b0fa7bace", + "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace", "shasum": "" }, "require": { @@ -4075,7 +4152,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4083,12 +4160,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php80\\": "" - }, "files": [ "bootstrap.php" ], + "psr-4": { + "Symfony\\Polyfill\\Php80\\": "" + }, "classmap": [ "Resources/stubs" ] @@ -4120,7 +4197,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.23.1" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.26.0" }, "funding": [ { @@ -4136,20 +4213,20 @@ "type": "tidelift" } ], - "time": "2021-07-28T13:41:28+00:00" + "time": "2022-05-10T07:21:04+00:00" }, { "name": "symfony/process", - "version": "v5.4.0", + "version": "v5.4.11", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "5be20b3830f726e019162b26223110c8f47cf274" + "reference": "6e75fe6874cbc7e4773d049616ab450eff537bf1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/5be20b3830f726e019162b26223110c8f47cf274", - "reference": "5be20b3830f726e019162b26223110c8f47cf274", + "url": "https://api.github.com/repos/symfony/process/zipball/6e75fe6874cbc7e4773d049616ab450eff537bf1", + "reference": "6e75fe6874cbc7e4773d049616ab450eff537bf1", "shasum": "" }, "require": { @@ -4182,7 +4259,7 @@ "description": "Executes commands in sub-processes", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/process/tree/v5.4.0" + "source": "https://github.com/symfony/process/tree/v5.4.11" }, "funding": [ { @@ -4198,24 +4275,24 @@ "type": "tidelift" } ], - "time": "2021-11-28T15:25:38+00:00" + "time": "2022-06-27T16:58:25+00:00" }, { "name": "symfony/service-contracts", - "version": "v3.0.0", + "version": "v3.1.1", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "36715ebf9fb9db73db0cb24263c79077c6fe8603" + "reference": "925e713fe8fcacf6bc05e936edd8dd5441a21239" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/36715ebf9fb9db73db0cb24263c79077c6fe8603", - "reference": "36715ebf9fb9db73db0cb24263c79077c6fe8603", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/925e713fe8fcacf6bc05e936edd8dd5441a21239", + "reference": "925e713fe8fcacf6bc05e936edd8dd5441a21239", "shasum": "" }, "require": { - "php": ">=8.0.2", + "php": ">=8.1", "psr/container": "^2.0" }, "conflict": { @@ -4227,7 +4304,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "3.1-dev" }, "thanks": { "name": "symfony/contracts", @@ -4237,7 +4314,10 @@ "autoload": { "psr-4": { "Symfony\\Contracts\\Service\\": "" - } + }, + "exclude-from-classmap": [ + "/Test/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -4264,7 +4344,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/v3.0.0" + "source": "https://github.com/symfony/service-contracts/tree/v3.1.1" }, "funding": [ { @@ -4280,20 +4360,20 @@ "type": "tidelift" } ], - "time": "2021-11-04T17:53:12+00:00" + "time": "2022-05-30T19:18:58+00:00" }, { "name": "symfony/stopwatch", - "version": "v5.4.0", + "version": "v5.4.5", "source": { "type": "git", "url": "https://github.com/symfony/stopwatch.git", - "reference": "208ef96122bfed82a8f3a61458a07113a08bdcfe" + "reference": "4d04b5c24f3c9a1a168a131f6cbe297155bc0d30" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/stopwatch/zipball/208ef96122bfed82a8f3a61458a07113a08bdcfe", - "reference": "208ef96122bfed82a8f3a61458a07113a08bdcfe", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/4d04b5c24f3c9a1a168a131f6cbe297155bc0d30", + "reference": "4d04b5c24f3c9a1a168a131f6cbe297155bc0d30", "shasum": "" }, "require": { @@ -4326,7 +4406,7 @@ "description": "Provides a way to profile code", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/stopwatch/tree/v5.4.0" + "source": "https://github.com/symfony/stopwatch/tree/v5.4.5" }, "funding": [ { @@ -4342,24 +4422,24 @@ "type": "tidelift" } ], - "time": "2021-11-23T10:19:22+00:00" + "time": "2022-02-18T16:06:09+00:00" }, { "name": "symfony/string", - "version": "v6.0.0", + "version": "v6.1.3", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "ba727797426af0f587f4800566300bdc0cda0777" + "reference": "f35241f45c30bcd9046af2bb200a7086f70e1d6b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/ba727797426af0f587f4800566300bdc0cda0777", - "reference": "ba727797426af0f587f4800566300bdc0cda0777", + "url": "https://api.github.com/repos/symfony/string/zipball/f35241f45c30bcd9046af2bb200a7086f70e1d6b", + "reference": "f35241f45c30bcd9046af2bb200a7086f70e1d6b", "shasum": "" }, "require": { - "php": ">=8.0.2", + "php": ">=8.1", "symfony/polyfill-ctype": "~1.8", "symfony/polyfill-intl-grapheme": "~1.0", "symfony/polyfill-intl-normalizer": "~1.0", @@ -4376,12 +4456,12 @@ }, "type": "library", "autoload": { - "psr-4": { - "Symfony\\Component\\String\\": "" - }, "files": [ "Resources/functions.php" ], + "psr-4": { + "Symfony\\Component\\String\\": "" + }, "exclude-from-classmap": [ "/Tests/" ] @@ -4411,7 +4491,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v6.0.0" + "source": "https://github.com/symfony/string/tree/v6.1.3" }, "funding": [ { @@ -4427,7 +4507,7 @@ "type": "tidelift" } ], - "time": "2021-10-29T07:35:21+00:00" + "time": "2022-07-27T15:50:51+00:00" }, { "name": "theseer/tokenizer", @@ -4481,21 +4561,21 @@ }, { "name": "webmozart/assert", - "version": "1.10.0", + "version": "1.11.0", "source": { "type": "git", "url": "https://github.com/webmozarts/assert.git", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25" + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozarts/assert/zipball/6964c76c7804814a842473e0c8fd15bab0f18e25", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/11cb2199493b2f8a3b53e7f19068fc6aac760991", + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991", "shasum": "" }, "require": { - "php": "^7.2 || ^8.0", - "symfony/polyfill-ctype": "^1.8" + "ext-ctype": "*", + "php": "^7.2 || ^8.0" }, "conflict": { "phpstan/phpstan": "<0.12.20", @@ -4533,9 +4613,9 @@ ], "support": { "issues": "https://github.com/webmozarts/assert/issues", - "source": "https://github.com/webmozarts/assert/tree/1.10.0" + "source": "https://github.com/webmozarts/assert/tree/1.11.0" }, - "time": "2021-03-09T10:59:23+00:00" + "time": "2022-06-03T18:03:27+00:00" } ], "aliases": [], diff --git a/src/Encoder/PaymentRequestDecoder.php b/src/Encoder/PaymentRequestDecoder.php index 5fb4d4e..04b13f3 100644 --- a/src/Encoder/PaymentRequestDecoder.php +++ b/src/Encoder/PaymentRequestDecoder.php @@ -160,7 +160,7 @@ public function decode(string $paymentRequest): array $toSign = Buffertools::concat( new Buffer($prefix), - $this->wordsToBuffer($wordsWithoutSignature), + $this->wordsToBuffer($wordsWithoutSignature, false), ); $payReqHash = Hash::sha256($toSign); diff --git a/tests/Encoder/PaymentRequestDecoderTest.php b/tests/Encoder/PaymentRequestDecoderTest.php index 70c1447..0374cf5 100644 --- a/tests/Encoder/PaymentRequestDecoderTest.php +++ b/tests/Encoder/PaymentRequestDecoderTest.php @@ -60,11 +60,11 @@ public function providerOfSuccessScenarios(): array 'Please send $3 for a cup of coffee to the same peer, within one minute' => [ 'lnbc2500u1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqdq5xysxxatsyp3k7enxv4jsxqzpuaztrnwngzn3kdzw5hydlzf03qdgm2hdq27cqv3agm2awhz5se903vruatfhq77w3ls4evs3ch9zw97j25emudupq63nyw24cg27h2rspfj9srp', [ - '_payment_request_hash' => '3c3aa1c9fba327079f59e744d328700c6f3f6f418ce4db4037b0867ae6f46425', + '_payment_request_hash' => '3cd6ef07744040556e01be64f68fd9e1565fb47d78c42308b1ee005aca5a0d86', '_message_to_sign' => '6c6e626332353030750b25fe64410d00004080c1014181c20240004080c1014181c20240004080c1014181c202404081a0a189031bab81031b7b33332b2818020f', 'prefix' => 'lnbc2500u', 'milli_satoshis' => 250000000, - 'payee_node_key' => '0307bfecdf775fe29aafe6446e223d9068aa27e267c74f1923223483ba7e654175', + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'recovery_flag' => 1, 'satoshis' => 250000, 'signature' => 'e89639ba6814e36689d4b91bf125f10351b55da057b00647a8dabaeb8a90c95f160f9d5a6e0f79d1fc2b964238b944e2fa4aa677c6f020d466472ab842bd750e', @@ -82,11 +82,11 @@ public function providerOfSuccessScenarios(): array 'Please send 0.0025 BTC for a cup of nonsense (ナンセンス 1杯) to the same peer, within one minute' => [ 'lnbc2500u1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqdpquwpc4curk03c9wlrswe78q4eyqc7d8d0xqzpuyk0sg5g70me25alkluzd2x62aysf2pyy8edtjeevuv4p2d5p76r4zkmneet7uvyakky2zr4cusd45tftc9c5fh0nnqpnl2jfll544esqchsrny', [ - '_payment_request_hash' => '9d96ed9ddd522deeee4884219ead16a1b5269015b0bb9bd17f553fb224656cd8', + '_payment_request_hash' => '197a3061f4f333d86669b8054592222b488f3c657a9d3e74f34f586fb3e7931c', '_message_to_sign' => '6c6e626332353030750b25fe64410d00004080c1014181c20240004080c1014181c20240004080c1014181c202404081a1071c1c571c1d9f1c15df1c1d9f1c15c9018f34ed798020', 'prefix' => 'lnbc2500u', 'milli_satoshis' => 250000000, - 'payee_node_key' => '0207f0a34ef228239f9d5fa92c24e5bbaabf25ea0183f5b482651c09db2e9ec6b1', + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'recovery_flag' => 0, 'satoshis' => 250000, 'signature' => '259f04511e7ef2aa77f6ff04d51b4ae9209504843e5ab9672ce32a153681f687515b73ce57ee309db588a10eb8e41b5a2d2bc17144ddf398033faa49ffe95ae6', @@ -104,7 +104,7 @@ public function providerOfSuccessScenarios(): array 'Now send $24 for an entire list of things (hashed)' => [ 'lnbc20m1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqhp58yjmdan79s6qqdhdzgynm4zwqd5d7xmw5fk98klysy043l2ahrqscc6gd6ql3jrc5yzme8v4ntcewwz5cnw92tz0pc8qcuufvq7khhr8wpald05e92xw006sq94mg8v2ndf4sefvf9sygkshp5zfem29trqq2yxxz7', [ - 'payee_node_key' => '021fe79f22a93c57805f621304a2b0d834805ed6d4cedceaf3fad0f89b72ef9906', + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'recovery_flag' => 0, 'satoshis' => 2000000, 'signature' => 'c63486e81f8c878a105bc9d959af1973854c4dc552c4f0e0e0c7389603d6bdc67707bf6be992a8ce7bf50016bb41d8a9b5358652c4960445a170d049ced4558c', @@ -117,7 +117,7 @@ public function providerOfSuccessScenarios(): array 'The same, on testnet, with a fallback address mk2QpYatsKicvFVuTAQLBryyccRXMUaGHP' => [ 'lntb20m1pvjluezhp58yjmdan79s6qqdhdzgynm4zwqd5d7xmw5fk98klysy043l2ahrqspp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqfpp3x9et2e20v6pu37c5d9vax37wxq72un98kmzzhznpurw9sgl2v0nklu2g4d0keph5t7tj9tcqd8rexnd07ux4uv2cjvcqwaxgj7v4uwn5wmypjd5n69z2xm3xgksg28nwht7f6zspwp3f9t', [ - 'payee_node_key' => '03288e6c22381c44e425a1611197b0f3164cc7aeb719844cebd6f239731f7f51df', + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'recovery_flag' => 1, 'satoshis' => 2000000, 'signature' => 'b6c42b8a61e0dc5823ea63e76ff148ab5f6c86f45f9722af0069c7934daff70d5e315893300774c897995e3a7476c8193693d144a36e2645a0851e6ebafc9d0a', @@ -138,6 +138,7 @@ public function providerOfSuccessScenarios(): array 'On mainnet, with fallback address 1RustyRX2oai4EYYDpQGWvEL62BBGqN9T with extra routing info to go via nodes 029e03a901b85534ff1e92c43c74431f7ce72046060fcf7a95c37e148f78c77255 then 039e03a901b85534ff1e92c43c74431f7ce72046060fcf7a95c37e148f78c77255' => [ 'lnbc20m1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqhp58yjmdan79s6qqdhdzgynm4zwqd5d7xmw5fk98klysy043l2ahrqsfpp3qjmp7lwpagxun9pygexvgpjdc4jdj85fr9yq20q82gphp2nflc7jtzrcazrra7wwgzxqc8u7754cdlpfrmccae92qgzqvzq2ps8pqqqqqqpqqqqq9qqqvpeuqafqxu92d8lr6fvg0r5gv0heeeqgcrqlnm6jhphu9y00rrhy4grqszsvpcgpy9qqqqqqgqqqqq7qqzqj9n4evl6mr5aj9f58zp6fyjzup6ywn3x6sk8akg5v4tgn2q8g4fhx05wf6juaxu9760yp46454gpg5mtzgerlzezqcqvjnhjh8z3g2qqdhhwkj', [ + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'satoshis' => 2000000, 'tags' => [ 'fallback_address' => [ @@ -167,6 +168,7 @@ public function providerOfSuccessScenarios(): array 'On mainnet, with fallback (P2SH) address 3EktnHQD7RiAE6uzMj2ZifT9YgRrkSgzQX' => [ 'lnbc20m1pvjluezhp58yjmdan79s6qqdhdzgynm4zwqd5d7xmw5fk98klysy043l2ahrqspp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqfppj3a24vwu6r8ejrss3axul8rxldph2q7z9kmrgvr7xlaqm47apw3d48zm203kzcq357a4ls9al2ea73r8jcceyjtya6fu5wzzpe50zrge6ulk4nvjcpxlekvmxl6qcs9j3tz0469gq5g658y', [ + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'tags' => [ 'fallback_address' => [ 'code' => 18, @@ -176,9 +178,10 @@ public function providerOfSuccessScenarios(): array ], ], ], - 'On mainnet, with fallback (P2WPKH) address bc1qw508d6qejxtdg4y5r3zarvary0c5xw7kv8f3t4' => [ + 'On mainnet, with fallback (P2WPKH) addressp bc1qw508d6qejxtdg4y5r3zarvary0c5xw7kv8f3t4' => [ 'lnbc20m1pvjluezhp58yjmdan79s6qqdhdzgynm4zwqd5d7xmw5fk98klysy043l2ahrqspp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqfppqw508d6qejxtdg4y5r3zarvary0c5xw7kepvrhrm9s57hejg0p662ur5j5cr03890fa7k2pypgttmh4897d3raaq85a293e9jpuqwl0rnfuwzam7yr8e690nd2ypcq9hlkdwdvycqa0qza8', [ + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'tags' => [ 'fallback_address' => [ 'code' => 0, @@ -191,6 +194,7 @@ public function providerOfSuccessScenarios(): array 'On mainnet, with fallback (P2WSH) address bc1qrp33g0q5c5txsp9arysrx4k6zdkfs4nce4xj0gdcccefvpysxf3qccfmv3' => [ 'lnbc20m1pvjluezhp58yjmdan79s6qqdhdzgynm4zwqd5d7xmw5fk98klysy043l2ahrqspp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqfp4qrp33g0q5c5txsp9arysrx4k6zdkfs4nce4xj0gdcccefvpysxf3q28j0v3rwgy9pvjnd48ee2pl8xrpxysd5g44td63g6xcjcu003j3qe8878hluqlvl3km8rm92f5stamd3jw763n3hck0ct7p8wwj463cql26ava', [ + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'tags' => [ 'fallback_address' => [ 'code' => 0, @@ -204,6 +208,7 @@ public function providerOfSuccessScenarios(): array 'lnbc9678785340p1pwmna7lpp5gc3xfm08u9qy06djf8dfflhugl6p7lgza6dsjxq454gxhj9t7a0sd8dgfkx7cmtwd68yetpd5s9xar0wfjn5gpc8qhrsdfq24f5ggrxdaezqsnvda3kkum5wfjkzmfqf3jkgem9wgsyuctwdus9xgrcyqcjcgpzgfskx6eqf9hzqnteypzxz7fzypfhg6trddjhygrcyqezcgpzfysywmm5ypxxjemgw3hxjmn8yptk7untd9hxwg3q2d6xjcmtv4ezq7pqxgsxzmnyyqcjqmt0wfjjq6t5v4khxxqyjw5qcqp2rzjq0gxwkzc8w6323m55m4jyxcjwmy7stt9hwkwe2qxmy8zpsgg7jcuwz87fcqqeuqqqyqqqqlgqqqqn3qq9qn07ytgrxxzad9hc4xt3mawjjt8znfv8xzscs7007v9gh9j569lencxa8xeujzkxs0uamak9aln6ez02uunw6rd2ht2sqe4hz8thcdagpleym0j', [ 'milli_satoshis' => 967878534, + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'satoshis' => 967878, 'tags' => [ 'description' => 'Blockstream Store: 88.85 USD for Blockstream Ledger Nano S x 1, "Back In My Day" Sticker x 2, "I Got Lightning Working" Sticker x 2 and 1 more items', @@ -228,6 +233,7 @@ public function providerOfSuccessScenarios(): array 'Please send $30 for coffee beans to the same peer, which supports features 9, 15 and 99, using secret 0x1111111111111111111111111111111111111111111111111111111111111111' => [ 'lnbc25m1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqdq5vdhkven9v5sxyetpdeessp5zyg3zyg3zyg3zyg3zyg3zyg3zyg3zyg3zyg3zyg3zyg3zyg3zygs9q5sqqqqqqqqqqqqqqqpqsq67gye39hfg3zd8rgc80k32tvy9xk2xunwm5lzexnvpx6fd77en8qaq424dxgt56cag2dpt359k3ssyhetktkpqh24jqnjyw6uqd08sgptq44qu', [ + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'tags' => [ 'secret' => '1111111111111111111111111111111111111111111111111111111111111111', '5' => 'unknown1sqqqqqqqqqqqqqqqpqsqn2lwct', @@ -237,6 +243,7 @@ public function providerOfSuccessScenarios(): array 'Same, but all upper case.' => [ 'LNBC25M1PVJLUEZPP5QQQSYQCYQ5RQWZQFQQQSYQCYQ5RQWZQFQQQSYQCYQ5RQWZQFQYPQDQ5VDHKVEN9V5SXYETPDEESSP5ZYG3ZYG3ZYG3ZYG3ZYG3ZYG3ZYG3ZYG3ZYG3ZYG3ZYG3ZYG3ZYGS9Q5SQQQQQQQQQQQQQQQPQSQ67GYE39HFG3ZD8RGC80K32TVY9XK2XUNWM5LZEXNVPX6FD77EN8QAQ424DXGT56CAG2DPT359K3SSYHETKTKPQH24JQNJYW6UQD08SGPTQ44QU', [ + 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', 'tags' => [ 'secret' => '1111111111111111111111111111111111111111111111111111111111111111', '5' => 'unknown1sqqqqqqqqqqqqqqqpqsqn2lwct', From 00c46d764f52770aa0e8bd5bc0402892a77e0568 Mon Sep 17 00:00:00 2001 From: Jorijn Schrijvershof Date: Fri, 19 Aug 2022 17:27:49 +0200 Subject: [PATCH 2/3] last few chars got lost somehow --- tests/Encoder/PaymentRequestDecoderTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/Encoder/PaymentRequestDecoderTest.php b/tests/Encoder/PaymentRequestDecoderTest.php index 0374cf5..91c9d6c 100644 --- a/tests/Encoder/PaymentRequestDecoderTest.php +++ b/tests/Encoder/PaymentRequestDecoderTest.php @@ -61,7 +61,7 @@ public function providerOfSuccessScenarios(): array 'lnbc2500u1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqdq5xysxxatsyp3k7enxv4jsxqzpuaztrnwngzn3kdzw5hydlzf03qdgm2hdq27cqv3agm2awhz5se903vruatfhq77w3ls4evs3ch9zw97j25emudupq63nyw24cg27h2rspfj9srp', [ '_payment_request_hash' => '3cd6ef07744040556e01be64f68fd9e1565fb47d78c42308b1ee005aca5a0d86', - '_message_to_sign' => '6c6e626332353030750b25fe64410d00004080c1014181c20240004080c1014181c20240004080c1014181c202404081a0a189031bab81031b7b33332b2818020f', + '_message_to_sign' => '6c6e626332353030750b25fe64410d00004080c1014181c20240004080c1014181c20240004080c1014181c202404081a0a189031bab81031b7b33332b2818020f00', 'prefix' => 'lnbc2500u', 'milli_satoshis' => 250000000, 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', @@ -83,7 +83,7 @@ public function providerOfSuccessScenarios(): array 'lnbc2500u1pvjluezpp5qqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqqqsyqcyq5rqwzqfqypqdpquwpc4curk03c9wlrswe78q4eyqc7d8d0xqzpuyk0sg5g70me25alkluzd2x62aysf2pyy8edtjeevuv4p2d5p76r4zkmneet7uvyakky2zr4cusd45tftc9c5fh0nnqpnl2jfll544esqchsrny', [ '_payment_request_hash' => '197a3061f4f333d86669b8054592222b488f3c657a9d3e74f34f586fb3e7931c', - '_message_to_sign' => '6c6e626332353030750b25fe64410d00004080c1014181c20240004080c1014181c20240004080c1014181c202404081a1071c1c571c1d9f1c15df1c1d9f1c15c9018f34ed798020', + '_message_to_sign' => '6c6e626332353030750b25fe64410d00004080c1014181c20240004080c1014181c20240004080c1014181c202404081a1071c1c571c1d9f1c15df1c1d9f1c15c9018f34ed798020f0', 'prefix' => 'lnbc2500u', 'milli_satoshis' => 250000000, 'payee_node_key' => '03e7156ae33b0a208d0744199163177e909e80176e55d97a2f221ede0f934dd9ad', From 5da09b7fd42776d041c88e5d3bf33e7f2a5963c3 Mon Sep 17 00:00:00 2001 From: Jorijn Schrijvershof Date: Sat, 20 Aug 2022 07:38:13 +0200 Subject: [PATCH 3/3] bump min. version php to 7.4, upgrade php-cs-fixer --- .github/workflows/test.yml | 2 +- .php-cs-fixer.php | 32 + .php_cs | 17 - composer.json | 4 +- composer.lock | 559 ++++++------------ .../decode_payment_request_into_array.php | 9 + ...mount_description_from_payment_request.php | 9 + ..._fallback_address_from_payment_request.php | 9 + ...et_milli_satoshis_from_payment_request.php | 9 + .../get_routing_info_from_payment_request.php | 9 + examples/parse_blank_payment_request.php | 9 + ...ment_request_with_expiration_timestamp.php | 9 + examples/view_all_available_attributes.php | 9 + .../view_timestamp_from_payment_request.php | 9 + src/Encoder/PaymentRequestDecoder.php | 16 +- src/Exception/InvalidAmountException.php | 9 + .../InvalidPaymentRequestException.php | 9 + .../PaymentRequestDecodeException.php | 9 + ...DoesNotMatchPayeePubkeyDecodeException.php | 9 + .../SignatureIncorrectOrMissingException.php | 9 + .../UnableToDecodeBech32Exception.php | 9 + .../UnableToDenormalizeException.php | 9 + ...UnknownFallbackAddressVersionException.php | 9 + .../UnknownNetworkVersionException.php | 9 + .../UnrecoverableSignatureException.php | 9 + src/Model/FallbackAddress.php | 11 + src/Model/PaymentRequest.php | 20 + src/Model/RoutingInfo.php | 13 + src/Model/Tag.php | 18 + src/Model/TagInterface.php | 9 + src/Model/UnknownTag.php | 10 + src/Normalizer/DenormalizerTrait.php | 9 + .../FallbackAddressDenormalizer.php | 9 + src/Normalizer/PaymentRequestDenormalizer.php | 9 + src/Normalizer/RoutingInfoDenormalizer.php | 9 + src/Normalizer/TagDenormalizer.php | 10 + tests/Encoder/PaymentRequestDecoderTest.php | 9 + tests/Model/PaymentRequestTest.php | 9 + tests/Normalizer/DenormalizerTraitTest.php | 9 + .../FallbackAddressDenormalizerTest.php | 9 + .../PaymentRequestDenormalizerTest.php | 10 + .../RoutingInfoDenormalizerTest.php | 9 + tests/Normalizer/TagDenormalizerTest.php | 11 + 43 files changed, 579 insertions(+), 415 deletions(-) create mode 100644 .php-cs-fixer.php delete mode 100644 .php_cs diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 009bd27..65f1b80 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - php-version: [ 7.3, 7.4, 8.0 ] + php-version: [ 7.4, 8.0, 8.1 ] steps: - name: Git checkout diff --git a/.php-cs-fixer.php b/.php-cs-fixer.php new file mode 100644 index 0000000..46b4535 --- /dev/null +++ b/.php-cs-fixer.php @@ -0,0 +1,32 @@ + + +This source file is subject to the MIT license that is bundled +with this source code in the file LICENSE. +EOF; + +$finder = PhpCsFixer\Finder::create() + ->in(__DIR__) + ->exclude('vendor'); + +return (new PhpCsFixer\Config()) + ->setRiskyAllowed(true) + ->setRules( + [ + '@Symfony' => true, + '@Symfony:risky' => true, + '@PhpCsFixer' => true, + '@PhpCsFixer:risky' => true, + 'array_syntax' => ['syntax' => 'short'], + 'general_phpdoc_annotation_remove' => ['annotations' => ['expectedDeprecation']], + 'header_comment' => ['header' => $header], + 'method_argument_space' => [ + 'on_multiline' => 'ensure_fully_multiline', + ], + ] + ) + ->setFinder($finder); diff --git a/.php_cs b/.php_cs deleted file mode 100644 index b3ebcb1..0000000 --- a/.php_cs +++ /dev/null @@ -1,17 +0,0 @@ -in(__DIR__) - ->exclude('vendor') -; - -return PhpCsFixer\Config::create() - ->setRules([ - '@Symfony' => true, - '@Symfony:risky' => true, - '@PhpCsFixer' => true, - '@PhpCsFixer:risky' => true, - 'array_syntax' => ['syntax' => 'short'], - ]) - ->setFinder($finder) -; diff --git a/composer.json b/composer.json index 625c601..d536a97 100644 --- a/composer.json +++ b/composer.json @@ -23,7 +23,7 @@ "prefer-stable": true, "minimum-stability": "stable", "require-dev": { - "friendsofphp/php-cs-fixer": "^2.17", + "friendsofphp/php-cs-fixer": "^3.10", "phpunit/phpunit": "^9" }, "autoload": { @@ -37,7 +37,7 @@ } }, "require": { - "php": "^7.3|^8.0", + "php": "^7.4|^8.0", "ext-bcmath": "*", "ext-gmp": "*", "bitwasp/bech32": "^0.0.1", diff --git a/composer.lock b/composer.lock index f1494fb..b1f55e4 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "6aeb268fa29e43e578af3b9e0e40ba5c", + "content-hash": "97cfe4b4896759e5c1fb0b6557f2943a", "packages": [ { "name": "bitwasp/bech32", @@ -496,30 +496,30 @@ "packages-dev": [ { "name": "composer/pcre", - "version": "1.0.1", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/composer/pcre.git", - "reference": "67a32d7d6f9f560b726ab25a061b38ff3a80c560" + "reference": "e300eb6c535192decd27a85bc72a9290f0d6b3bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/pcre/zipball/67a32d7d6f9f560b726ab25a061b38ff3a80c560", - "reference": "67a32d7d6f9f560b726ab25a061b38ff3a80c560", + "url": "https://api.github.com/repos/composer/pcre/zipball/e300eb6c535192decd27a85bc72a9290f0d6b3bd", + "reference": "e300eb6c535192decd27a85bc72a9290f0d6b3bd", "shasum": "" }, "require": { - "php": "^5.3.2 || ^7.0 || ^8.0" + "php": "^7.4 || ^8.0" }, "require-dev": { "phpstan/phpstan": "^1.3", "phpstan/phpstan-strict-rules": "^1.1", - "symfony/phpunit-bridge": "^4.2 || ^5" + "symfony/phpunit-bridge": "^5" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "1.x-dev" + "dev-main": "3.x-dev" } }, "autoload": { @@ -547,7 +547,7 @@ ], "support": { "issues": "https://github.com/composer/pcre/issues", - "source": "https://github.com/composer/pcre/tree/1.0.1" + "source": "https://github.com/composer/pcre/tree/3.0.0" }, "funding": [ { @@ -563,31 +563,31 @@ "type": "tidelift" } ], - "time": "2022-01-21T20:24:37+00:00" + "time": "2022-02-25T20:21:48+00:00" }, { "name": "composer/xdebug-handler", - "version": "2.0.5", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/composer/xdebug-handler.git", - "reference": "9e36aeed4616366d2b690bdce11f71e9178c579a" + "reference": "ced299686f41dce890debac69273b47ffe98a40c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/9e36aeed4616366d2b690bdce11f71e9178c579a", - "reference": "9e36aeed4616366d2b690bdce11f71e9178c579a", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/ced299686f41dce890debac69273b47ffe98a40c", + "reference": "ced299686f41dce890debac69273b47ffe98a40c", "shasum": "" }, "require": { - "composer/pcre": "^1", - "php": "^5.3.2 || ^7.0 || ^8.0", + "composer/pcre": "^1 || ^2 || ^3", + "php": "^7.2.5 || ^8.0", "psr/log": "^1 || ^2 || ^3" }, "require-dev": { "phpstan/phpstan": "^1.0", "phpstan/phpstan-strict-rules": "^1.1", - "symfony/phpunit-bridge": "^4.2 || ^5.0 || ^6.0" + "symfony/phpunit-bridge": "^6.0" }, "type": "library", "autoload": { @@ -613,7 +613,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/xdebug-handler/issues", - "source": "https://github.com/composer/xdebug-handler/tree/2.0.5" + "source": "https://github.com/composer/xdebug-handler/tree/3.0.3" }, "funding": [ { @@ -629,7 +629,7 @@ "type": "tidelift" } ], - "time": "2022-02-24T20:20:32+00:00" + "time": "2022-02-25T21:32:43+00:00" }, { "name": "doctrine/annotations", @@ -852,85 +852,65 @@ }, { "name": "friendsofphp/php-cs-fixer", - "version": "v2.19.3", + "version": "v3.10.0", "source": { "type": "git", "url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git", - "reference": "75ac86f33fab4714ea5a39a396784d83ae3b5ed8" + "reference": "76d7da666e66d83a1dc27a9d1c625c80cc4ac1fe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/75ac86f33fab4714ea5a39a396784d83ae3b5ed8", - "reference": "75ac86f33fab4714ea5a39a396784d83ae3b5ed8", + "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/76d7da666e66d83a1dc27a9d1c625c80cc4ac1fe", + "reference": "76d7da666e66d83a1dc27a9d1c625c80cc4ac1fe", "shasum": "" }, "require": { - "composer/semver": "^1.4 || ^2.0 || ^3.0", - "composer/xdebug-handler": "^1.2 || ^2.0", - "doctrine/annotations": "^1.2", + "composer/semver": "^3.2", + "composer/xdebug-handler": "^3.0.3", + "doctrine/annotations": "^1.13", "ext-json": "*", "ext-tokenizer": "*", - "php": "^5.6 || ^7.0 || ^8.0", - "php-cs-fixer/diff": "^1.3", - "symfony/console": "^3.4.43 || ^4.1.6 || ^5.0", - "symfony/event-dispatcher": "^3.0 || ^4.0 || ^5.0", - "symfony/filesystem": "^3.0 || ^4.0 || ^5.0", - "symfony/finder": "^3.0 || ^4.0 || ^5.0", - "symfony/options-resolver": "^3.0 || ^4.0 || ^5.0", - "symfony/polyfill-php70": "^1.0", - "symfony/polyfill-php72": "^1.4", - "symfony/process": "^3.0 || ^4.0 || ^5.0", - "symfony/stopwatch": "^3.0 || ^4.0 || ^5.0" + "php": "^7.4 || ^8.0", + "sebastian/diff": "^4.0", + "symfony/console": "^5.4 || ^6.0", + "symfony/event-dispatcher": "^5.4 || ^6.0", + "symfony/filesystem": "^5.4 || ^6.0", + "symfony/finder": "^5.4 || ^6.0", + "symfony/options-resolver": "^5.4 || ^6.0", + "symfony/polyfill-mbstring": "^1.23", + "symfony/polyfill-php80": "^1.25", + "symfony/polyfill-php81": "^1.25", + "symfony/process": "^5.4 || ^6.0", + "symfony/stopwatch": "^5.4 || ^6.0" }, "require-dev": { - "justinrainbow/json-schema": "^5.0", - "keradus/cli-executor": "^1.4", - "mikey179/vfsstream": "^1.6", - "php-coveralls/php-coveralls": "^2.4.2", - "php-cs-fixer/accessible-object": "^1.0", + "justinrainbow/json-schema": "^5.2", + "keradus/cli-executor": "^1.5", + "mikey179/vfsstream": "^1.6.10", + "php-coveralls/php-coveralls": "^2.5.2", + "php-cs-fixer/accessible-object": "^1.1", "php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.2", "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.2.1", - "phpspec/prophecy-phpunit": "^1.1 || ^2.0", - "phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.13 || ^9.5", + "phpspec/prophecy": "^1.15", + "phpspec/prophecy-phpunit": "^2.0", + "phpunit/phpunit": "^9.5", "phpunitgoodpractices/polyfill": "^1.5", "phpunitgoodpractices/traits": "^1.9.1", - "sanmai/phpunit-legacy-adapter": "^6.4 || ^8.2.1", - "symfony/phpunit-bridge": "^5.2.1", - "symfony/yaml": "^3.0 || ^4.0 || ^5.0" + "symfony/phpunit-bridge": "^6.0", + "symfony/yaml": "^5.4 || ^6.0" }, "suggest": { "ext-dom": "For handling output formats in XML", - "ext-mbstring": "For handling non-UTF8 characters.", - "php-cs-fixer/phpunit-constraint-isidenticalstring": "For IsIdenticalString constraint.", - "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "For XmlMatchesXsd constraint.", - "symfony/polyfill-mbstring": "When enabling `ext-mbstring` is not possible." + "ext-mbstring": "For handling non-UTF8 characters." }, "bin": [ "php-cs-fixer" ], "type": "application", - "extra": { - "branch-alias": { - "dev-master": "2.19-dev" - } - }, "autoload": { "psr-4": { "PhpCsFixer\\": "src/" - }, - "classmap": [ - "tests/Test/AbstractFixerTestCase.php", - "tests/Test/AbstractIntegrationCaseFactory.php", - "tests/Test/AbstractIntegrationTestCase.php", - "tests/Test/Assert/AssertTokensTrait.php", - "tests/Test/IntegrationCase.php", - "tests/Test/IntegrationCaseFactory.php", - "tests/Test/IntegrationCaseFactoryInterface.php", - "tests/Test/InternalIntegrationCaseFactory.php", - "tests/Test/IsIdenticalConstraint.php", - "tests/Test/TokensWithObservedTransformers.php", - "tests/TestCase.php" - ] + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -949,7 +929,7 @@ "description": "A tool to automatically fix PHP code style", "support": { "issues": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues", - "source": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/tree/v2.19.3" + "source": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/tree/v3.10.0" }, "funding": [ { @@ -957,7 +937,7 @@ "type": "github" } ], - "time": "2021-11-15T17:17:55+00:00" + "time": "2022-08-17T22:13:10+00:00" }, { "name": "myclabs/deep-copy", @@ -1185,61 +1165,6 @@ }, "time": "2022-02-21T01:04:05+00:00" }, - { - "name": "php-cs-fixer/diff", - "version": "v1.3.1", - "source": { - "type": "git", - "url": "https://github.com/PHP-CS-Fixer/diff.git", - "reference": "dbd31aeb251639ac0b9e7e29405c1441907f5759" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/dbd31aeb251639ac0b9e7e29405c1441907f5759", - "reference": "dbd31aeb251639ac0b9e7e29405c1441907f5759", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0 || ^8.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.7.23 || ^6.4.3 || ^7.0", - "symfony/process": "^3.3" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - }, - { - "name": "SpacePossum" - } - ], - "description": "sebastian/diff v2 backport support for PHP5.6", - "homepage": "https://github.com/PHP-CS-Fixer", - "keywords": [ - "diff" - ], - "support": { - "issues": "https://github.com/PHP-CS-Fixer/diff/issues", - "source": "https://github.com/PHP-CS-Fixer/diff/tree/v1.3.1" - }, - "time": "2020-10-14T08:39:05+00:00" - }, { "name": "phpdocumentor/reflection-common", "version": "2.2.0", @@ -1469,23 +1394,23 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.15", + "version": "9.2.16", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "2e9da11878c4202f97915c1cb4bb1ca318a63f5f" + "reference": "2593003befdcc10db5e213f9f28814f5aa8ac073" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2e9da11878c4202f97915c1cb4bb1ca318a63f5f", - "reference": "2e9da11878c4202f97915c1cb4bb1ca318a63f5f", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2593003befdcc10db5e213f9f28814f5aa8ac073", + "reference": "2593003befdcc10db5e213f9f28814f5aa8ac073", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.13.0", + "nikic/php-parser": "^4.14", "php": ">=7.3", "phpunit/php-file-iterator": "^3.0.3", "phpunit/php-text-template": "^2.0.2", @@ -1534,7 +1459,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.15" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.16" }, "funding": [ { @@ -1542,7 +1467,7 @@ "type": "github" } ], - "time": "2022-03-07T09:28:20+00:00" + "time": "2022-08-20T05:26:47+00:00" }, { "name": "phpunit/php-file-iterator", @@ -2041,16 +1966,16 @@ }, { "name": "psr/log", - "version": "2.0.0", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/php-fig/log.git", - "reference": "ef29f6d262798707a9edd554e2b82517ef3a9376" + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/ef29f6d262798707a9edd554e2b82517ef3a9376", - "reference": "ef29f6d262798707a9edd554e2b82517ef3a9376", + "url": "https://api.github.com/repos/php-fig/log/zipball/fe5ea303b0887d5caefd3d431c3e61ad47037001", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001", "shasum": "" }, "require": { @@ -2059,7 +1984,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.x-dev" } }, "autoload": { @@ -2085,9 +2010,9 @@ "psr-3" ], "support": { - "source": "https://github.com/php-fig/log/tree/2.0.0" + "source": "https://github.com/php-fig/log/tree/3.0.0" }, - "time": "2021-07-14T16:41:46+00:00" + "time": "2021-07-14T16:46:02+00:00" }, { "name": "sebastian/cli-parser", @@ -3055,46 +2980,43 @@ }, { "name": "symfony/console", - "version": "v5.4.11", + "version": "v6.1.3", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "535846c7ee6bc4dd027ca0d93220601456734b10" + "reference": "43fcb5c5966b43c56bcfa481368d90d748936ab8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/535846c7ee6bc4dd027ca0d93220601456734b10", - "reference": "535846c7ee6bc4dd027ca0d93220601456734b10", + "url": "https://api.github.com/repos/symfony/console/zipball/43fcb5c5966b43c56bcfa481368d90d748936ab8", + "reference": "43fcb5c5966b43c56bcfa481368d90d748936ab8", "shasum": "" }, "require": { - "php": ">=7.2.5", + "php": ">=8.1", "symfony/deprecation-contracts": "^2.1|^3", "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php73": "^1.9", - "symfony/polyfill-php80": "^1.16", "symfony/service-contracts": "^1.1|^2|^3", - "symfony/string": "^5.1|^6.0" + "symfony/string": "^5.4|^6.0" }, "conflict": { - "psr/log": ">=3", - "symfony/dependency-injection": "<4.4", - "symfony/dotenv": "<5.1", - "symfony/event-dispatcher": "<4.4", - "symfony/lock": "<4.4", - "symfony/process": "<4.4" + "symfony/dependency-injection": "<5.4", + "symfony/dotenv": "<5.4", + "symfony/event-dispatcher": "<5.4", + "symfony/lock": "<5.4", + "symfony/process": "<5.4" }, "provide": { - "psr/log-implementation": "1.0|2.0" + "psr/log-implementation": "1.0|2.0|3.0" }, "require-dev": { - "psr/log": "^1|^2", - "symfony/config": "^4.4|^5.0|^6.0", - "symfony/dependency-injection": "^4.4|^5.0|^6.0", - "symfony/event-dispatcher": "^4.4|^5.0|^6.0", - "symfony/lock": "^4.4|^5.0|^6.0", - "symfony/process": "^4.4|^5.0|^6.0", - "symfony/var-dumper": "^4.4|^5.0|^6.0" + "psr/log": "^1|^2|^3", + "symfony/config": "^5.4|^6.0", + "symfony/dependency-injection": "^5.4|^6.0", + "symfony/event-dispatcher": "^5.4|^6.0", + "symfony/lock": "^5.4|^6.0", + "symfony/process": "^5.4|^6.0", + "symfony/var-dumper": "^5.4|^6.0" }, "suggest": { "psr/log": "For using the console logger", @@ -3134,7 +3056,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v5.4.11" + "source": "https://github.com/symfony/console/tree/v6.1.3" }, "funding": [ { @@ -3150,7 +3072,7 @@ "type": "tidelift" } ], - "time": "2022-07-22T10:42:43+00:00" + "time": "2022-07-22T14:17:57+00:00" }, { "name": "symfony/deprecation-contracts", @@ -3221,40 +3143,38 @@ }, { "name": "symfony/event-dispatcher", - "version": "v5.4.9", + "version": "v6.1.0", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "8e6ce1cc0279e3ff3c8ff0f43813bc88d21ca1bc" + "reference": "a0449a7ad7daa0f7c0acd508259f80544ab5a347" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/8e6ce1cc0279e3ff3c8ff0f43813bc88d21ca1bc", - "reference": "8e6ce1cc0279e3ff3c8ff0f43813bc88d21ca1bc", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/a0449a7ad7daa0f7c0acd508259f80544ab5a347", + "reference": "a0449a7ad7daa0f7c0acd508259f80544ab5a347", "shasum": "" }, "require": { - "php": ">=7.2.5", - "symfony/deprecation-contracts": "^2.1|^3", - "symfony/event-dispatcher-contracts": "^2|^3", - "symfony/polyfill-php80": "^1.16" + "php": ">=8.1", + "symfony/event-dispatcher-contracts": "^2|^3" }, "conflict": { - "symfony/dependency-injection": "<4.4" + "symfony/dependency-injection": "<5.4" }, "provide": { "psr/event-dispatcher-implementation": "1.0", - "symfony/event-dispatcher-implementation": "2.0" + "symfony/event-dispatcher-implementation": "2.0|3.0" }, "require-dev": { "psr/log": "^1|^2|^3", - "symfony/config": "^4.4|^5.0|^6.0", - "symfony/dependency-injection": "^4.4|^5.0|^6.0", - "symfony/error-handler": "^4.4|^5.0|^6.0", - "symfony/expression-language": "^4.4|^5.0|^6.0", - "symfony/http-foundation": "^4.4|^5.0|^6.0", + "symfony/config": "^5.4|^6.0", + "symfony/dependency-injection": "^5.4|^6.0", + "symfony/error-handler": "^5.4|^6.0", + "symfony/expression-language": "^5.4|^6.0", + "symfony/http-foundation": "^5.4|^6.0", "symfony/service-contracts": "^1.1|^2|^3", - "symfony/stopwatch": "^4.4|^5.0|^6.0" + "symfony/stopwatch": "^5.4|^6.0" }, "suggest": { "symfony/dependency-injection": "", @@ -3286,7 +3206,7 @@ "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/event-dispatcher/tree/v5.4.9" + "source": "https://github.com/symfony/event-dispatcher/tree/v6.1.0" }, "funding": [ { @@ -3302,7 +3222,7 @@ "type": "tidelift" } ], - "time": "2022-05-05T16:45:39+00:00" + "time": "2022-05-05T16:51:07+00:00" }, { "name": "symfony/event-dispatcher-contracts", @@ -3385,23 +3305,22 @@ }, { "name": "symfony/filesystem", - "version": "v5.4.11", + "version": "v6.1.3", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "6699fb0228d1bc35b12aed6dd5e7455457609ddd" + "reference": "c780e677cddda78417fa5187a7c6cd2f21110db9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/6699fb0228d1bc35b12aed6dd5e7455457609ddd", - "reference": "6699fb0228d1bc35b12aed6dd5e7455457609ddd", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/c780e677cddda78417fa5187a7c6cd2f21110db9", + "reference": "c780e677cddda78417fa5187a7c6cd2f21110db9", "shasum": "" }, "require": { - "php": ">=7.2.5", + "php": ">=8.1", "symfony/polyfill-ctype": "~1.8", - "symfony/polyfill-mbstring": "~1.8", - "symfony/polyfill-php80": "^1.16" + "symfony/polyfill-mbstring": "~1.8" }, "type": "library", "autoload": { @@ -3429,7 +3348,7 @@ "description": "Provides basic utilities for the filesystem", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/filesystem/tree/v5.4.11" + "source": "https://github.com/symfony/filesystem/tree/v6.1.3" }, "funding": [ { @@ -3445,26 +3364,27 @@ "type": "tidelift" } ], - "time": "2022-07-20T13:00:38+00:00" + "time": "2022-07-20T14:45:06+00:00" }, { "name": "symfony/finder", - "version": "v5.4.11", + "version": "v6.1.3", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "7872a66f57caffa2916a584db1aa7f12adc76f8c" + "reference": "39696bff2c2970b3779a5cac7bf9f0b88fc2b709" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/7872a66f57caffa2916a584db1aa7f12adc76f8c", - "reference": "7872a66f57caffa2916a584db1aa7f12adc76f8c", + "url": "https://api.github.com/repos/symfony/finder/zipball/39696bff2c2970b3779a5cac7bf9f0b88fc2b709", + "reference": "39696bff2c2970b3779a5cac7bf9f0b88fc2b709", "shasum": "" }, "require": { - "php": ">=7.2.5", - "symfony/deprecation-contracts": "^2.1|^3", - "symfony/polyfill-php80": "^1.16" + "php": ">=8.1" + }, + "require-dev": { + "symfony/filesystem": "^6.0" }, "type": "library", "autoload": { @@ -3492,7 +3412,7 @@ "description": "Finds files and directories via an intuitive fluent interface", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/finder/tree/v5.4.11" + "source": "https://github.com/symfony/finder/tree/v6.1.3" }, "funding": [ { @@ -3508,27 +3428,25 @@ "type": "tidelift" } ], - "time": "2022-07-29T07:37:50+00:00" + "time": "2022-07-29T07:42:06+00:00" }, { "name": "symfony/options-resolver", - "version": "v5.4.11", + "version": "v6.1.0", "source": { "type": "git", "url": "https://github.com/symfony/options-resolver.git", - "reference": "54f14e36aa73cb8f7261d7686691fd4d75ea2690" + "reference": "a3016f5442e28386ded73c43a32a5b68586dd1c4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/options-resolver/zipball/54f14e36aa73cb8f7261d7686691fd4d75ea2690", - "reference": "54f14e36aa73cb8f7261d7686691fd4d75ea2690", + "url": "https://api.github.com/repos/symfony/options-resolver/zipball/a3016f5442e28386ded73c43a32a5b68586dd1c4", + "reference": "a3016f5442e28386ded73c43a32a5b68586dd1c4", "shasum": "" }, "require": { - "php": ">=7.2.5", - "symfony/deprecation-contracts": "^2.1|^3", - "symfony/polyfill-php73": "~1.0", - "symfony/polyfill-php80": "^1.16" + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.1|^3" }, "type": "library", "autoload": { @@ -3561,7 +3479,7 @@ "options" ], "support": { - "source": "https://github.com/symfony/options-resolver/tree/v5.4.11" + "source": "https://github.com/symfony/options-resolver/tree/v6.1.0" }, "funding": [ { @@ -3577,7 +3495,7 @@ "type": "tidelift" } ], - "time": "2022-07-20T13:00:38+00:00" + "time": "2022-02-25T11:15:52+00:00" }, { "name": "symfony/polyfill-ctype", @@ -3910,161 +3828,17 @@ "time": "2022-05-24T11:49:31+00:00" }, { - "name": "symfony/polyfill-php70", - "version": "v1.20.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php70.git", - "reference": "5f03a781d984aae42cebd18e7912fa80f02ee644" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php70/zipball/5f03a781d984aae42cebd18e7912fa80f02ee644", - "reference": "5f03a781d984aae42cebd18e7912fa80f02ee644", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "type": "metapackage", - "extra": { - "branch-alias": { - "dev-main": "1.20-dev" - }, - "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 7.0+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "support": { - "source": "https://github.com/symfony/polyfill-php70/tree/v1.20.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2020-10-23T14:02:19+00:00" - }, - { - "name": "symfony/polyfill-php72", - "version": "v1.26.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php72.git", - "reference": "bf44a9fd41feaac72b074de600314a93e2ae78e2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/bf44a9fd41feaac72b074de600314a93e2ae78e2", - "reference": "bf44a9fd41feaac72b074de600314a93e2ae78e2", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "1.26-dev" - }, - "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" - } - }, - "autoload": { - "files": [ - "bootstrap.php" - ], - "psr-4": { - "Symfony\\Polyfill\\Php72\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "support": { - "source": "https://github.com/symfony/polyfill-php72/tree/v1.26.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2022-05-24T11:49:31+00:00" - }, - { - "name": "symfony/polyfill-php73", + "name": "symfony/polyfill-php80", "version": "v1.26.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "e440d35fa0286f77fb45b79a03fedbeda9307e85" + "url": "https://github.com/symfony/polyfill-php80.git", + "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/e440d35fa0286f77fb45b79a03fedbeda9307e85", - "reference": "e440d35fa0286f77fb45b79a03fedbeda9307e85", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/cfa0ae98841b9e461207c13ab093d76b0fa7bace", + "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace", "shasum": "" }, "require": { @@ -4085,7 +3859,7 @@ "bootstrap.php" ], "psr-4": { - "Symfony\\Polyfill\\Php73\\": "" + "Symfony\\Polyfill\\Php80\\": "" }, "classmap": [ "Resources/stubs" @@ -4096,6 +3870,10 @@ "MIT" ], "authors": [ + { + "name": "Ion Bazan", + "email": "ion.bazan@gmail.com" + }, { "name": "Nicolas Grekas", "email": "p@tchwork.com" @@ -4105,7 +3883,7 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill backporting some PHP 7.3+ features to lower PHP versions", + "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", "homepage": "https://symfony.com", "keywords": [ "compatibility", @@ -4114,7 +3892,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.26.0" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.26.0" }, "funding": [ { @@ -4130,20 +3908,20 @@ "type": "tidelift" } ], - "time": "2022-05-24T11:49:31+00:00" + "time": "2022-05-10T07:21:04+00:00" }, { - "name": "symfony/polyfill-php80", + "name": "symfony/polyfill-php81", "version": "v1.26.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace" + "url": "https://github.com/symfony/polyfill-php81.git", + "reference": "13f6d1271c663dc5ae9fb843a8f16521db7687a1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/cfa0ae98841b9e461207c13ab093d76b0fa7bace", - "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace", + "url": "https://api.github.com/repos/symfony/polyfill-php81/zipball/13f6d1271c663dc5ae9fb843a8f16521db7687a1", + "reference": "13f6d1271c663dc5ae9fb843a8f16521db7687a1", "shasum": "" }, "require": { @@ -4164,7 +3942,7 @@ "bootstrap.php" ], "psr-4": { - "Symfony\\Polyfill\\Php80\\": "" + "Symfony\\Polyfill\\Php81\\": "" }, "classmap": [ "Resources/stubs" @@ -4175,10 +3953,6 @@ "MIT" ], "authors": [ - { - "name": "Ion Bazan", - "email": "ion.bazan@gmail.com" - }, { "name": "Nicolas Grekas", "email": "p@tchwork.com" @@ -4188,7 +3962,7 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", + "description": "Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions", "homepage": "https://symfony.com", "keywords": [ "compatibility", @@ -4197,7 +3971,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.26.0" + "source": "https://github.com/symfony/polyfill-php81/tree/v1.26.0" }, "funding": [ { @@ -4213,25 +3987,24 @@ "type": "tidelift" } ], - "time": "2022-05-10T07:21:04+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/process", - "version": "v5.4.11", + "version": "v6.1.3", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "6e75fe6874cbc7e4773d049616ab450eff537bf1" + "reference": "a6506e99cfad7059b1ab5cab395854a0a0c21292" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/6e75fe6874cbc7e4773d049616ab450eff537bf1", - "reference": "6e75fe6874cbc7e4773d049616ab450eff537bf1", + "url": "https://api.github.com/repos/symfony/process/zipball/a6506e99cfad7059b1ab5cab395854a0a0c21292", + "reference": "a6506e99cfad7059b1ab5cab395854a0a0c21292", "shasum": "" }, "require": { - "php": ">=7.2.5", - "symfony/polyfill-php80": "^1.16" + "php": ">=8.1" }, "type": "library", "autoload": { @@ -4259,7 +4032,7 @@ "description": "Executes commands in sub-processes", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/process/tree/v5.4.11" + "source": "https://github.com/symfony/process/tree/v6.1.3" }, "funding": [ { @@ -4275,7 +4048,7 @@ "type": "tidelift" } ], - "time": "2022-06-27T16:58:25+00:00" + "time": "2022-06-27T17:24:16+00:00" }, { "name": "symfony/service-contracts", @@ -4364,20 +4137,20 @@ }, { "name": "symfony/stopwatch", - "version": "v5.4.5", + "version": "v6.1.0", "source": { "type": "git", "url": "https://github.com/symfony/stopwatch.git", - "reference": "4d04b5c24f3c9a1a168a131f6cbe297155bc0d30" + "reference": "77dedae82ce2a26e2e9b481855473fc3b3e4e54d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/stopwatch/zipball/4d04b5c24f3c9a1a168a131f6cbe297155bc0d30", - "reference": "4d04b5c24f3c9a1a168a131f6cbe297155bc0d30", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/77dedae82ce2a26e2e9b481855473fc3b3e4e54d", + "reference": "77dedae82ce2a26e2e9b481855473fc3b3e4e54d", "shasum": "" }, "require": { - "php": ">=7.2.5", + "php": ">=8.1", "symfony/service-contracts": "^1|^2|^3" }, "type": "library", @@ -4406,7 +4179,7 @@ "description": "Provides a way to profile code", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/stopwatch/tree/v5.4.5" + "source": "https://github.com/symfony/stopwatch/tree/v6.1.0" }, "funding": [ { @@ -4422,7 +4195,7 @@ "type": "tidelift" } ], - "time": "2022-02-18T16:06:09+00:00" + "time": "2022-02-25T11:15:52+00:00" }, { "name": "symfony/string", @@ -4626,7 +4399,7 @@ "prefer-stable": true, "prefer-lowest": false, "platform": { - "php": "^7.3|^8.0", + "php": "^7.4|^8.0", "ext-bcmath": "*", "ext-gmp": "*" }, diff --git a/examples/decode_payment_request_into_array.php b/examples/decode_payment_request_into_array.php index ea38fb6..bde0888 100644 --- a/examples/decode_payment_request_into_array.php +++ b/examples/decode_payment_request_into_array.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; require dirname(__DIR__).DIRECTORY_SEPARATOR.'vendor'.DIRECTORY_SEPARATOR.'autoload.php'; diff --git a/examples/get_amount_description_from_payment_request.php b/examples/get_amount_description_from_payment_request.php index 50b42c4..d723565 100644 --- a/examples/get_amount_description_from_payment_request.php +++ b/examples/get_amount_description_from_payment_request.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; use Jorijn\Bitcoin\Bolt11\Model\Tag; use Jorijn\Bitcoin\Bolt11\Normalizer\PaymentRequestDenormalizer; diff --git a/examples/get_fallback_address_from_payment_request.php b/examples/get_fallback_address_from_payment_request.php index 85df5fc..979729e 100644 --- a/examples/get_fallback_address_from_payment_request.php +++ b/examples/get_fallback_address_from_payment_request.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; use Jorijn\Bitcoin\Bolt11\Model\FallbackAddress; use Jorijn\Bitcoin\Bolt11\Model\Tag; diff --git a/examples/get_milli_satoshis_from_payment_request.php b/examples/get_milli_satoshis_from_payment_request.php index 5df086f..199ed04 100644 --- a/examples/get_milli_satoshis_from_payment_request.php +++ b/examples/get_milli_satoshis_from_payment_request.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; use Jorijn\Bitcoin\Bolt11\Normalizer\PaymentRequestDenormalizer; diff --git a/examples/get_routing_info_from_payment_request.php b/examples/get_routing_info_from_payment_request.php index 108440c..5f4bc3c 100644 --- a/examples/get_routing_info_from_payment_request.php +++ b/examples/get_routing_info_from_payment_request.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; use Jorijn\Bitcoin\Bolt11\Model\RoutingInfo; use Jorijn\Bitcoin\Bolt11\Model\Tag; diff --git a/examples/parse_blank_payment_request.php b/examples/parse_blank_payment_request.php index c31572d..96e5dce 100644 --- a/examples/parse_blank_payment_request.php +++ b/examples/parse_blank_payment_request.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; use Jorijn\Bitcoin\Bolt11\Model\Tag; use Jorijn\Bitcoin\Bolt11\Normalizer\PaymentRequestDenormalizer; diff --git a/examples/payment_request_with_expiration_timestamp.php b/examples/payment_request_with_expiration_timestamp.php index 9f36e2e..e7ddf4c 100644 --- a/examples/payment_request_with_expiration_timestamp.php +++ b/examples/payment_request_with_expiration_timestamp.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; use Jorijn\Bitcoin\Bolt11\Model\Tag; use Jorijn\Bitcoin\Bolt11\Normalizer\PaymentRequestDenormalizer; diff --git a/examples/view_all_available_attributes.php b/examples/view_all_available_attributes.php index 8fb384d..225dfe0 100644 --- a/examples/view_all_available_attributes.php +++ b/examples/view_all_available_attributes.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; use Jorijn\Bitcoin\Bolt11\Normalizer\PaymentRequestDenormalizer; diff --git a/examples/view_timestamp_from_payment_request.php b/examples/view_timestamp_from_payment_request.php index 0a2f1f9..c3d59b4 100644 --- a/examples/view_timestamp_from_payment_request.php +++ b/examples/view_timestamp_from_payment_request.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; use Jorijn\Bitcoin\Bolt11\Normalizer\PaymentRequestDenormalizer; diff --git a/src/Encoder/PaymentRequestDecoder.php b/src/Encoder/PaymentRequestDecoder.php index 04b13f3..757b443 100644 --- a/src/Encoder/PaymentRequestDecoder.php +++ b/src/Encoder/PaymentRequestDecoder.php @@ -2,10 +2,20 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Encoder; use function BitWasp\Bech32\decodeRaw; use function BitWasp\Bech32\encode; + use BitWasp\Bitcoin\Address\PayToPubKeyHashAddress; use BitWasp\Bitcoin\Address\ScriptHashAddress; use BitWasp\Bitcoin\Address\SegwitAddress; @@ -67,8 +77,10 @@ class PaymentRequestDecoder /** @var string[] */ protected $tagNames = []; + /** @var \Closure[] */ protected $tagParsers = []; + /** @var EcAdapterInterface */ protected $ecAdapter; @@ -104,7 +116,7 @@ public function decode(string $paymentRequest): array // get remaining signature buffer after extracting recovery flag $signatureBuffer = $signatureBuffer->slice(0, -1); - if (!(\in_array($recoveryID, [0, 1, 2, 3], true)) || 64 !== $signatureBuffer->getSize()) { + if (!\in_array($recoveryID, [0, 1, 2, 3], true) || 64 !== $signatureBuffer->getSize()) { throw new SignatureIncorrectOrMissingException('signature is missing or incorrect'); } @@ -132,7 +144,7 @@ public function decode(string $paymentRequest): array $divisor = $prefixMatches[3]; try { - $satoshis = (int) ($this->hrpToSat($value.$divisor)); + $satoshis = (int) $this->hrpToSat($value.$divisor); } catch (\Throwable $exception) { $satoshis = 0; $removeSatoshis = true; diff --git a/src/Exception/InvalidAmountException.php b/src/Exception/InvalidAmountException.php index 391d070..ad20616 100644 --- a/src/Exception/InvalidAmountException.php +++ b/src/Exception/InvalidAmountException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class InvalidAmountException extends PaymentRequestDecodeException diff --git a/src/Exception/InvalidPaymentRequestException.php b/src/Exception/InvalidPaymentRequestException.php index 48f12b3..91ccd5d 100644 --- a/src/Exception/InvalidPaymentRequestException.php +++ b/src/Exception/InvalidPaymentRequestException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class InvalidPaymentRequestException extends PaymentRequestDecodeException diff --git a/src/Exception/PaymentRequestDecodeException.php b/src/Exception/PaymentRequestDecodeException.php index 39ecd56..b992ed6 100644 --- a/src/Exception/PaymentRequestDecodeException.php +++ b/src/Exception/PaymentRequestDecodeException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; abstract class PaymentRequestDecodeException extends \RuntimeException diff --git a/src/Exception/SignatureDoesNotMatchPayeePubkeyDecodeException.php b/src/Exception/SignatureDoesNotMatchPayeePubkeyDecodeException.php index 7f0c970..c8dc147 100644 --- a/src/Exception/SignatureDoesNotMatchPayeePubkeyDecodeException.php +++ b/src/Exception/SignatureDoesNotMatchPayeePubkeyDecodeException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class SignatureDoesNotMatchPayeePubkeyDecodeException extends PaymentRequestDecodeException diff --git a/src/Exception/SignatureIncorrectOrMissingException.php b/src/Exception/SignatureIncorrectOrMissingException.php index 52e95ce..1f907a3 100644 --- a/src/Exception/SignatureIncorrectOrMissingException.php +++ b/src/Exception/SignatureIncorrectOrMissingException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class SignatureIncorrectOrMissingException extends PaymentRequestDecodeException diff --git a/src/Exception/UnableToDecodeBech32Exception.php b/src/Exception/UnableToDecodeBech32Exception.php index cb7e54e..8414623 100644 --- a/src/Exception/UnableToDecodeBech32Exception.php +++ b/src/Exception/UnableToDecodeBech32Exception.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class UnableToDecodeBech32Exception extends PaymentRequestDecodeException diff --git a/src/Exception/UnableToDenormalizeException.php b/src/Exception/UnableToDenormalizeException.php index d24744c..66512ea 100644 --- a/src/Exception/UnableToDenormalizeException.php +++ b/src/Exception/UnableToDenormalizeException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class UnableToDenormalizeException extends \RuntimeException diff --git a/src/Exception/UnknownFallbackAddressVersionException.php b/src/Exception/UnknownFallbackAddressVersionException.php index ffa9e83..e080506 100644 --- a/src/Exception/UnknownFallbackAddressVersionException.php +++ b/src/Exception/UnknownFallbackAddressVersionException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class UnknownFallbackAddressVersionException extends PaymentRequestDecodeException diff --git a/src/Exception/UnknownNetworkVersionException.php b/src/Exception/UnknownNetworkVersionException.php index 8576380..4884755 100644 --- a/src/Exception/UnknownNetworkVersionException.php +++ b/src/Exception/UnknownNetworkVersionException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class UnknownNetworkVersionException extends PaymentRequestDecodeException diff --git a/src/Exception/UnrecoverableSignatureException.php b/src/Exception/UnrecoverableSignatureException.php index fbbab78..3fd4117 100644 --- a/src/Exception/UnrecoverableSignatureException.php +++ b/src/Exception/UnrecoverableSignatureException.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Exception; class UnrecoverableSignatureException extends PaymentRequestDecodeException diff --git a/src/Model/FallbackAddress.php b/src/Model/FallbackAddress.php index 04cc1b6..b231039 100644 --- a/src/Model/FallbackAddress.php +++ b/src/Model/FallbackAddress.php @@ -2,14 +2,25 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Model; class FallbackAddress { /** @var int */ protected $code; + /** @var string */ protected $address; + /** @var string */ protected $addressHash; diff --git a/src/Model/PaymentRequest.php b/src/Model/PaymentRequest.php index 1a79e5f..7e14d45 100644 --- a/src/Model/PaymentRequest.php +++ b/src/Model/PaymentRequest.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Model; use BitWasp\Bitcoin\Network\NetworkInterface; @@ -10,26 +19,37 @@ class PaymentRequest { /** @var string */ protected $prefix; + /** @var NetworkInterface */ protected $network; + /** @var null|int */ protected $satoshis; + /** @var null|int */ protected $milliSatoshis; + /** @var int */ protected $timestamp; + /** @var \DateTimeInterface */ protected $timestampDateTime; + /** @var string */ protected $payeeNodeKey; + /** @var string */ protected $signature; + /** @var int */ protected $recoveryFlag; + /** @var TagInterface[] */ protected $tags = []; + /** @var null|int */ protected $expiryTimestamp; + /** @var null|\DateTimeInterface */ protected $expiryDateTime; diff --git a/src/Model/RoutingInfo.php b/src/Model/RoutingInfo.php index 4a69e3f..92733a7 100644 --- a/src/Model/RoutingInfo.php +++ b/src/Model/RoutingInfo.php @@ -2,18 +2,31 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Model; class RoutingInfo { /** @var string */ protected $pubkey; + /** @var string */ protected $shortChannelId; + /** @var int */ protected $feeBaseMsat; + /** @var int */ protected $feeProportionalMillionths; + /** @var int */ protected $cltvExpiryDelta; diff --git a/src/Model/Tag.php b/src/Model/Tag.php index 3c3a53f..f8c30f6 100644 --- a/src/Model/Tag.php +++ b/src/Model/Tag.php @@ -2,31 +2,49 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Model; class Tag implements TagInterface { /** @var string */ public const PAYMENT_HASH = 'payment_hash'; + /** @var string */ public const DESCRIPTION = 'description'; + /** @var string */ public const PAYEE_NODE_KEY = 'payee_node_key'; + /** @var string */ public const PURPOSE_COMMIT_HASH = 'purpose_commit_hash'; + /** @var string */ public const EXPIRE_TIME = 'expire_time'; + /** @var string */ public const MIN_FINAL_CLTV_EXPIRY = 'min_final_cltv_expiry'; + /** @var string */ public const FALLBACK_ADDRESS = 'fallback_address'; + /** @var string */ public const ROUTING_INFO = 'routing_info'; + /** @var string */ public const SECRET = 'secret'; /** @var string */ protected $tagName; + /** @var mixed */ protected $data; diff --git a/src/Model/TagInterface.php b/src/Model/TagInterface.php index 9c4efeb..24b1458 100644 --- a/src/Model/TagInterface.php +++ b/src/Model/TagInterface.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Model; interface TagInterface diff --git a/src/Model/UnknownTag.php b/src/Model/UnknownTag.php index e78df15..4f8ff84 100644 --- a/src/Model/UnknownTag.php +++ b/src/Model/UnknownTag.php @@ -2,12 +2,22 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Model; class UnknownTag implements TagInterface { /** @var int */ protected $tagCode; + /** @var string */ protected $words; diff --git a/src/Normalizer/DenormalizerTrait.php b/src/Normalizer/DenormalizerTrait.php index 9fddf9e..135600f 100644 --- a/src/Normalizer/DenormalizerTrait.php +++ b/src/Normalizer/DenormalizerTrait.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Exception\UnableToDenormalizeException; diff --git a/src/Normalizer/FallbackAddressDenormalizer.php b/src/Normalizer/FallbackAddressDenormalizer.php index a24cd6f..c850786 100644 --- a/src/Normalizer/FallbackAddressDenormalizer.php +++ b/src/Normalizer/FallbackAddressDenormalizer.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Model\FallbackAddress; diff --git a/src/Normalizer/PaymentRequestDenormalizer.php b/src/Normalizer/PaymentRequestDenormalizer.php index 2d4bac2..ab2ceb2 100644 --- a/src/Normalizer/PaymentRequestDenormalizer.php +++ b/src/Normalizer/PaymentRequestDenormalizer.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Model\PaymentRequest; diff --git a/src/Normalizer/RoutingInfoDenormalizer.php b/src/Normalizer/RoutingInfoDenormalizer.php index 3469d01..2186300 100644 --- a/src/Normalizer/RoutingInfoDenormalizer.php +++ b/src/Normalizer/RoutingInfoDenormalizer.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Model\RoutingInfo; diff --git a/src/Normalizer/TagDenormalizer.php b/src/Normalizer/TagDenormalizer.php index e2fb28f..f5dcceb 100644 --- a/src/Normalizer/TagDenormalizer.php +++ b/src/Normalizer/TagDenormalizer.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; @@ -16,6 +25,7 @@ class TagDenormalizer /** @var FallbackAddressDenormalizer */ protected $fallbackAddressDenormalizer; + /** @var RoutingInfoDenormalizer */ protected $routingInfoDenormalizer; diff --git a/tests/Encoder/PaymentRequestDecoderTest.php b/tests/Encoder/PaymentRequestDecoderTest.php index 91c9d6c..c045408 100644 --- a/tests/Encoder/PaymentRequestDecoderTest.php +++ b/tests/Encoder/PaymentRequestDecoderTest.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Tests\Jorijn\Bitcoin\Bolt11\Encoder; use BitWasp\Bitcoin\Bitcoin; diff --git a/tests/Model/PaymentRequestTest.php b/tests/Model/PaymentRequestTest.php index f957259..7ede817 100644 --- a/tests/Model/PaymentRequestTest.php +++ b/tests/Model/PaymentRequestTest.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Tests\Jorijn\Bitcoin\Bolt11\Model; use Jorijn\Bitcoin\Bolt11\Model\PaymentRequest; diff --git a/tests/Normalizer/DenormalizerTraitTest.php b/tests/Normalizer/DenormalizerTraitTest.php index d806d49..33d99ae 100644 --- a/tests/Normalizer/DenormalizerTraitTest.php +++ b/tests/Normalizer/DenormalizerTraitTest.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Tests\Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Exception\UnableToDenormalizeException; diff --git a/tests/Normalizer/FallbackAddressDenormalizerTest.php b/tests/Normalizer/FallbackAddressDenormalizerTest.php index 977c74f..3d57392 100644 --- a/tests/Normalizer/FallbackAddressDenormalizerTest.php +++ b/tests/Normalizer/FallbackAddressDenormalizerTest.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Tests\Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Normalizer\FallbackAddressDenormalizer; diff --git a/tests/Normalizer/PaymentRequestDenormalizerTest.php b/tests/Normalizer/PaymentRequestDenormalizerTest.php index cffdd31..1449607 100644 --- a/tests/Normalizer/PaymentRequestDenormalizerTest.php +++ b/tests/Normalizer/PaymentRequestDenormalizerTest.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Tests\Jorijn\Bitcoin\Bolt11\Normalizer; use BitWasp\Bitcoin\Network\NetworkInterface; @@ -25,6 +34,7 @@ final class PaymentRequestDenormalizerTest extends TestCase { /** @var PaymentRequestDenormalizer */ protected $denormalizer; + /** @var MockObject|TagDenormalizer */ protected $tagDenormalizer; diff --git a/tests/Normalizer/RoutingInfoDenormalizerTest.php b/tests/Normalizer/RoutingInfoDenormalizerTest.php index 5da76de..e36726d 100644 --- a/tests/Normalizer/RoutingInfoDenormalizerTest.php +++ b/tests/Normalizer/RoutingInfoDenormalizerTest.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Tests\Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Model\RoutingInfo; diff --git a/tests/Normalizer/TagDenormalizerTest.php b/tests/Normalizer/TagDenormalizerTest.php index 61cd157..16f4653 100644 --- a/tests/Normalizer/TagDenormalizerTest.php +++ b/tests/Normalizer/TagDenormalizerTest.php @@ -2,6 +2,15 @@ declare(strict_types=1); +/* + * This file is part of the PHP Bitcoin BOLT11 package. + * + * (c) Jorijn Schrijvershof + * + * This source file is subject to the MIT license that is bundled + * with this source code in the file LICENSE. + */ + namespace Tests\Jorijn\Bitcoin\Bolt11\Normalizer; use Jorijn\Bitcoin\Bolt11\Encoder\PaymentRequestDecoder; @@ -29,8 +38,10 @@ final class TagDenormalizerTest extends TestCase { /** @var FallbackAddressDenormalizer|MockObject */ protected $fallbackAddressDenormalizer; + /** @var MockObject|RoutingInfoDenormalizer */ protected $routingInfoDenormalizer; + /** @var TagDenormalizer */ protected $tagDenormalizer;