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

org.bouncycastle.crypto

## Interface EncapsulatedSecretGenerator

- All Known Implementing Classes:
    CMCEKEMGenerator, CMCEKEMGenerator, ECIESKEMGenerator, FrodoKEMGenerator, FrodoKEMGenerator, HQCKEMGenerator, MLKEMGenerator, MLKEMGenerator, NTRUKEMGenerator, NTRULPRimeKEMGenerator, NTRUPlusKEMGenerator, RSAKEMGenerator, SABERKEMGenerator, SAKKEKEMSGenerator, SNTRUPrimeKEMGenerator, XWingKEMGenerator

      public interface EncapsulatedSecretGenerator

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `SecretWithEncapsulation` | `generateEncapsulated(AsymmetricKeyParameter recipientKey)` Generate secret/encapsulation based on the recipient public key.

- - ### Method Detail

    - #### generateEncapsulated

          SecretWithEncapsulation generateEncapsulated(AsymmetricKeyParameter recipientKey)

      Generate secret/encapsulation based on the recipient public key.
      Returns:
        An SecretWithEncapsulation derived from the recipient public key.