Project JXTA

net.jxta.impl.membership.pse
Class FileKeyStoreManager

java.lang.Object
  extended bynet.jxta.impl.membership.pse.FileKeyStoreManager
All Implemented Interfaces:
KeyStoreManager

public class FileKeyStoreManager
extends Object
implements KeyStoreManager

Manages a Keystore located at at URI. This version precludes KeyStores which are built from multiple URIs.


Constructor Summary
FileKeyStoreManager(String type, String provider, File location)
          Default constructor.
 
Method Summary
 void createKeyStore(char[] store_password)
          
 void eraseKeyStore()
          
 boolean isInitialized()
          
 boolean isInitialized(char[] store_password)
          
 KeyStore loadKeyStore(char[] password)
          Return the keystore instance we are using. i
 void saveKeyStore(KeyStore store, char[] password)
          Return the keystore instance we are using. includes compatibility code to force using Bouncy Castle for < JDK 1.5.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileKeyStoreManager

public FileKeyStoreManager(String type,
                           String provider,
                           File location)
                    throws NoSuchProviderException,
                           KeyStoreException
Default constructor.

Method Detail

isInitialized

public boolean isInitialized()

Specified by:
isInitialized in interface KeyStoreManager

isInitialized

public boolean isInitialized(char[] store_password)

Specified by:
isInitialized in interface KeyStoreManager

createKeyStore

public void createKeyStore(char[] store_password)
                    throws KeyStoreException,
                           IOException

Specified by:
createKeyStore in interface KeyStoreManager
Throws:
KeyStoreException
IOException

loadKeyStore

public KeyStore loadKeyStore(char[] password)
                      throws KeyStoreException,
                             IOException
Return the keystore instance we are using. i

Specified by:
loadKeyStore in interface KeyStoreManager
Throws:
KeyStoreException
IOException

saveKeyStore

public void saveKeyStore(KeyStore store,
                         char[] password)
                  throws KeyStoreException,
                         IOException
Return the keystore instance we are using. includes compatibility code to force using Bouncy Castle for < JDK 1.5. The JCE 1.4.X PCKS#12 keystore is read only.

Specified by:
saveKeyStore in interface KeyStoreManager
Throws:
KeyStoreException
IOException

eraseKeyStore

public void eraseKeyStore()
                   throws IOException

Specified by:
eraseKeyStore in interface KeyStoreManager
Throws:
IOException

JXTA J2SE