diff --git a/phpseclib/Math/BigInteger.php b/phpseclib/Math/BigInteger.php index b3ab84a8..70491abd 100644 --- a/phpseclib/Math/BigInteger.php +++ b/phpseclib/Math/BigInteger.php @@ -437,6 +437,8 @@ class BigInteger implements \JsonSerializable * JSON Serialize * * Will be called, automatically, when json_encode() is called on a BigInteger object. + * + * @return array{hex: string, precision?: int] */ #[\ReturnTypeWillChange] public function jsonSerialize() diff --git a/phpseclib/Math/BigInteger/Engines/Engine.php b/phpseclib/Math/BigInteger/Engines/Engine.php index 3f34fd36..2b00bc37 100644 --- a/phpseclib/Math/BigInteger/Engines/Engine.php +++ b/phpseclib/Math/BigInteger/Engines/Engine.php @@ -370,6 +370,8 @@ abstract class Engine implements \JsonSerializable * JSON Serialize * * Will be called, automatically, when json_encode() is called on a BigInteger object. + * + * @return array{hex: string, precision?: int] */ #[\ReturnTypeWillChange] public function jsonSerialize() diff --git a/phpseclib/Math/Common/FiniteField/Integer.php b/phpseclib/Math/Common/FiniteField/Integer.php index 4197ed37..3c959e94 100644 --- a/phpseclib/Math/Common/FiniteField/Integer.php +++ b/phpseclib/Math/Common/FiniteField/Integer.php @@ -26,6 +26,8 @@ abstract class Integer implements \JsonSerializable * * PHP Serialize isn't supported because unserializing would require the factory be * serialized as well and that just sounds like too much + * + * @return array{hex: string} */ #[\ReturnTypeWillChange] public function jsonSerialize()