SignatureVerifier

org.sigilaris.core.application.security.SignatureVerifier

Utilities for recovering signer keys from signed transactions and verifying key ownership against registered accounts.

Attributes

Source
SignatureVerifier.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

def recoverKeyId[F[_], T <: Tx](signedTx: Signed[T], context: Option[String])(using evidence$1: Monad[F], hashT: Hash[T], recoverT: Recover[T]): StoreF[F][KeyId20]

Recover the 20-byte key identifier from a signed transaction's signature.

Recover the 20-byte key identifier from a signed transaction's signature.

Type parameters

F

the effect type

T

the transaction type

Value parameters

context

optional context string included in error messages on failure

signedTx

the signed transaction to recover from

Attributes

Returns

the recovered KeyId20, or raises a CryptoFailure

Source
SignatureVerifier.scala
def verifyKeyOwnership[F[_] : Monad](accountSig: AccountSignature, recoveredKeyId: KeyId20, envelopeTimestamp: Instant)(lookup: (Utf8, KeyId20) => StoreF[F][Option[KeyInfo]]): StoreF[F][Unit]

Verify that the recovered key belongs to the claimed signer and is not expired.

Verify that the recovered key belongs to the claimed signer and is not expired.

Attributes

Source
SignatureVerifier.scala
def verifySignature[F[_], T <: Tx](signedTx: Signed[T], envelopeTimestamp: Instant, context: Option[String])(lookup: (Utf8, KeyId20) => StoreF[F][Option[KeyInfo]])(using evidence$1: Monad[F], Hash[T], Recover[T]): StoreF[F][KeyId20]

Recover the signer key and verify ownership in a single step.

Recover the signer key and verify ownership in a single step.

Attributes

Source
SignatureVerifier.scala