SchnorrSignature
Table of Contents
Constants
-
AUX
= 'BIP0340/aux'
-
CHALLENGE
= 'BIP0340/challenge'
-
NONCE
= 'BIP0340/nonce'
Methods
-
sign()
: array<string|int, mixed>
-
verify()
: bool
-
finalizeSchnorrVerify()
: bool
-
gmp_hexval()
: string
-
initSchnorrVerify()
: array<string|int, mixed>
AUX
public
mixed
AUX
= 'BIP0340/aux'
CHALLENGE
public
mixed
CHALLENGE
= 'BIP0340/challenge'
NONCE
public
mixed
NONCE
= 'BIP0340/nonce'
sign()
public
sign(string $privateKey, string $message[, string $randomK = null ]) : array<string|int, mixed>
Parameters
-
$privateKey
: string
-
-
$message
: string
-
-
$randomK
: string
= null
-
Return values
array<string|int, mixed>
verify()
public
verify(string $publicKey, string $signature, string $message) : bool
Parameters
-
$publicKey
: string
-
-
$signature
: string
-
-
$message
: string
-
finalizeSchnorrVerify()
private
finalizeSchnorrVerify(GMP $r, PointInterface $P, GMP $s, GMP $e) : bool
Parameters
-
$r
: GMP
-
-
$P
: PointInterface
-
-
$s
: GMP
-
-
$e
: GMP
-
gmp_hexval()
private
gmp_hexval(GMP $gmp) : string
Parameters
-
$gmp
: GMP
-
initSchnorrVerify()
private
initSchnorrVerify(string $signature, string $message, string $publicKey) : array<string|int, mixed>
Parameters
-
$signature
: string
-
-
$message
: string
-
-
$publicKey
: string
-
Return values
array<string|int, mixed>