|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--cryptix.pgp.KeyStore | +--cryptix.pgp.KeyRing | +--cryptix.pgp.SecretKeyRing
Represents a secret keyring. Use the getKey()
functions
to retrieve a key.
Copyright © 1995-1997
Systemics Ltd on behalf of the
Cryptix Development Team.
All rights reserved.
$Revision: 1.1.1.1 $
Fields inherited from class cryptix.pgp.KeyRing |
addresses, entriesById, users |
Constructor Summary | |
protected |
SecretKeyRing()
Creates an empty secret keyring object. |
|
SecretKeyRing(java.io.InputStream in)
Creates a new secret keyring object from in. |
|
SecretKeyRing(java.lang.String filename)
Create a new secret keyring object from the file filename. |
Method Summary | |
SecretKey |
getKey(EmailAddress address,
Passphrase passphrase)
Retrieves a key by any of the e-mail addresses on it. |
PublicKey |
getKey(KeyID keyID)
DON'T USE THIS - it's only here to allow SecretKeyRing to fit into this class hierarchy. |
SecretKey |
getKey(KeyID keyID,
Passphrase passphrase)
Retrieves a key by its ID. |
PublicKey |
getKey(java.lang.String username)
DON'T USE THIS - it's only here to allow SecretKeyRing to fit into this class hierarchy. |
SecretKey |
getKey(java.lang.String username,
Passphrase passphrase)
Retrieves a key by any of the user names on it. |
int |
getKeyTrust(KeyID keyId)
How much is the key with ID keyId trusted by this user? |
protected void |
init(PacketInputStream reader)
Subclasses should override this method to read entries from an InputStream. |
Methods inherited from class cryptix.pgp.KeyRing |
add, checkSignatures, checkSignatures, dump, getFullNameList, getFullUserNameList, getIfBegins, getPublicKey, getPublicKey, getSecretKey, getSecretKey, getUserName, list, write |
Methods inherited from class cryptix.pgp.KeyStore |
checkSignature, checkSignature, checkSignature |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
protected SecretKeyRing()
add
method to add new entries.public SecretKeyRing(java.io.InputStream in) throws java.io.IOException
java.io.IOException
- if there was an I/O errorpublic SecretKeyRing(java.lang.String filename) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
- if filename was not foundjava.io.IOException
- if there was an I/O errorMethod Detail |
public final PublicKey getKey(java.lang.String username) throws FormatException
null
is always returned as a
passphrase is needed to decrypt the key first.getKey
in class KeyStore
public final SecretKey getKey(java.lang.String username, Passphrase passphrase) throws java.io.IOException, DecryptException
java.io.IOException
- if there was an I/O errorDecryptException
- if the key could not be decryptedpublic final PublicKey getKey(KeyID keyID)
null
is always returned as a
passphrase is needed to decrypt the key first.getKey
in class KeyStore
public final SecretKey getKey(KeyID keyID, Passphrase passphrase) throws DecryptException
DecryptException
- if the key could not be decryptedpublic final SecretKey getKey(EmailAddress address, Passphrase passphrase) throws DecryptException
DecryptException
- if the key could not be decryptedpublic final int getKeyTrust(KeyID keyId)
KeyRing
getKeyTrust
in class KeyRing
protected final void init(PacketInputStream reader) throws java.io.IOException
KeyRing
init
in class KeyRing
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |