org.globus.gsi.bc
Class BouncyCastleOpenSSLKey
java.lang.Object
org.globus.gsi.OpenSSLKey
org.globus.gsi.bc.BouncyCastleOpenSSLKey
- public class BouncyCastleOpenSSLKey
- extends OpenSSLKey
BouncyCastle-based implementation of OpenSSLKey.
Methods inherited from class org.globus.gsi.OpenSSLKey |
decrypt, decrypt, encrypt, encrypt, getEncoded, getPrivateKey, isEncrypted, setEncryptionAlgorithm, writeTo, writeTo, writeTo |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BouncyCastleOpenSSLKey
public BouncyCastleOpenSSLKey(InputStream is)
throws IOException,
GeneralSecurityException
BouncyCastleOpenSSLKey
public BouncyCastleOpenSSLKey(String file)
throws IOException,
GeneralSecurityException
BouncyCastleOpenSSLKey
public BouncyCastleOpenSSLKey(PrivateKey key)
BouncyCastleOpenSSLKey
public BouncyCastleOpenSSLKey(String algorithm,
byte[] data)
throws GeneralSecurityException
getKey
protected PrivateKey getKey(String alg,
byte[] data)
throws GeneralSecurityException
- Description copied from class:
OpenSSLKey
- Returns PrivateKey object initialized from give byte array
(in PKCS#1 format)
- Specified by:
getKey
in class OpenSSLKey
- Throws:
GeneralSecurityException
getEncoded
protected byte[] getEncoded(PrivateKey key)
- Description copied from class:
OpenSSLKey
- Returns DER encoded byte array (PKCS#1).
- Specified by:
getEncoded
in class OpenSSLKey
getProvider
protected String getProvider()
- Overrides:
getProvider
in class OpenSSLKey