javax.management.remote.message
Class SASLMessage

java.lang.Object
  extended by javax.management.remote.message.SASLMessage
All Implemented Interfaces:
Serializable, Message, ProfileMessage

public class SASLMessage
extends Object
implements ProfileMessage

A challenge or response exchanged between client and server during SASL authentication. This message encapsulates either a challenge or a response generated by the SASL mechanism during the SASL authentication exchanges taking place between the client and the server.

The challenges/responses (blobs) are generated by the SASL mechanism:

The status attribute takes one of the two values: At any time during the SASL handshake, if the server encounters a problem it can notify the client by sending an indication as to why the operation failed.

At any time during the SASL handshake, if the client encounters a problem or wants to abort the authentication exchange it can notify the server by sending an indication as to why the operation failed or is aborted.

The profile name in this profile message is built by concatenating the prefix "SASL/" with the SASL mechanism name provided by the IANA SASL registry.

Examples of SASL profile names are:

See Also:
HandshakeBeginMessage, Serialized Form

Field Summary
static int COMPLETE
          This status code is used by a server to indicate that the authentication exchange is complete and successful.
static int CONTINUE
          This status code is used by either a client or server to indicate that they require more interaction with the other peer in order to complete the authentication exchange.
 
Constructor Summary
SASLMessage(String mechanism, int status, byte[] blob)
          Constructs a new SASLMessage with the specified SASL mechanism, status and generated blob.
 
Method Summary
 byte[] getBlob()
          The blob generated by the SASL mechanism.
 String getMechanism()
          The SASL mechanism.
 String getProfileName()
          The profile name.
 int getStatus()
          The status of the current SASL authentication exchanges.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONTINUE

public static final int CONTINUE
This status code is used by either a client or server to indicate that they require more interaction with the other peer in order to complete the authentication exchange.

See Also:
Constant Field Values

COMPLETE

public static final int COMPLETE
This status code is used by a server to indicate that the authentication exchange is complete and successful.

See Also:
Constant Field Values
Constructor Detail

SASLMessage

public SASLMessage(String mechanism,
                   int status,
                   byte[] blob)
Constructs a new SASLMessage with the specified SASL mechanism, status and generated blob.

Parameters:
mechanism - the SASL mechanism
status - the status of the current SASL authentication exchanges.
blob - the blob generated by the SASL mechanism.
Method Detail

getMechanism

public String getMechanism()
The SASL mechanism.

Returns:
the SASL mechanism.

getStatus

public int getStatus()
The status of the current SASL authentication exchanges.

Returns:
the status of the current SASL authentication exchanges.
See Also:
CONTINUE, COMPLETE

getBlob

public byte[] getBlob()
The blob generated by the SASL mechanism.

Returns:
the blob generated by the SASL mechanism.

getProfileName

public String getProfileName()
The profile name.

Specified by:
getProfileName in interface ProfileMessage
Returns:
the profile name.

Open Source build 02
opendmk-1.0-b02 2007.10.01_19:17:46_MEST

Copyright 1998-2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.