version 1.41, 2008/12/16 18:55:59
|
version 1.41.8.3, 2014/04/28 00:29:12
|
|
|
#include <Pegasus/Common/Linkage.h> | #include <Pegasus/Common/Linkage.h> |
#include <Pegasus/Common/SSLContext.h> | #include <Pegasus/Common/SSLContext.h> |
| |
#ifdef PEGASUS_KERBEROS_AUTHENTICATION |
|
#include <Pegasus/Common/CIMKerberosSecurityAssociation.h> |
|
#endif |
|
| |
PEGASUS_NAMESPACE_BEGIN | PEGASUS_NAMESPACE_BEGIN |
| |
|
|
/** | /** |
This class keeps the authentication information of a connection | This class keeps the authentication information of a connection |
persistent until the connection is destroyed. | persistent until the connection is destroyed. |
|
|
/** Constructor - Instantiates a AuthenticationInfo object. | /** Constructor - Instantiates a AuthenticationInfo object. |
@param flag - used only to distinguish from the default constructor. | @param flag - used only to distinguish from the default constructor. |
*/ | */ |
AuthenticationInfo(Boolean flag) |
AuthenticationInfo(Boolean) |
{ | { |
PEG_METHOD_ENTER( | PEG_METHOD_ENTER( |
TRC_AUTHENTICATION, "AuthenticationInfo::AuthenticationInfo"); | TRC_AUTHENTICATION, "AuthenticationInfo::AuthenticationInfo"); |
| |
_rep = new AuthenticationInfoRep(flag); |
_rep = new AuthenticationInfoRep(); |
| |
PEG_METHOD_EXIT(); | PEG_METHOD_EXIT(); |
} | } |
|
|
} | } |
| |
| |
#ifdef PEGASUS_KERBEROS_AUTHENTICATION |
|
/** Get the CIM Security Association |
|
@return a pointer to the CIM Security Association |
|
*/ |
|
CIMKerberosSecurityAssociation* getSecurityAssociation() const |
|
{ |
|
CheckRep(_rep); |
|
return _rep->getSecurityAssociation(); |
|
} |
|
|
|
/** Set the CIM Security Association |
|
The pointer will only be set once. If it is already set it will |
|
not reset it. |
|
*/ |
|
void setSecurityAssociation() |
|
{ |
|
CheckRep(_rep); |
|
_rep->setSecurityAssociation(); |
|
} |
|
#endif |
|
|
|
Array<SSLCertificateInfo*> getClientCertificateChain() | Array<SSLCertificateInfo*> getClientCertificateChain() |
{ | { |
CheckRep(_rep); | CheckRep(_rep); |
|
|
return _rep->getRemotePrivilegedUserAccessChecked(); | return _rep->getRemotePrivilegedUserAccessChecked(); |
} | } |
| |
|
void setAuthHandle(const AuthHandle & authHandle) |
|
{ |
|
CheckRep(_rep); |
|
_rep->setAuthHandle(authHandle); |
|
} |
|
|
|
AuthHandle getAuthHandle() |
|
{ |
|
CheckRep(_rep); |
|
return _rep->getAuthHandle(); |
|
} |
|
|
|
void setUserRole(const String & userRole) |
|
{ |
|
CheckRep(_rep); |
|
_rep->setUserRole(userRole); |
|
} |
|
|
|
String getUserRole() |
|
{ |
|
CheckRep(_rep); |
|
return _rep->getUserRole(); |
|
} |
|
|
|
void setExpiredPassword(Boolean status) |
|
{ |
|
CheckRep(_rep); |
|
_rep->setExpiredPassword(status); |
|
} |
|
|
|
Boolean isExpiredPassword() const |
|
{ |
|
CheckRep(_rep); |
|
return _rep->isExpiredPassword(); |
|
} |
|
|
private: | private: |
| |
AuthenticationInfo(AuthenticationInfoRep* rep) : _rep(rep) | AuthenticationInfo(AuthenticationInfoRep* rep) : _rep(rep) |