|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnet.sourceforge.jtds.util.SSPIJNIClient
A JNI client to SSPI based CPP program (DLL) that returns the user credentials for NTLM authentication.
The DLL name is ntlmauth.dll.
| Field Summary | |
private boolean |
initialized
SSPI client initialized flag. |
private static boolean |
libraryLoaded
SSPI native library loaded flag. |
private static SSPIJNIClient |
thisInstance
Singleton instance. |
| Constructor Summary | |
private |
SSPIJNIClient()
Private constructor for singleton. |
| Method Summary | |
static SSPIJNIClient |
getInstance()
Returns the singleton SSPIJNIClient instance. |
private void |
initialize()
Initializes the SSPI client. |
void |
invokeInitialize()
Calls #initialize() if the SSPI client is not already inited. |
byte[] |
invokePrepareSSORequest()
Calls #prepareSSORequest() to prepare the NTLM TYPE-1 message. |
byte[] |
invokePrepareSSOSubmit(byte[] buf)
Calls #prepareSSOSubmit(byte[], long) to prepare the NTLM TYPE-3
message. |
void |
invokeUnInitialize()
Calls #unInitialize() if the SSPI client is inited. |
private byte[] |
prepareSSORequest()
Prepares the NTLM TYPE-1 message and returns it as a byte[]. |
private byte[] |
prepareSSOSubmit(byte[] buf,
long size)
Prepares the NTLM TYPE-3 message using the current user's credentials. |
private void |
unInitialize()
Uninitializes the SSPI client. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
private static SSPIJNIClient thisInstance
private static boolean libraryLoaded
private boolean initialized
| Constructor Detail |
private SSPIJNIClient()
| Method Detail |
private void initialize()
private void unInitialize()
private byte[] prepareSSORequest()
byte[].
private byte[] prepareSSOSubmit(byte[] buf,
long size)
It needs the challenge BLOB and it's size as input. The challenge BLOB is nothig but the TYPE-2 message that is received from the SQL Server.
buf - challenge BLOBsize - challenge BLOB size
public static SSPIJNIClient getInstance()
throws java.lang.Exception
SSPIJNIClient instance.
java.sql.SQLException - if an error occurs during initialization
java.lang.Exceptionpublic void invokeInitialize()
#initialize() if the SSPI client is not already inited.
public void invokeUnInitialize()
#unInitialize() if the SSPI client is inited.
public byte[] invokePrepareSSORequest()
throws java.lang.Exception
#prepareSSORequest() to prepare the NTLM TYPE-1 message.
java.lang.Exception - if an error occurs during the call or the SSPI client
is uninitialized
public byte[] invokePrepareSSOSubmit(byte[] buf)
throws java.lang.Exception
#prepareSSOSubmit(byte[], long) to prepare the NTLM TYPE-3
message.
java.lang.Exception - if an error occurs during the call or the SSPI client
is uninitialized
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||