class SynchronizerSnapshotSyncCryptoApi extends SyncCryptoApi with NamedLogging
crypto operations for a (synchronizer,timestamp)
- Alphabetic
- By Inheritance
- SynchronizerSnapshotSyncCryptoApi
- NamedLogging
- SyncCryptoApi
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new SynchronizerSnapshotSyncCryptoApi(synchronizerId: SynchronizerId, staticSynchronizerParameters: StaticSynchronizerParameters, ipsSnapshot: TopologySnapshot, crypto: Crypto, syncCryptoSigner: SyncCryptoSigner, syncCryptoVerifier: SyncCryptoVerifier, loggerFactory: NamedLoggerFactory)(implicit ec: ExecutionContext)
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- val crypto: Crypto
- 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.
Decrypts a message using the private key of the public key identified by the fingerprint in the AsymmetricEncrypted object.
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- 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 member.
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- implicit def errorLoggingContext(implicit traceContext: TraceContext): ErrorLoggingContext
- Attributes
- protected
- Definition Classes
- NamedLogging
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- val ipsSnapshot: TopologySnapshot
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def logger: TracedLogger
- Attributes
- protected
- Definition Classes
- NamedLogging
- val loggerFactory: NamedLoggerFactory
- Attributes
- protected
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → NamedLogging
- implicit def namedLoggingContext(implicit traceContext: TraceContext): NamedLoggingContext
- Attributes
- protected
- Definition Classes
- NamedLogging
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def noTracingLogger: Logger
- Attributes
- protected
- Definition Classes
- NamedLogging
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- val pureCrypto: CryptoPureApi
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- 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
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- val syncCryptoSigner: SyncCryptoSigner
- val syncCryptoVerifier: SyncCryptoVerifier
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- val synchronizerId: SynchronizerId
- def toString(): String
- Definition Classes
- AnyRef → Any
- 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
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- 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 amediatorGroup
, counting each member's signature only once.Verifies a list of
signatures
to be produced by active members of amediatorGroup
, counting each member's signature only once. ReturnsRight
when themediatorGroup
'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 returnsLeft
with all the signature check errors.- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- def verifySequencerSignatures(hash: Hash, signatures: NonEmpty[Seq[Signature]], usage: NonEmpty[Set[SigningKeyUsage]])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SignatureCheckError, Unit]
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- 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
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- def verifySignatures(hash: Hash, signer: Member, signatures: NonEmpty[Seq[Signature]], usage: NonEmpty[Set[SigningKeyUsage]])(implicit traceContext: TraceContext): EitherT[FutureUnlessShutdown, SignatureCheckError, Unit]
- Definition Classes
- SynchronizerSnapshotSyncCryptoApi → SyncCryptoApi
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])