Module java.base

Class SM2PrivateKeySpec

  • All Implemented Interfaces:
    KeySpec

    public final class SM2PrivateKeySpec
    extends ECPrivateKeySpec
    A SM2 private key with the specified value.
    • Constructor Detail

      • SM2PrivateKeySpec

        public SM2PrivateKeySpec​(BigInteger s)
        Create a new SM2PrivateKeySpec with a key value.
        Parameters:
        s - the private key value.
      • SM2PrivateKeySpec

        public SM2PrivateKeySpec​(byte[] sKey)
        Create a new SM2PrivateKeySpec with a key in byte array.
        Parameters:
        sKey - the private key value represented by a byte array.