Packages

trait SyncCryptoApi extends AnyRef

impure part of the crypto api with access to private key store and knowledge about the current entity to key assoc

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. SyncCryptoApi
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Abstract Value Members

  1. abstract def decrypt[M](encryptedMessage: AsymmetricEncrypted[M])(deserialize: (ByteString) => Either[DeserializationError, M])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SyncCryptoError, M]

    Decrypts a message using the private key of the public key identified by the fingerprint in the AsymmetricEncrypted object.

  2. abstract def encryptFor[M <: HasToByteString, MemberType <: Member](message: M, members: Seq[MemberType])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, (MemberType, SyncCryptoError), Map[MemberType, AsymmetricEncrypted[M]]]

    Encrypts a message for the given members

    Encrypts a message for the given members

    Utility method to lookup a key on an IPS snapshot and then encrypt the given message with the most suitable key for the respective key owner.

  3. abstract def ipsSnapshot: TopologySnapshot
  4. abstract def pureCrypto: CryptoPureApi
  5. abstract def sign(hash: Hash, usage: NonEmpty[Set[SigningKeyUsage]])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SyncCryptoError, Signature]

    Signs the given hash using the private signing key.

    Signs the given hash using the private signing key. It uses the most recent signing key with the specified usage in the private store. The key usage must intersect with the provided usage, but it does not need to satisfy all the provided usages.

    hash

    the hash to sign

    usage

    restricts signing to private keys that have at least one matching usage

  6. abstract def unsafePartialVerifySequencerSignatures(hash: Hash, signatures: NonEmpty[Seq[Signature]], usage: NonEmpty[Set[SigningKeyUsage]])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SignatureCheckError, Unit]

    This verifies that at least one of the signature is a valid sequencer signature.

    This verifies that at least one of the signature is a valid sequencer signature. In particular, it does not respect the participant trust threshold. This should be used only in the context of reassignment where the concept of cross-synchronizer proof of sequencing is not fully fleshed out.

    TODO(#12410) Remove this method and respect trust threshold

  7. abstract def verifyMediatorSignatures(hash: Hash, mediatorGroupIndex: MediatorGroupIndex, signatures: NonEmpty[Seq[Signature]], usage: NonEmpty[Set[SigningKeyUsage]])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SignatureCheckError, Unit]

    Verifies a list of signatures to be produced by active members of a mediatorGroup, counting each member's signature only once.

    Verifies a list of signatures to be produced by active members of a mediatorGroup, counting each member's signature only once. Returns Right when the mediatorGroup's threshold is met. Can be successful even if some signatures fail the check, logs the errors in that case. When the threshold is not met returns Left with all the signature check errors.

  8. abstract def verifySequencerSignatures(hash: Hash, signatures: NonEmpty[Seq[Signature]], usage: NonEmpty[Set[SigningKeyUsage]])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SignatureCheckError, Unit]
  9. abstract def verifySignature(hash: Hash, signer: Member, signature: Signature, usage: NonEmpty[Set[SigningKeyUsage]])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SignatureCheckError, Unit]

    Verify signature of a given owner.

    Verify signature of a given owner. Convenience method to lookup a key of a given owner, synchronizer and timestamp and verify the result.

    usage

    verifies that the signature was produced with a signing key with at least one matching usage

  10. abstract def verifySignatures(hash: Hash, signer: Member, signatures: NonEmpty[Seq[Signature]], usage: NonEmpty[Set[SigningKeyUsage]])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SignatureCheckError, Unit]

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
  6. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  7. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  8. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @IntrinsicCandidate() @native()
  9. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @IntrinsicCandidate() @native()
  10. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  11. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @IntrinsicCandidate() @native()
  13. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @IntrinsicCandidate() @native()
  14. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  15. def toString(): String
    Definition Classes
    AnyRef → Any
  16. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  17. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  18. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

    (Since version 9)

Inherited from AnyRef

Inherited from Any

Ungrouped