com.cafesoft.core.message
Class AuthStatus

java.lang.Object
  |
  +--com.cafesoft.core.message.AuthStatus

public class AuthStatus
extends Object

The AuthStatus object is the response object returned from the Authenticator object when an authentication attempt is made.

Since:
4/8/02

Field Summary
static int RC_ACCESS_DENIED
          Reason Code: Access was denied by the server.
static int RC_AUTHENTICATOR_ERROR
          Reason Code: There was an error on the server that did not allow authentication.
static int RC_GENERAL_SERVER_ERROR
          Reason Code: General Server Error, probably due to a misconfiguration.
static int RC_INVALID_CREDENTIAL
          Reason Code: The credential was not valid.
static int RC_INVALID_REMOTE_HOST_NAME
          Reason Code: The remote host name is not valid.
static int RC_INVALID_REMOTE_IP_ADDRESS
          Reason Code: The remote host IP address is not valid.
static int RC_MISSING_CREDENTIAL
          Reason Code: A principal was missing a required credential.
static int RC_MISSING_PRINCIPAL
          Reason Code: A principal was missing (and it was required).
static int RC_NOT_APPLICABLE
          Reason Code: Not Applicable (because authentication is pending)
static int RC_UNKNOWN_AUTH_TYPE
          Reason Code: An unknown authentication type was used
static int RC_UNKNOWN_CREDENTIAL_TYPE
          Reason Code: The credential type was not recognized.
static int RC_UNKNOWN_PRINCIPAL
          Reason Code: An unrecognized principal was specified.
static int SC_AUTH_FAILURE
          Status Code indicating that authentication failed.
static int SC_AUTH_PENDING
          Status Code indicating that authentication is in progress.
static int SC_AUTH_SUCCESS
          Status Code indicating that authentication succeeded.
 
Constructor Summary
AuthStatus()
          Create an AuthStatus with no additional information
AuthStatus(int status, int reason, String message)
          Create an AuthStatus object with a status and reason code and a message.
 
Method Summary
 String getMessage()
          Get the Message
 int getReason()
          Get the Reason Code
 int getStatus()
          Get the Status Code
 void readAuthStatusPacket(Packet packet)
          KRJ - doc
 void setMessage(String message)
          Set the Message
 void setReason(int reason)
          Set the Reason Code
 void setStatus(int status)
          Set the Status Code
 String toString()
          KRJ - doc
 void writeAuthStatusPacket(Packet packet)
          KRJ - doc
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

SC_AUTH_PENDING

public static final int SC_AUTH_PENDING
Status Code indicating that authentication is in progress.

See Also:
Constant Field Values

SC_AUTH_SUCCESS

public static final int SC_AUTH_SUCCESS
Status Code indicating that authentication succeeded.

See Also:
Constant Field Values

SC_AUTH_FAILURE

public static final int SC_AUTH_FAILURE
Status Code indicating that authentication failed.

See Also:
Constant Field Values

RC_NOT_APPLICABLE

public static final int RC_NOT_APPLICABLE
Reason Code: Not Applicable (because authentication is pending)

See Also:
Constant Field Values

RC_MISSING_PRINCIPAL

public static final int RC_MISSING_PRINCIPAL
Reason Code: A principal was missing (and it was required).

See Also:
Constant Field Values

RC_MISSING_CREDENTIAL

public static final int RC_MISSING_CREDENTIAL
Reason Code: A principal was missing a required credential.

See Also:
Constant Field Values

RC_UNKNOWN_PRINCIPAL

public static final int RC_UNKNOWN_PRINCIPAL
Reason Code: An unrecognized principal was specified.

See Also:
Constant Field Values

RC_INVALID_CREDENTIAL

public static final int RC_INVALID_CREDENTIAL
Reason Code: The credential was not valid.

See Also:
Constant Field Values

RC_UNKNOWN_CREDENTIAL_TYPE

public static final int RC_UNKNOWN_CREDENTIAL_TYPE
Reason Code: The credential type was not recognized.

See Also:
Constant Field Values

RC_AUTHENTICATOR_ERROR

public static final int RC_AUTHENTICATOR_ERROR
Reason Code: There was an error on the server that did not allow authentication.

See Also:
Constant Field Values

RC_UNKNOWN_AUTH_TYPE

public static final int RC_UNKNOWN_AUTH_TYPE
Reason Code: An unknown authentication type was used

See Also:
Constant Field Values

RC_ACCESS_DENIED

public static final int RC_ACCESS_DENIED
Reason Code: Access was denied by the server.

See Also:
Constant Field Values

RC_GENERAL_SERVER_ERROR

public static final int RC_GENERAL_SERVER_ERROR
Reason Code: General Server Error, probably due to a misconfiguration.

See Also:
Constant Field Values

RC_INVALID_REMOTE_IP_ADDRESS

public static final int RC_INVALID_REMOTE_IP_ADDRESS
Reason Code: The remote host IP address is not valid.

See Also:
Constant Field Values

RC_INVALID_REMOTE_HOST_NAME

public static final int RC_INVALID_REMOTE_HOST_NAME
Reason Code: The remote host name is not valid.

See Also:
Constant Field Values
Constructor Detail

AuthStatus

public AuthStatus()
Create an AuthStatus with no additional information


AuthStatus

public AuthStatus(int status,
                  int reason,
                  String message)
Create an AuthStatus object with a status and reason code and a message.

Parameters:
status - the status code
reason - the reason code
message - the message of the AuthStatus
Method Detail

getStatus

public int getStatus()
Get the Status Code

Returns:
the status code

getReason

public int getReason()
Get the Reason Code

Returns:
the reason code

getMessage

public String getMessage()
Get the Message

Returns:
the message

setStatus

public void setStatus(int status)
Set the Status Code

Parameters:
status - the new Status code

setReason

public void setReason(int reason)
Set the Reason Code

Parameters:
reason - the new Reason code

setMessage

public void setMessage(String message)
Set the Message

Parameters:
message - the new message

toString

public String toString()
KRJ - doc

Overrides:
toString in class Object
Returns:
KRJ

writeAuthStatusPacket

public void writeAuthStatusPacket(Packet packet)
                           throws MessageServiceException
KRJ - doc

Parameters:
packet - KRJ
Throws:
MessageServiceException - KRJ

readAuthStatusPacket

public void readAuthStatusPacket(Packet packet)
                          throws MessageServiceException
KRJ - doc

Parameters:
packet - KRJ
Throws:
MessageServiceException - KRJ


Generated on 10:40:31 AM September 10, 2003, © 1996-2003 Cafésoft LLC. All rights reserved.