java SunX509 的用途是什么,它可以与使用 IbmX509 的各方一起使用吗?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/10073202/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
What is SunX509 used for and can it work with parties using IbmX509?
提问by daramasala
When I manually create a KeyManager
, one of the steps is this:
当我手动创建 a 时KeyManager
,其中一个步骤是:
KeyManagerFactory.getInstance("SunX509")
This does not work on IBM jre where I need to specify "IbmX509".
My questions:
这不适用于我需要指定“IbmX509”的 IBM jre。
我的问题:
- I read that this is called the "certificate encoding algorithm". What does that mean? When is it used?
- What happens when the client is using the IBM algorithm and the server is using the Sun algorithm?
- 我读到这称为“证书编码算法”。这意味着什么?什么时候使用?
- 当客户端使用 IBM 算法而服务器使用 Sun 算法时会发生什么?
Thanks,
Doron
谢谢,
多伦
回答by user207421
I read that this is called the "certificate encoding algorithm".
我读到这称为“证书编码算法”。
No it isn't. It is a key manager algorithm that defines both a provider and a content type, in this case "Sun" or "IBM" and X.509. Basically it is a keystore type.
不,不是。它是一种密钥管理器算法,用于定义提供者和内容类型,在本例中为“Sun”或“IBM”和 X.509。基本上它是一种密钥库类型。
Anyway the best solution is not to use either. Just use
无论如何,最好的解决方案是不要使用。只需使用
KeyManagerFactory.getInstance(KeyManagerFactory.getDefaultAlgorithm());
The KeyManager
and KeyManagerFactory
just deal with the local keystore/truststore. The peer doesn't care about that, only about the certificates that are in them, and that only indirectly.
在KeyManager
与KeyManagerFactory
刚刚处理本地密钥库/信任。对等方不关心这个,只关心其中的证书,而且只是间接的。