DigestingStateAwareMessageSigner (Bouncy Castle Library 1.85 API Specification)
Date: 2026-07-12

org.bouncycastle.pqc.crypto

## Class DigestingStateAwareMessageSigner

- java.lang.Object
- - org.bouncycastle.pqc.crypto.DigestingMessageSigner
  - - org.bouncycastle.pqc.crypto.DigestingStateAwareMessageSigner

- All Implemented Interfaces:
    Signer

      public class DigestingStateAwareMessageSigner
      extends DigestingMessageSigner

  Implements the sign and verify functions for a Signature Scheme using a hash function to allow processing of large messages.

  This class can be used with algorithms where the state associated with the private key changes as each signature is generated. Calling getUpdatedPrivateKey() will recover the private key that can be used to initialize a signer next time around.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DigestingStateAwareMessageSigner(StateAwareMessageSigner messSigner, Digest messDigest)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `AsymmetricKeyParameter` | `getUpdatedPrivateKey()` Return the current version of the private key with the updated state.

    - ### Methods inherited from class org.bouncycastle.pqc.crypto.DigestingMessageSigner

      `generateSignature, init, reset, update, update, verifySignature`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### DigestingStateAwareMessageSigner

          public DigestingStateAwareMessageSigner(StateAwareMessageSigner messSigner,
                                                  Digest messDigest)

  - ### Method Detail

    - #### getUpdatedPrivateKey

          public AsymmetricKeyParameter getUpdatedPrivateKey()

      Return the current version of the private key with the updated state.

      Note: calling this method will effectively disable the Signer from being used for further signature generation without another call to init().

      Returns:
        an updated private key object, which can be used for later signature generation.