Interface DerivationAlgorithm<T extends KeyDerivationParameters>

  • All Known Implementing Classes:
    ConcatKDF, HKDF

    public interface DerivationAlgorithm<T extends KeyDerivationParameters>
    The DerivationAlgorithm is the base interface for all key derivation algorithms implementation.
    • Method Detail

      • deriveKey

        byte[] deriveKey​(byte[] secret,
                         T params)
                  throws XMLSecurityException
        Derives a key from the given secret and other info.
        Parameters:
        secret - The "shared" secret to use for key derivation (e.g. the secret key)
        params - The key derivation parameters implementing the KeyDerivationParameters interface
        Returns:
        Byte array of the derived key
        Throws:
        XMLSecurityException - in case of derivation error or invalid parameters