00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #ifndef SEN_WS_SECURITY_HEADER2_H
00024 #define SEN_WS_SECURITY_HEADER2_H
00025
00026
00027 #include <SenFragmentBase.h>
00028 #include <SenSoapConstants.h>
00029
00030
00031 class CSenIdentityProvider;
00032
00033
00034
00041 class CSenWsSecurityHeader2 : public CSenFragmentBase
00042 {
00043 public:
00044
00048 enum TPasswordType
00049 {
00050 EText = 1,
00051 EDigest
00052 };
00053
00054
00062 IMPORT_C static CSenWsSecurityHeader2* NewL(RSenDocument aDocument,
00063 TXmlEngElement aElement);
00064
00073 IMPORT_C static CSenWsSecurityHeader2* NewLC(RSenDocument aDocument,
00074 TXmlEngElement aElement);
00075
00084 IMPORT_C static CSenWsSecurityHeader2* NewL(const TDesC8& aData,
00085 RSenDocument aDocument,
00086 TXmlEngElement aElement);
00087
00097 IMPORT_C static CSenWsSecurityHeader2* NewLC(const TDesC8& aData,
00098 RSenDocument aDocument,
00099 TXmlEngElement aElement);
00100
00110 IMPORT_C static CSenWsSecurityHeader2* NewL(const TDesC8& aData,
00111 const TDesC8& aSecurityNs,
00112 RSenDocument aDocument,
00113 TXmlEngElement aElement);
00114
00125 IMPORT_C static CSenWsSecurityHeader2* NewLC(const TDesC8& aData,
00126 const TDesC8& aSecurityNs,
00127 RSenDocument aDocument,
00128 TXmlEngElement aElement);
00129
00133 IMPORT_C virtual ~CSenWsSecurityHeader2();
00134
00135
00136
00158 IMPORT_C HBufC8* UsernameTokenL(CSenIdentityProvider &aIdentityProvider);
00159
00194 IMPORT_C HBufC8* UsernameTokenL(CSenIdentityProvider &aIdentityProvider,
00195 CSenWsSecurityHeader2::TPasswordType aType);
00196
00197
00198
00210 IMPORT_C static TInt UsernameTokenL(const TDesC8& aUsername,
00211 HBufC8*& aToken);
00212
00227 IMPORT_C static TInt UsernameTokenL(const TDesC8& aUsername,
00228 const TDesC8& aPassword,
00229 HBufC8*& aToken);
00230
00259 IMPORT_C static TInt UsernameTokenL(const TDesC8& aUsername,
00260 const TDesC8& aPassword,
00261 CSenWsSecurityHeader2::TPasswordType aType,
00262 HBufC8*& aToken);
00263
00264
00281 IMPORT_C static TInt TimestampL(const TDesC8& aCreated, const TDesC8& aExpires, HBufC8*& aTimestamp);
00282
00297 IMPORT_C static TInt TimestampL(const TDesC8& aCreated, HBufC8*& aTimestamp);
00298
00314
00315
00316
00317
00318
00324 IMPORT_C virtual TPtrC8 XmlNs();
00325
00332 IMPORT_C virtual TPtrC8 XmlNsPrefix();
00333
00334 protected:
00335
00339 IMPORT_C CSenWsSecurityHeader2();
00340
00344 IMPORT_C void BaseConstructL(RSenDocument aDocument,
00345 TXmlEngElement aElement);
00346
00347
00348
00358 IMPORT_C void BaseConstructL(const TDesC8& aData,
00359 RSenDocument aDocument,
00360 TXmlEngElement aElement);
00361
00372 IMPORT_C void BaseConstructL(const TDesC8& aData,
00373 const TDesC8& aSecurityNs,
00374 RSenDocument aDocument,
00375 TXmlEngElement aElement);
00376 };
00377
00378 #endif // SEN_WS_SECURITY_HEADER2_H
00379
00380