java.lang.Object
net.i2p.crypto.KeyPair
net.i2p.router.crypto.ratchet.Elg2KeyPair

public class Elg2KeyPairextends KeyPair
X25519 key pair with pre-calculated Elligator2-encoded public key.
  • Field Details

    • encoded

      private final byte[] encoded
      The key in its encoded form.
  • Constructor Details

    • Elg2KeyPair

      public Elg2KeyPair(PublicKey publicKey, PrivateKey privateKey, byte[] enc)
      Key pair from the given keys and the pre-encoded public key.
      Parameters:
      publicKey - the public key
      privateKey - the private key
      enc - the encoded Elligator2 public key
  • Method Details

    • getEncoded

      public byte[] getEncoded()
      The pre-calculated Elligator2-encoded public key.
      Returns:
      the encoded Elligator2 public key