All Known Implementing Classes:
HashBasedCounter

public interface Counter
Interface for byte array based counter used for cryptography.
Author:
Roman Strobl, roman.strobl@wultra.com
  • Method Summary

    Modifier and Type
    Method
    Description
    byte[]
    Initialize counter by generating initial counter data.
    byte[]
    next(byte[] ctrData)
    Generate next counter data based on current counter data.
  • Method Details

    • init

      byte[] init() throws CryptoProviderException
      Initialize counter by generating initial counter data.
      Returns:
      Initial counter data.
      Throws:
      CryptoProviderException - In case key cryptography provider is incorrectly initialized.
    • next

      byte[] next(byte[] ctrData)
      Generate next counter data based on current counter data.
      Parameters:
      ctrData - Current counter data.
      Returns:
      Next counter data.