java.lang.Object
net.i2p.crypto.CryptixAESKeyCache

public final class CryptixAESKeyCacheextends Object
Cache the objects used in CryptixRijndael_Algorithm.makeKey to reduce memory churn. The KeyCacheEntry should be held onto as long as the data referenced in it is needed (which often is only one or two lines of code)

Not for external use, not a public API.

Unused as a class, as the keys are cached in the SessionKey objects, but the static methods are used in FortunaStandalone.

  • Field Details

    • KEYSIZE

      private static final int KEYSIZE
      Key length, 32 bytes for AES-256.
      See Also:
    • BLOCKSIZE

      private static final int BLOCKSIZE
      AES block size, in bytes.
      See Also:
    • ROUNDS

      private static final int ROUNDS
      Number of encryption rounds for the key size.
    • BC

      private static final int BC
      Block size measured in 4-byte words.
      See Also:
  • Constructor Details

    • CryptixAESKeyCache

      public CryptixAESKeyCache()
      Constructor. The round-key cache itself is never instantiated - entries come from the static createNew() - so a bare instance holds nothing.
  • Method Details