Class AsymmetricKeyPairEcBc

  • All Implemented Interfaces:
    AsymmetricKeyPair<org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPrivateKey,​org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPublicKey>, KeySet

    public class AsymmetricKeyPairEcBc
    extends AsymmetricKeyPairEc<org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPrivateKey,​org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPublicKey>
    An implementation of AsymmetricKeyPair for BCECPrivateKey and BCECPublicKey.
    Since:
    1.0.0
    Author:
    Joerg Hohwiller (hohwille at users.sourceforge.net)
    • Constructor Detail

      • AsymmetricKeyPairEcBc

        public AsymmetricKeyPairEcBc​(org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPrivateKey privateKey)
        The constructor.
        Parameters:
        privateKey - the private key.
      • AsymmetricKeyPairEcBc

        public AsymmetricKeyPairEcBc​(org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPrivateKey privateKey,
                                     org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPublicKey publicKey)
        The constructor.
        Parameters:
        privateKey - the private key.
        publicKey - the public key.
    • Method Detail

      • createPrivateKey

        public static org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPrivateKey createPrivateKey​(BigInteger s,
                                                                                                     org.bouncycastle.jce.spec.ECParameterSpec ecParameters)
        Parameters:
        s - the private key value s.
        ecParameters - the ECParameterSpec representing the curve.
        Returns:
        the BCECPrivateKey.
      • createPrivateKey

        public static org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPrivateKey createPrivateKey​(org.bouncycastle.jce.spec.ECPrivateKeySpec keySpec)
        Parameters:
        keySpec - the ECPrivateKeySpec.
        Returns:
        the BCECPrivateKey.
      • createPrivateKeyFromEncodedData

        public static org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPrivateKey createPrivateKeyFromEncodedData​(byte[] data)
        Parameters:
        data - the encoded data.
        Returns:
        the BCECPrivateKey.
      • createPublicKey

        public static org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPublicKey createPublicKey​(org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPrivateKey privateKey)
        Parameters:
        privateKey - the BCECPrivateKey.
        Returns:
        the corresponding BCECPublicKey.
      • createPublicKey

        public static org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPublicKey createPublicKey​(org.bouncycastle.math.ec.ECPoint q,
                                                                                                   org.bouncycastle.jce.spec.ECParameterSpec ecParameters)
        Parameters:
        q - the public key value q.
        ecParameters - the ECParameterSpec representing the curve.
        Returns:
        the ECPublicKey.
      • createPublicKey

        public static org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPublicKey createPublicKey​(org.bouncycastle.jce.spec.ECPublicKeySpec keySpec)
        Parameters:
        keySpec - the ECPublicKeySpec.
        Returns:
        the ECPublicKey.
      • createPublicKeyFromEncodedData

        public static org.bouncycastle.jcajce.provider.asymmetric.ec.BCECPublicKey createPublicKeyFromEncodedData​(byte[] data)
        Parameters:
        data - the encoded data.
        Returns:
        the ECPublicKey.