version 1.31, 2006/11/10 18:14:57
|
version 1.34, 2007/03/16 18:22:30
|
|
|
{ | { |
public: | public: |
| |
/** Constructor - Creates an uninitiated new AuthenticationInfo |
/** Constructor - Creates an uninitialized new AuthenticationInfo |
object reprenting a AuthenticationInfo class. The class object |
object representing an AuthenticationInfo class. The class object |
created by this constructor can only be used in an operation such as the | created by this constructor can only be used in an operation such as the |
copy constructor. It cannot be used to do method calls like |
copy constructor. It cannot be used to do method calls such as |
setAuthStatus, getAuthType, etc. since it is unitiated. |
getAuthType, since it is uninitialized. |
| |
Use one of the other constructors to create an initiated new | Use one of the other constructors to create an initiated new |
AuthenticationInfo class object. Throws an exception | AuthenticationInfo class object. Throws an exception |
|
|
PEG_METHOD_EXIT(); | PEG_METHOD_EXIT(); |
} | } |
| |
/** Get the authentication status of the request |
/** Sets the connection authentication status of the request to the |
@return the current authentication status |
status specified. |
*/ |
|
AuthenticationInfoRep::AuthStatus getAuthStatus() const |
|
{ |
|
_checkRep(); |
|
return _rep->getAuthStatus(); |
|
} |
|
|
|
/** Sets the authentication status of the request to the status |
|
specified. |
|
@param status - the new authentication status | @param status - the new authentication status |
*/ | */ |
void setAuthStatus(AuthenticationInfoRep::AuthStatus status) |
void setConnectionAuthenticated(Boolean status) |
{ | { |
_checkRep(); | _checkRep(); |
_rep->setAuthStatus(status); |
_rep->setConnectionAuthenticated(status); |
} | } |
| |
/** Get the previously authenticated user name | /** Get the previously authenticated user name |
|
|
_rep->setAuthenticatedPassword(password); | _rep->setAuthenticatedPassword(password); |
} | } |
| |
/** Get the authentication challenge that was sent to the client |
/** Get the local authentication secret that was sent to client |
@return string containing the authentication challenge |
|
*/ |
|
String getAuthChallenge() const |
|
{ |
|
_checkRep(); |
|
return _rep->getAuthChallenge(); |
|
} |
|
|
|
/** Sets the authentication challenge to the specified challenge |
|
@param challenge - string containing the authentication challenge |
|
*/ |
|
void setAuthChallenge(const String& challenge) |
|
{ |
|
_checkRep(); |
|
_rep->setAuthChallenge(challenge); |
|
} |
|
|
|
/** Get the authentication secret that was sent to client |
|
@return string containing the authentication secret | @return string containing the authentication secret |
*/ | */ |
String getAuthSecret() const |
String getLocalAuthSecret() const |
{ | { |
_checkRep(); | _checkRep(); |
return _rep->getAuthSecret(); |
return _rep->getLocalAuthSecret(); |
} | } |
| |
/** Set the authentication secret to the specified secret |
/** Set the local authentication secret to the specified secret |
@param secret - string containing the authentication secret | @param secret - string containing the authentication secret |
*/ | */ |
void setAuthSecret(const String& secret) |
void setLocalAuthSecret(const String& secret) |
{ |
|
_checkRep(); |
|
_rep->setAuthSecret(secret); |
|
} |
|
|
|
/** Returns the connection type of the previous authenticated request |
|
@return true if the connection is privileged, false otherwise |
|
*/ |
|
Boolean isPrivileged() const |
|
{ |
|
_checkRep(); |
|
return _rep->isPrivileged(); |
|
} |
|
|
|
/** Set the privileged flag to the specified value |
|
@param privileged - boolean flag indicating the connection type |
|
*/ |
|
void setPrivileged(Boolean privileged) |
|
{ | { |
_checkRep(); | _checkRep(); |
_rep->setPrivileged(privileged); |
_rep->setLocalAuthSecret(secret); |
} | } |
| |
/** Is the request authenticated | /** Is the request authenticated |
|
|
/** Returns the authentication status of the current connection. | /** Returns the authentication status of the current connection. |
@return true if the connection was authenticated, false otherwise | @return true if the connection was authenticated, false otherwise |
*/ | */ |
Boolean isAuthenticated() const |
Boolean isConnectionAuthenticated() const |
{ | { |
_checkRep(); | _checkRep(); |
return _rep->isAuthenticated(); |
return _rep->isConnectionAuthenticated(); |
} | } |
| |
/** Set the authentication type to the specified type | /** Set the authentication type to the specified type |