public final class NtlmUtil extends Object
Modifier and Type | Method and Description |
---|---|
static byte[] |
getLMv2Response(byte[] responseKeyLM,
byte[] serverChallenge,
byte[] clientChallenge) |
static byte[] |
getLMv2Response(String domain,
String user,
String password,
byte[] challenge,
byte[] clientChallenge)
Creates the LMv2 response for the supplied information.
|
static byte[] |
getNTLM2Response(byte[] nTOWFv1,
byte[] serverChallenge,
byte[] clientChallenge) |
static byte[] |
getNTLMResponse(String password,
byte[] challenge)
Generate the Unicode MD4 hash for the password associated with these credentials.
|
static byte[] |
getNTLMv2Response(byte[] responseKeyNT,
byte[] serverChallenge,
byte[] clientChallenge,
long nanos1601,
byte[] targetInfo) |
static byte[] |
getPreNTLMResponse(CIFSContext tc,
String password,
byte[] challenge)
Generate the ANSI DES hash for the password associated with these credentials.
|
static byte[] |
nTOWFv1(String password) |
static byte[] |
nTOWFv2(String domain,
String username,
String password) |
public static byte[] getNTLMv2Response(byte[] responseKeyNT, byte[] serverChallenge, byte[] clientChallenge, long nanos1601, byte[] targetInfo)
responseKeyNT
- serverChallenge
- clientChallenge
- nanos1601
- targetInfo
- public static byte[] getLMv2Response(byte[] responseKeyLM, byte[] serverChallenge, byte[] clientChallenge)
responseKeyLM
- serverChallenge
- clientChallenge
- public static byte[] nTOWFv2(String domain, String username, String password)
domain
- username
- password
- public static byte[] nTOWFv1(String password)
password
- public static byte[] getNTLM2Response(byte[] nTOWFv1, byte[] serverChallenge, byte[] clientChallenge) throws GeneralSecurityException
nTOWFv1
- serverChallenge
- clientChallenge
- GeneralSecurityException
public static byte[] getLMv2Response(String domain, String user, String password, byte[] challenge, byte[] clientChallenge) throws GeneralSecurityException
domain
- The domain in which the username exists.user
- The username.password
- The user's password.challenge
- The server challenge.clientChallenge
- The client challenge (nonce).GeneralSecurityException
public static byte[] getNTLMResponse(String password, byte[] challenge) throws GeneralSecurityException
password
- challenge
- GeneralSecurityException
public static byte[] getPreNTLMResponse(CIFSContext tc, String password, byte[] challenge) throws GeneralSecurityException
tc
- password
- challenge
- GeneralSecurityException
Copyright © 2016. All rights reserved.