AccountEd25519Signature
in package
Ed25519 signature for Soroban authorization entries
This class represents an Ed25519 signature used in the authorization process for Soroban smart contracts. It encapsulates the public key and signature bytes that are required for validating authorization entries. The signature is typically created when signing authorization entries with a keypair.
Tags
Table of Contents
Properties
- $publicKey : string
- $signatureBytes : string
Methods
- __construct() : mixed
- Creates a new Ed25519 signature for Soroban authorization.
- getPublicKey() : string
- Returns the raw Ed25519 public key.
- getSignatureBytes() : string
- Returns the raw Ed25519 signature bytes.
- setPublicKey() : void
- Sets the raw Ed25519 public key.
- setSignatureBytes() : void
- Sets the raw Ed25519 signature bytes.
- toXdrSCVal() : XdrSCVal
- Returns a scval map containing the public key and signature bytes.
Properties
$publicKey
public
string
$publicKey
raw Ed25519 public key of 32 bytes used for signature verification
$signatureBytes
public
string
$signatureBytes
raw Ed25519 signature bytes generated by signing the authorization payload
Methods
__construct()
Creates a new Ed25519 signature for Soroban authorization.
public
__construct(string $publicKey, string $signatureBytes) : mixed
Parameters
- $publicKey : string
-
raw Ed25519 public key of 32 bytes used for verification
- $signatureBytes : string
-
raw Ed25519 signature bytes produced by signing the payload
getPublicKey()
Returns the raw Ed25519 public key.
public
getPublicKey() : string
Return values
string —raw public key of 32 bytes
getSignatureBytes()
Returns the raw Ed25519 signature bytes.
public
getSignatureBytes() : string
Return values
string —the raw signature bytes
setPublicKey()
Sets the raw Ed25519 public key.
public
setPublicKey(string $publicKey) : void
Parameters
- $publicKey : string
-
raw public key of 32 bytes
setSignatureBytes()
Sets the raw Ed25519 signature bytes.
public
setSignatureBytes(string $signatureBytes) : void
Parameters
- $signatureBytes : string
-
the raw signature bytes
toXdrSCVal()
Returns a scval map containing the public key and signature bytes.
public
toXdrSCVal() : XdrSCVal
Return values
XdrSCVal —the scval map containing the public key and signature bytes.