|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.di.plugin.security.authentication.ProxyAuth
public class ProxyAuth
Mutual authentication between the proxy and a client. A client can be either the plug-in module of a Password Synchronizer or an administration tool. This class handles the authentication protocol from the proxy side.
Field Summary | |
---|---|
static java.lang.String |
CLIENT_PASSWORD_FILE_NAME
The name of the password file of client (plugin or admin tool). |
static int |
PASSWORD_LENGTH
The length of a password in bytes. |
static java.lang.String |
PROXY_PASSWORD_FILE_NAME
The name of the password file of the proxy. |
Constructor Summary | |
---|---|
ProxyAuth()
|
Method Summary | |
---|---|
static boolean |
authenticate(java.net.Socket socket,
java.lang.String authFolder,
PWSyncLog log)
Perform mutual authentication between the proxy and a client. |
static void |
createPWDFile(java.lang.String filePath,
byte[] password)
Create a password file using the specified password. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String CLIENT_PASSWORD_FILE_NAME
public static final java.lang.String PROXY_PASSWORD_FILE_NAME
public static final int PASSWORD_LENGTH
Constructor Detail |
---|
public ProxyAuth()
Method Detail |
---|
public static void createPWDFile(java.lang.String filePath, byte[] password) throws java.io.IOException
filePath
- The path of the password file that will be created.password
- The password that will be written in the file.
java.io.IOException
- Error while writing the file.public static boolean authenticate(java.net.Socket socket, java.lang.String authFolder, PWSyncLog log)
Perform mutual authentication between the proxy and a client. This method handles the proxy side of the protocol.
The authentication protocol goes like this: First the proxy creates both password files. After that the proxy notifies the client that the authentication may begin. Then in turns the client and the each other's passwords over the connection: the client sends the proxy's password to the proxy, and the proxy sends the client's password to the client.
socket
- A connection to the client.authFolder
- Authentication folder.log
- Logger.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |