简体   繁体   English

我可以从智能卡中的密钥容器获取公钥/私钥对吗?

[英]Can I get public/private key pair from a key container in smartcard?

我可以使用PKCS#11或CryptoAPI从智能卡内的密钥容器中获取公钥/私钥对吗?

I'm no expert in this, but I think the whole point of a smartcard is that you can't extract the private key. 我不是这方面的专家,但我认为智能卡的全部意义在于你无法提取私钥。 You send the data to the card instead, and let it do the crypto operations on its own processor. 您将数据发送到卡,并让它在自己的处理器上执行加密操作。

It depends. 这取决于。 Both CryptoAPI (well the CSP for the smart card) and PKCS#11 allows you to have exportable key pairs. CryptoAPI(以及智能卡的CSP)和PKCS#11都允许您使用可导出的密钥对。 However it's common to use non exportable private keys to use the smart card strength to its full potential. 但是,通常使用不可导出的私钥来充分发挥智能卡强度的作用。

So if you're writing an application it becomes your choice. 因此,如果您正在编写应用程序,它将成为您的选择。 Otherwise someone else already made that choice for you ;-) 否则其他人已经为你做出了这个选择;-)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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