All Packages Class Hierarchy This Package Previous Next Index
Class cryptix.pgp.SecretKeyRing
java.lang.Object
|
+----cryptix.pgp.KeyStore
|
+----cryptix.pgp.KeyRing
|
+----cryptix.pgp.SecretKeyRing
- public final class SecretKeyRing
- extends KeyRing
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 $
- Author:
- Mike Wynn, Ian Brown
-
SecretKeyRing()
- Creates an empty secret keyring object.
-
SecretKeyRing(InputStream)
- Creates a new secret keyring object from in.
-
SecretKeyRing(String)
- Create a new secret keyring object from the file filename.
-
getKey(EmailAddress, Passphrase)
- Retrieves a key by any of the e-mail addresses on it.
-
getKey(KeyID)
- DON'T USE THIS - it's only here to allow SecretKeyRing to fit
into this class hierarchy.
-
getKey(KeyID, Passphrase)
- Retrieves a key by its ID.
-
getKey(String)
- DON'T USE THIS - it's only here to allow SecretKeyRing to fit
into this class hierarchy.
-
getKey(String, Passphrase)
- Retrieves a key by any of the user names on it.
-
getKeyTrust(KeyID)
- How much is the key with ID keyId trusted by this user?
-
init(PacketInputStream)
- Subclasses should override this method to read entries from
an InputStream.
SecretKeyRing
protected SecretKeyRing()
- Creates an empty secret keyring object. Use the
add
method to add new entries.
SecretKeyRing
public SecretKeyRing(InputStream in) throws IOException
- Creates a new secret keyring object from in.
- Throws: IOException
- if there was an I/O error
SecretKeyRing
public SecretKeyRing(String filename) throws FileNotFoundException, IOException
- Create a new secret keyring object from the file filename.
- Throws: FileNotFoundException
- if filename was not found
- Throws: IOException
- if there was an I/O error
getKey
public final PublicKey getKey(String username) throws FormatException
- DON'T USE THIS - it's only here to allow SecretKeyRing to fit
into this class hierarchy.
null
is always returned as a
passphrase is needed to decrypt the key first.
- Overrides:
- getKey in class KeyStore
getKey
public final SecretKey getKey(String username,
Passphrase passphrase) throws IOException, DecryptException
- Retrieves a key by any of the user names on it.
- Throws: IOException
- if there was an I/O error
- Throws: DecryptException
- if the key could not be decrypted
getKey
public final PublicKey getKey(KeyID keyID)
- DON'T USE THIS - it's only here to allow SecretKeyRing to fit
into this class hierarchy.
null
is always returned as a
passphrase is needed to decrypt the key first.
- Overrides:
- getKey in class KeyStore
getKey
public final SecretKey getKey(KeyID keyID,
Passphrase passphrase) throws DecryptException
- Retrieves a key by its ID.
- Throws: DecryptException
- if the key could not be decrypted
getKey
public final SecretKey getKey(EmailAddress address,
Passphrase passphrase) throws DecryptException
- Retrieves a key by any of the e-mail addresses on it.
- Throws: DecryptException
- if the key could not be decrypted
getKeyTrust
public final int getKeyTrust(KeyID keyId)
- How much is the key with ID keyId trusted by this user?
- Overrides:
- getKeyTrust in class KeyRing
init
protected final void init(PacketInputStream reader) throws IOException
- Subclasses should override this method to read entries from
an InputStream.
- Overrides:
- init in class KeyRing
All Packages Class Hierarchy This Package Previous Next Index