public class ScramSession extends Object
Modifier and Type | Class and Description |
---|---|
class |
ScramSession.ClientFinalProcessor
Processor that allows to generate the client-final-message,
as well as process the server-final-message and verify server's signature.
|
class |
ScramSession.ServerFirstProcessor
Process a received server-first-message.
|
Constructor and Description |
---|
ScramSession(ScramMechanism scramMechanism,
StringPreparation stringPreparation,
String user,
String nonce)
Constructs a SCRAM client, to perform an authentication for a given user.
|
Modifier and Type | Method and Description |
---|---|
String |
clientFirstMessage()
Returns the text representation of a SCRAM client-first-message, with no channel binding nor authzid.
|
String |
clientFirstMessage(Gs2CbindFlag gs2CbindFlag,
String cbindName,
String authzid)
Returns the text representation of a SCRAM client-first-message, with the GSS-API header values indicated.
|
ScramSession.ServerFirstProcessor |
receiveServerFirstMessage(String serverFirstMessage)
Constructs a handler for the server-first-message, from its String representation.
|
public ScramSession(ScramMechanism scramMechanism, StringPreparation stringPreparation, String user, String nonce)
ScramClient
is used instead.scramMechanism
- The SCRAM mechanism that will be using this clientstringPreparation
- user
- nonce
- public String clientFirstMessage(Gs2CbindFlag gs2CbindFlag, String cbindName, String authzid)
gs2CbindFlag
- The channel binding flagcbindName
- The channel binding algorithm name, if channel binding is supported, or nullauthzid
- The optionalpublic String clientFirstMessage()
public ScramSession.ServerFirstProcessor receiveServerFirstMessage(String serverFirstMessage) throws ScramParseException, IllegalArgumentException
serverFirstMessage
- The messageScramParseException
- If the message is not a valid server-first-messageIllegalArgumentException
- If the message is null or emptyCopyright © 2019–2024. All rights reserved.