简体   繁体   中英

Size of RSA struct and size of public key in Openssl

为什么如果我在RSA对象上调用RSA_size() ,我得到的值小于在同一个RSA对象上调用的RSA_size()的返回值( i2d_RSAPublicKey的大小)?

Because i2d_RSAPublicKey gives you a PKCS#1 encoded version of the key, including public exponent and DER elements.

RSA_size() gives you just the size in bytes of the pure modulus (which is also the size of any unencoded signature or ciphertext for that key).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM