Class PublicKeyKeyEncryptionMethodGenerator

    • Field Detail

      • SESSION_KEY_OBFUSCATION_PROPERTY

        public static final java.lang.String SESSION_KEY_OBFUSCATION_PROPERTY
        See Also:
        Constant Field Values
      • sessionKeyObfuscation

        protected boolean sessionKeyObfuscation
      • useWildcardKeyID

        protected boolean useWildcardKeyID
    • Constructor Detail

      • PublicKeyKeyEncryptionMethodGenerator

        protected PublicKeyKeyEncryptionMethodGenerator​(PGPPublicKey pubKey)
    • Method Detail

      • setSessionKeyObfuscation

        public PublicKeyKeyEncryptionMethodGenerator setSessionKeyObfuscation​(boolean enabled)
        Controls whether to obfuscate the size of ECDH session keys using extra padding where necessary.

        The default behaviour can be configured using the system property "", or else it will default to enabled.

        Returns:
        the current generator.
      • setUseWildcardKeyID

        public PublicKeyKeyEncryptionMethodGenerator setUseWildcardKeyID​(boolean enabled)
        Controls whether the recipient key ID is hidden (replaced by a wildcard ID
        0
        ).
        Parameters:
        enabled - boolean
        Returns:
        this
      • processSessionInfo

        public byte[][] processSessionInfo​(byte[] encryptedSessionInfo)
                                    throws PGPException
        Throws:
        PGPException
      • getSessionInfo

        protected static byte[] getSessionInfo​(byte[] ephPubEncoding,
                                               byte[] c)
                                        throws java.io.IOException
        Throws:
        java.io.IOException
      • getSessionInfo

        protected static byte[] getSessionInfo​(byte[] VB,
                                               int sysmmetricKeyAlgorithm,
                                               byte[] c)