openssl 1.1.1b 如何制作SM2公钥(在Ubuntu 19.04下测试通过)

liuqun@vmware:~$ openssl ecparam -list_curves
  secp112r1 : SECG/WTLS curve over a 112 bit prime field
  secp112r2 : SECG curve over a 112 bit prime field
  secp128r1 : SECG curve over a 128 bit prime field
... 省略若干行 ...
  brainpoolP384t1: RFC 5639 curve over a 384 bit prime field
  brainpoolP512r1: RFC 5639 curve over a 512 bit prime field
  brainpoolP512t1: RFC 5639 curve over a 512 bit prime field
  SM2       : SM2 curve over a 256 bit prime field
liuqun@vmware:~$ openssl ecparam -name SM2 -genkey -noout -out ../sm2-key.pem
liuqun@vmware:~$ cat sm2-key.pem
-----BEGIN EC PRIVATE KEY-----
MHcCAQEEIBrBtetQDddQUUtuuSoJk3/Qbl+8G+nwBeJZAwVDp04FoAoGCCqBHM9V
AYItoUQDQgAEWSZWD9vh+2u/uAHn2QVDoe1Gv4mScyvYyedJ9ZTrYZzEjmPzIcOS
HEQ9S6e1LQuvwgX8nlJ4LM8uZAbgvj+1MQ==
-----END EC PRIVATE KEY-----
liuqun@vmware:~$ openssl version
OpenSSL 1.1.1b  26 Feb 2019

liuqun@vmware:~$ which openssl
/usr/bin/openssl

你可能感兴趣的:(openssl 1.1.1b 如何制作SM2公钥(在Ubuntu 19.04下测试通过))