cryptData
protected byte[] cryptData(boolean forEncryption,
AlgorithmIdentifier algId,
char[] password,
boolean wrongPKCS12Zero,
byte[] data)
throws IOException
engineAliases
public Enumeration engineAliases()
engineContainsAlias
public boolean engineContainsAlias(String alias)
engineDeleteEntry
public void engineDeleteEntry(String alias)
throws KeyStoreException
this is not quite complete - we should follow up on the chain, a bit
tricky if a certificate appears in more than one chain...
engineGetCertificate
public Certificate engineGetCertificate(String alias)
simply return the cert for the private key
engineGetCertificateAlias
public String engineGetCertificateAlias(Certificate cert)
engineGetCertificateChain
public Certificate[] engineGetCertificateChain(String alias)
engineGetCreationDate
public Date engineGetCreationDate(String alias)
engineGetKey
public Key engineGetKey(String alias,
char[] password)
throws NoSuchAlgorithmException,
UnrecoverableKeyException
engineIsCertificateEntry
public boolean engineIsCertificateEntry(String alias)
engineIsKeyEntry
public boolean engineIsKeyEntry(String alias)
engineLoad
public void engineLoad(InputStream stream,
char[] password)
throws IOException
engineSetCertificateEntry
public void engineSetCertificateEntry(String alias,
Certificate cert)
throws KeyStoreException
engineSetKeyEntry
public void engineSetKeyEntry(String alias,
Key key,
char[] password,
Certificate[] chain)
throws KeyStoreException
engineSetKeyEntry
public void engineSetKeyEntry(String alias,
byte[] key,
Certificate[] chain)
throws KeyStoreException
engineSize
public int engineSize()
engineStore
public void engineStore(OutputStream stream,
char[] password)
throws IOException
setRandom
public void setRandom(SecureRandom rand)
set the random source for the key store
- setRandom in interface BCKeyStore
unwrapKey
protected PrivateKey unwrapKey(AlgorithmIdentifier algId,
byte[] data,
char[] password,
boolean wrongPKCS12Zero)
throws IOException
wrapKey
protected byte[] wrapKey(String algorithm,
Key key,
PKCS12PBEParams pbeParams,
char[] password)
throws IOException