williamr@2: /* williamr@2: * Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). williamr@2: * All rights reserved. williamr@2: * This component and the accompanying materials are made available williamr@2: * under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members williamr@2: * which accompanies this distribution, and is available williamr@2: * at the URL "http://www.symbianfoundation.org/legal/licencesv10.html". williamr@2: * williamr@2: * Initial Contributors: williamr@2: * Nokia Corporation - initial contribution. williamr@2: * williamr@2: * Contributors: williamr@2: * williamr@2: * Description: This header provides SOAP specific constants. williamr@2: * williamr@2: */ williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: #ifndef SEN_SOAP_CONSTANTS_H williamr@2: #define SEN_SOAP_CONSTANTS_H williamr@2: williamr@2: // CONSTANTS williamr@2: williamr@2: /// Envelope: williamr@2: _LIT8(KSenSoap12ContentTypeHeaderValue, "application/soap+xml; charset=utf-8"); williamr@2: _LIT8(KSenSoap12AcceptHeaderValue, "application/soap+xml"); williamr@2: _LIT8(KSenSoapEnvelopeName, "Envelope"); williamr@2: _LIT8(KSenSoapEnvelopePrefix, "S"); williamr@2: _LIT8(KSenSoapEnvelopeQName, "S:Envelope"); williamr@2: williamr@2: _LIT8(KSenSoapEnvelopeXmlns, "http://schemas.xmlsoap.org/soap/envelope/"); williamr@2: _LIT8(KSenSoap12EnvelopeXmlns, "http://www.w3.org/2003/05/soap-envelope"); williamr@2: _LIT8(KSenSoapEnvelopeHeaderName, "Header"); williamr@2: _LIT8(KSenSoapEnvelopeHeaderQName, "S:Header"); williamr@2: _LIT8(KSenSoapEnvelopeBodyName, "Body"); williamr@2: _LIT8(KSenSoapEnvelopeBodyQName, "S:Body"); williamr@2: _LIT8(KSenSoapFaultName, "Fault"); williamr@2: williamr@2: /// Action williamr@2: _LIT8(KSenSoapActionHeaderName, "SOAPAction"); williamr@2: _LIT8(KSenSoapActionHeaderValueEmpty, "\"\""); williamr@2: williamr@2: /// Security williamr@2: _LIT8(KSecurityName, "Security"); williamr@2: _LIT8(KBinarySecurityToken, "BinarySecurityToken"); williamr@2: _LIT8(KSecurityXmlNs, "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"); williamr@2: _LIT8(KSecuritySchemeXmlNs, "http://schemas.xmlsoap.org/ws/2003/06/secext"); williamr@2: _LIT8(KSecurityXmlNsPrefix, "wsse"); williamr@2: williamr@2: _LIT8(KSecurityAttrType, "Type"); // name of the XML attribute williamr@2: _LIT8(KSecurityAttrTypeText, "PasswordText"); // for default type: wsse:PasswordText williamr@2: _LIT8(KSecurityAttrTypeDigest, "PasswordDigest"); // digest type: wsse:Digest williamr@2: williamr@2: _LIT8(KSecurityTokenReference, "SecurityTokenReference"); williamr@2: _LIT8(KSecurityUtilityXmlNs, "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"); williamr@2: _LIT8(KSecurityUtilityXmlNsPrefix, "wsu"); williamr@2: williamr@2: _LIT8(KSecurityUtilityId, "Id"); williamr@2: _LIT8(KSecurityUtilityWsuId, "wsu:Id"); williamr@2: williamr@2: williamr@2: const TInt KStateParsingSoapHeader = 20; // ignore state (even number) williamr@2: const TInt KStateParsingSoapBody = 40; // ignore state (even number) williamr@2: const TInt KStateParsingSoapFault = 5; // save state (odd number) williamr@2: williamr@2: /// Fault williamr@2: // CONSTANTS williamr@2: _LIT8(KFaultCodeLocalname, "faultcode"); // "faultcode" is intended for use by software to williamr@2: // provide an algorithmic mechanism for williamr@2: // identifying the fault. williamr@2: williamr@2: _LIT8(KFaultStringLocalname, "faultstring"); // "faultstring" is intended to provide a human williamr@2: // readable explanation of the fault and is not williamr@2: // intended for algorithmic processing. williamr@2: williamr@2: _LIT8(KFaultActorLocalname, "faultactor"); // "faultactor" is intended to provide information williamr@2: // about which SOAP node on the SOAP message path williamr@2: // caused the fault to happen. williamr@2: // The value of the "faultactor" is a URI williamr@2: // identifying the source of the fault. williamr@2: williamr@2: _LIT8(KDetailLocalname, "detail"); // "detail" is intended for carrying application williamr@2: // specific error information related to the SOAP williamr@2: // Body. It MUST be present when the contents of williamr@2: // the SOAP Body could not be processed williamr@2: // successfully. williamr@2: williamr@2: // SOAP 1.2 (http://www.w3.org/TR/soap12-part1/): williamr@2: _LIT8(KFault12CodeLocalname, "Code"); // "Code" has a mandatory "Value" element williamr@2: // information item and may have an optional williamr@2: // Subcode element information item. williamr@2: williamr@2: _LIT8(KFault12SubcodeLocalname, "Subcode"); // "Subcode" has a mandatory "Value" element williamr@2: // information item and may have an optional williamr@2: // Subcode element information item. williamr@2: williamr@2: _LIT8(KFault12ValueLocalname, "Value"); // In "Code" element: williamr@2: // The type of the Value element information williamr@2: // item is env:faultCodeEnum. SOAP defines a williamr@2: // small set of SOAP fault codes covering high williamr@2: // level SOAP faults. williamr@2: // In "Subcode" element: williamr@2: // The type of the Value element information williamr@2: // item is xs:QName. The value of this element williamr@2: // is an application defined subcategory of williamr@2: // the value of the Value child element williamr@2: // information item of the Subcode element williamr@2: // information item's parent element information williamr@2: // item. williamr@2: williamr@2: _LIT8(KFault12ReasonLocalname, "Reason"); // "Reason" has one or more "Text" element williamr@2: // information item children. Each child "Text" williamr@2: // element information item SHOULD have a williamr@2: // different value for its "xml:lang" attribute williamr@2: // information item. williamr@2: williamr@2: _LIT8(KFault12TextLocalname, "Text"); // "Text" has a mandatory attribute information williamr@2: // item with a [local name] of lang and williamr@2: // [namespace name] of williamr@2: // "http://www.w3.org/XML/1998/namespace". williamr@2: // Note that the definition in of the lang williamr@2: // attribute information item requires that the williamr@2: // [prefix] is "xml" or any capitalization thereof. williamr@2: // williamr@2: // "Text" is similar to the 'Reason-Phrase' defined williamr@2: // by HTTP [RFC 2616] and SHOULD provide williamr@2: // information explaining the nature of the fault. williamr@2: // It is not intended for algorithmic processing. williamr@2: williamr@2: _LIT8(KFault12NodeLocalname, "Node"); // "Node" is intended to provide information about williamr@2: // which SOAP node on the SOAP message path caused williamr@2: // the fault to happen. williamr@2: // "Node" contains the URI of the SOAP node that williamr@2: // generated the fault. williamr@2: williamr@2: _LIT8(KFault12DetailLocalname, "Detail"); // "Detail" MAY be present in a SOAP fault in williamr@2: // which case it carries additional information williamr@2: // relative to the SOAP fault codes describing williamr@2: // the fault. For example, the Detail element williamr@2: // information item might contain information about williamr@2: // a message not containing the proper credentials, williamr@2: // a timeout, etc. The presence of the Detail williamr@2: // element information item has no significance as williamr@2: // to which parts of the faulty SOAP message were williamr@2: // processed. williamr@2: williamr@2: // SOAP Fault Codes in SOAP 1.2 (http://www.w3.org/TR/soap12-part1/): williamr@2: _LIT8(KDataEncodingUnknown, "DataEncodingUnknown"); williamr@2: // A SOAP header block or SOAP body child element williamr@2: // information item targeted at the faulting SOAP williamr@2: // node is scoped (see 5.1.1 SOAP encodingStyle williamr@2: // Attribute) with a data encoding that the williamr@2: // faulting node does not support. williamr@2: williamr@2: _LIT8(KMustUnderstand, "MustUnderstand"); williamr@2: // An immediate child element information item of williamr@2: // the SOAP Header element information item williamr@2: // targeted at the faulting node that was not williamr@2: // understood by the faulting node contained a SOAP williamr@2: // mustUnderstand attribute information item with a williamr@2: // value of "true". williamr@2: williamr@2: _LIT8(KReceiver, "Receiver"); // The message could not be processed for reasons williamr@2: // attributable to the processing of the message williamr@2: // rather than to the contents of the message williamr@2: // itself. For example, processing could include williamr@2: // communicating with an upstream SOAP node, which williamr@2: // did not respond. The message could succeed if williamr@2: // resent at a later point in time. williamr@2: williamr@2: _LIT8(KSender, "Sender"); // The message was incorrectly formed or did not williamr@2: // contain the appropriate information in order to williamr@2: // succeed. For example, the message could lack the williamr@2: // proper authentication or payment information. It williamr@2: // is generally an indication that the message is williamr@2: // not to be resent without change. williamr@2: williamr@2: _LIT8(KVersionMismatch, "VersionMismatch"); williamr@2: // The faulting node found an invalid element williamr@2: // information item instead of the expected williamr@2: // Envelope element information item. The namespace, williamr@2: // local name or both did not match the Envelope williamr@2: // element information item required by this williamr@2: // recommendation. williamr@2: williamr@2: enum TSOAPVersion williamr@2: { williamr@2: ESOAP11 = 1, williamr@2: ESOAP12 williamr@2: }; williamr@2: williamr@2: #endif // SEN_SOAP_CONSTANTS_H williamr@2: williamr@2: williamr@2: williamr@2: