public class ChallengeResponseCredential extends Object implements Credential
Modifier and Type | Field and Description |
---|---|
protected byte[] |
m_Challenge
The 8-byte challenge.
|
protected String |
m_Name
The name of the user.
|
protected byte[] |
m_Response
The 24-byte response.
|
protected int |
m_Type
The response type, enumerated.
|
static int |
TYPE_LMSESSIONKEY
Indicates an SMB LM session key type of response.
|
static int |
TYPE_NTSESSIONKEY
Indicates an SMB NT session key type of response.
|
static int |
TYPE_UNKNOWN
Indicates an unknown type of response.
|
Constructor and Description |
---|
ChallengeResponseCredential()
Constructs a ChallengeResponseCredential.
|
ChallengeResponseCredential(String name,
byte[] challenge,
byte[] response,
int type)
Constructs a ChallengeResponseCredential.
|
Modifier and Type | Method and Description |
---|---|
byte[] |
getChallenge()
Gets the challenge.
|
String |
getName()
Gets the name of the user.
|
byte[] |
getResponse()
Gets the response.
|
int |
getType()
Gets the type of the response.
|
void |
setChallenge(byte[] challenge)
Sets the challenge.
|
void |
setName(String name)
Sets the name of the user.
|
void |
setResponse(byte[] response)
Sets the response.
|
void |
setType(int type)
Sets the type of the response.
|
public static final int TYPE_UNKNOWN
public static final int TYPE_NTSESSIONKEY
public static final int TYPE_LMSESSIONKEY
protected String m_Name
protected byte[] m_Challenge
protected byte[] m_Response
protected int m_Type
public ChallengeResponseCredential() throws IfsException
IfsException
- if the operation failspublic ChallengeResponseCredential(String name, byte[] challenge, byte[] response, int type) throws IfsException
name
- the name of the userchallenge
- the 8-byte challengeresponse
- the 24-byte responsetype
- the type of the responseIfsException
- if the operation failspublic String getName() throws IfsException
getName
in interface Credential
IfsException
- (IFS-10187) if the operation failspublic void setName(String name) throws IfsException
setName
in interface Credential
name
- the name of the userIfsException
- (IFS-10188) if the operation failspublic byte[] getChallenge() throws IfsException
IfsException
- if the operation failspublic void setChallenge(byte[] challenge) throws IfsException
challenge
- the 8-byte challengeIfsException
- if the operation failspublic byte[] getResponse() throws IfsException
IfsException
- if the operation failspublic void setResponse(byte[] response) throws IfsException
response
- the 24-byte responseIfsException
- if the operation failspublic int getType() throws IfsException
IfsException
- if the operation failspublic void setType(int type) throws IfsException
type
- the type; must be either
TYPE_NTSESSIONKEY
or
TYPE_LMSESSIONKEY
IfsException
- if the operation failsCopyright © 2023. All rights reserved.