Ed25519PublicKey

@Serializable
class Ed25519PublicKey(data: ByteArray) : AccountPublicKey

Represents the public key of an Ed25519 key pair.

Since AIP-55 Aptos supports Legacy and Unified authentication keys.

Ed25519 scheme is represented in the SDK as Legacy authentication key and also as AnyPublicKey that represents any Unified authentication key

Constructors

Link copied to clipboard
constructor(data: HexInput)
constructor(data: ByteArray)

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
open override fun authKey(): AuthenticationKey

Get the authentication key associated with this public key

Link copied to clipboard
open override fun toBcs(): ByteArray

Get the public key in BCS bytes (ByteArray).

Link copied to clipboard
open override fun toByteArray(): ByteArray

Get the public key in bytes (ByteArray).

Link copied to clipboard
open override fun toString(): String

Get the public key as a hex string with a 0x prefix e.g. 0x123456...

Link copied to clipboard
open override fun verifySignature(message: HexInput, signature: Signature): Boolean

Verifies that the private key associated with this public key signed the message with the given signature.