Package org.cryptacular.adapter
Class Converter
java.lang.Object
org.cryptacular.adapter.Converter
Static factory with methods to convert from BC type to the corresponding JCE type.
- Author:
- Middleware Services
-
Method Summary
Modifier and TypeMethodDescriptionstatic PrivateKey
convertPrivateKey
(org.bouncycastle.crypto.params.AsymmetricKeyParameter bcKey) Produces aPrivateKey
from a BC private key type.static PublicKey
convertPublicKey
(org.bouncycastle.crypto.params.AsymmetricKeyParameter bcKey) Produces aPublicKey
from a BC public key type.
-
Method Details
-
convertPrivateKey
public static PrivateKey convertPrivateKey(org.bouncycastle.crypto.params.AsymmetricKeyParameter bcKey) Produces aPrivateKey
from a BC private key type.- Parameters:
bcKey
- BC private key.- Returns:
- JCE private key.
-
convertPublicKey
public static PublicKey convertPublicKey(org.bouncycastle.crypto.params.AsymmetricKeyParameter bcKey) Produces aPublicKey
from a BC public key type.- Parameters:
bcKey
- BC public key.- Returns:
- JCE public key.
-