edu.stanford.peer.secrmi
Class SecureClientToolkit
java.lang.Object
|
+--edu.stanford.peer.secrmi.SecureRMIToolkit
|
+--edu.stanford.peer.secrmi.SecureClientToolkit
- public class SecureClientToolkit
- extends edu.stanford.peer.secrmi.SecureRMIToolkit
Constructor Summary |
SecureClientToolkit(java.security.KeyStore classKS,
java.lang.String ckAlias,
java.security.KeyStore objectKS,
java.lang.String okAlias)
Creates a SecureClientToolkit object using KeyStore objects and
aliases, which specify the two trusted public keys. |
SecureClientToolkit(java.security.PublicKey classKey,
java.security.PublicKey objectKey)
Create a SecureClientToolkit object using the public key trusted for
signing the class of the proxy and the public key trusted for signing
the object of the proxy. |
Method Summary |
static java.security.KeyStore |
loadKeyStore(java.lang.String type,
java.io.FileInputStream in,
char[] icchars)
Load a key store from an input stream. |
static java.security.KeyStore |
loadKeyStore(java.lang.String type,
java.lang.String provider,
java.io.FileInputStream in,
char[] icchars)
Load a key store from an input stream. |
static java.security.KeyStore |
loadKeyStore(java.lang.String type,
java.lang.String filename,
java.lang.String icword)
Load a key store from file. |
static java.security.KeyStore |
loadKeyStore(java.lang.String type,
java.lang.String provider,
java.lang.String filename,
java.lang.String icword)
Load a key store from file. |
java.lang.Object |
lookupSigned(java.lang.String proxyAddress)
Looks up a signed proxy and verify that it is signed by the trusted key |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SecureClientToolkit
public SecureClientToolkit(java.security.PublicKey classKey,
java.security.PublicKey objectKey)
- Create a SecureClientToolkit object using the public key trusted for
signing the class of the proxy and the public key trusted for signing
the object of the proxy.
- Parameters:
classKey
- the public key trusted for signing the
class of the proxy.objectKey
- the public key trusted for signing
the object of the proxy.
SecureClientToolkit
public SecureClientToolkit(java.security.KeyStore classKS,
java.lang.String ckAlias,
java.security.KeyStore objectKS,
java.lang.String okAlias)
throws java.security.KeyStoreException
- Creates a SecureClientToolkit object using KeyStore objects and
aliases, which specify the two trusted public keys.
- Parameters:
ks1
- the KeyStore that contains the public keyalias1
- ks2
- alias2
-
lookupSigned
public java.lang.Object lookupSigned(java.lang.String proxyAddress)
throws java.rmi.NotBoundException,
VerificationFailureException,
java.io.IOException,
java.lang.ClassNotFoundException
- Looks up a signed proxy and verify that it is signed by the trusted key
- Parameters:
proxyAddress
- the address of the signed proxy
loadKeyStore
public static final java.security.KeyStore loadKeyStore(java.lang.String type,
java.lang.String filename,
java.lang.String icword)
throws java.io.FileNotFoundException,
java.io.IOException,
java.security.KeyStoreException,
java.security.cert.CertificateException,
java.security.NoSuchAlgorithmException
- Load a key store from file.
- Parameters:
type
- the type of the key store to load, e.g., JKS, jceks, etc.filename
- the name of the key store fileicword
- the word for checking the integrity of the key store;
when it is null, no check is performed
loadKeyStore
public static final java.security.KeyStore loadKeyStore(java.lang.String type,
java.io.FileInputStream in,
char[] icchars)
throws java.io.IOException,
java.security.KeyStoreException,
java.security.cert.CertificateException,
java.security.NoSuchAlgorithmException
- Load a key store from an input stream.
- Parameters:
type
- the type of the key store to load, e.g., JKS, jceks, etc.in
- the input stream of the keystoreicchars
- the word for checking the integrity of the key store;
when it is null, no check is performed.
loadKeyStore
public static final java.security.KeyStore loadKeyStore(java.lang.String type,
java.lang.String provider,
java.lang.String filename,
java.lang.String icword)
throws java.io.FileNotFoundException,
java.io.IOException,
java.security.KeyStoreException,
java.security.cert.CertificateException,
java.security.NoSuchAlgorithmException,
java.security.NoSuchProviderException
- Load a key store from file.
- Parameters:
type
- the type of the key store to load, e.g., JKS, jceks, etc.provider
- the name of the providerfilename
- the name of the key store fileicword
- the word for checking the integrity of the key store;
when it is null, no check is performed
loadKeyStore
public static final java.security.KeyStore loadKeyStore(java.lang.String type,
java.lang.String provider,
java.io.FileInputStream in,
char[] icchars)
throws java.io.IOException,
java.security.KeyStoreException,
java.security.NoSuchProviderException,
java.security.cert.CertificateException,
java.security.NoSuchAlgorithmException
- Load a key store from an input stream.
- Parameters:
type
- the type of the key store to load, e.g., JKS, jceks, etc.provider
- the name of the providerin
- the input stream of the keystoreicchars
- the word for checking the integrity of the key store;
when it is null, no check is performed