oxs_constants.h

Go to the documentation of this file.
00001 /*
00002  * Copyright 2004,2005 The Apache Software Foundation.
00003  *
00004  * Licensed under the Apache License, Version 2.0 (the "License")" "
00005  * you may not use this file except in compliance with the License.
00006  * You may obtain a copy of the License at
00007  *
00008  *      http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
00015  */
00016 
00022 #ifndef OXS_CONSTANTS_H
00023 #define OXS_CONSTANTS_H
00024 
00025 #ifdef __cplusplus
00026 extern "C"
00027 {
00028 #endif
00029 
00040     /*Default values*/
00041     /*Key transfer algo*/
00042 #define OXS_DEFAULT_KT_ALGO_HREF    OXS_HREF_RSA_PKCS1
00043 #define OXS_DEFAULT_SYM_ALGO        OXS_HREF_AES_256_CBC
00044 #define OXS_STR_DEFAULT             OXS_STR_EMBEDDED
00045 
00046 
00047     /****************************************************************
00048        Global prefixes 
00049     ****************************************************************/
00050 #define OXS_XENC "xenc"
00051 #define OXS_DS "ds"
00052 #define OXS_WSSE "wsse"
00053 #define OXS_WSSE_11 "wsse11"
00054 #define OXS_WSU "wsu"
00055 #define OXS_WSC "wsc"
00056 #define OXS_WSSE_XMLNS      "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
00057 #define OXS_WSSE_11_XMLNS   "http://docs.oasis-open.org/wss/oasis-wss-wssecurity-secext-1.1.xsd"
00058 #define OXS_WSU_XMLNS "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
00059     /****************************************************************
00060         ID Prefixes
00061     ****************************************************************/
00062 #define OXS_ENCDATA_ID "EncDataID"
00063 #define OXS_ENCKEY_ID "EncKeyID"
00064 #define OXS_SIG_ID "SigID"
00065 #define OXS_CERT_ID "CertID"
00066 #define OXS_EMBEDDED_ID "EmbeddedID"
00067 #define OXS_DERIVED_ID "DKID"
00068 #define OXS_SIG_CONF_ID "SigConfID"
00069 #define OXS_LOCAL_REFERENCE_PREFIX "#"
00070 
00071     /****************************************************************
00072        Global namespaces 
00073     ****************************************************************/
00074 #define OXS_DSIG_NS                "http://www.w3.org/2000/09/xmldsig#"
00075 #define OXS_ENC_NS                 "http://www.w3.org/2001/04/xmlenc#"
00076 /*#define OXS_WSSE_NS                "http://schemas.xmlsoap.org/ws/2002/04/secext"*/
00077 #define OXS_WSSE_NS                "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
00078 #define OXS_WSC_NS_05_02 "http://schemas.xmlsoap.org/ws/2005/02/sc"
00079 #define OXS_WSC_NS_05_12 "http://docs.oasis-open.org/ws-sx/ws-secureconversation/200512"
00080 
00081     /****************************************************************
00082         DSig Nodes  
00083     ****************************************************************/
00084 #define OXS_NODE_SIGNATURE         "Signature"
00085 #define OXS_NODE_SIGNEDINFO        "SignedInfo"
00086 #define OXS_NODE_CANONICALIZATION_METHOD "CanonicalizationMethod"
00087 #define OXS_NODE_SIGNATURE_METHOD    "SignatureMethod"
00088 #define OXS_NODE_SIGNATURE_VALUE     "SignatureValue"
00089 #define OXS_NODE_DIGEST_METHOD       "DigestMethod"
00090 #define OXS_NODE_DIGEST_VALUE        "DigestValue"
00091 #define OXS_NODE_OBJECT             "Object"
00092 #define OXS_NODE_MANIFEST           "Manifest"
00093 #define OXS_NODE_SIGNATUREPROPERTIES "SignatureProperties"
00094 #define OXS_NODE_SIGNATURE_CONFIRMATION "SignatureConfirmation" /*SOAP 11*/
00095 
00096     /****************************************************************
00097        Encryption Nodes 
00098     ****************************************************************/
00099 #define OXS_NODE_ENCRYPTED_DATA             "EncryptedData"
00100 #define OXS_NODE_ENCRYPTION_METHOD          "EncryptionMethod"
00101 #define OXS_NODE_ENCRYPTION_PROPERTIES      "EncryptionProperties"
00102 #define OXS_NODE_ENCRYPTION_PROPERTY        "EncryptionProperty"
00103 #define OXS_NODE_CIPHER_DATA                "CipherData"
00104 #define OXS_NODE_CIPHER_VALUE               "CipherValue"
00105 #define OXS_NODE_CIPHER_REFERENCE           "CipherReference"
00106 #define OXS_NODE_REFERENCE_LIST             "ReferenceList"
00107 #define OXS_NODE_DATA_REFERENCE             "DataReference"
00108 #define OXS_NODE_KEY_REFERENCE              "KeyReference"
00109 #define OXS_NODE_CARRIED_KEYNAME            "CarriedKeyName"
00110 #define OXS_TYPE_ENC_CONTENT                "http://www.w3.org/2001/04/xmlenc#Content"
00111 #define OXS_TYPE_ENC_ELEMENT                "http://www.w3.org/2001/04/xmlenc#Element"
00112 
00113     /****************************************************************
00114        KeyInfo Nodes
00115     ****************************************************************/
00116 #define OXS_NODE_KEY_INFO               "KeyInfo"
00117 #define OXS_NODE_REFERENCE             "Reference"
00118 #define OXS_NODE_TRANSFORMS            "Transforms"
00119 #define OXS_NODE_TRANSFORM             "Transform"
00120 #define OXS_NODE_TRANSFORMATIONPARAMETERS   "TransformationParameters"
00121     /****************************************************************
00122         KeyInfo Nodes
00123     ****************************************************************/
00124 #define OXS_NODE_BINARY_SECURITY_TOKEN     "BinarySecurityToken"
00125 #define OXS_NODE_KEY_IDENTIFIER     "KeyIdentifier"
00126 #define OXS_NODE_SECURITY_TOKEN_REFRENCE    "SecurityTokenReference"
00127 #define OXS_NODE_EMBEDDED    "Embedded"
00128 
00129     /****************************************************************
00130         Secure Conversation Nodes
00131     ****************************************************************/
00132 #define OXS_NODE_DERIVED_KEY_TOKEN     "DerivedKeyToken"
00133 #define OXS_NODE_PROPERTIES "Properties"
00134 #define OXS_NODE_GENERATION "Generation"
00135 #define OXS_NODE_OFFSET "Offset"
00136 #define OXS_NODE_LENGTH "Length"
00137 #define OXS_NODE_LABEL "Label"
00138 #define OXS_NODE_NONCE "Nonce"
00139 #define OXS_NODE_SECURITY_CONTEXT_TOKEN "SecurityContextToken"
00140 #define OXS_NODE_IDENTIFIER "Identifier"
00141 #define OXS_VALUE_TYPE_SECURITY_CONTEXT_TOKEN_05_02 "http://schemas.xmlsoap.org/ws/2005/02/sc/sct"
00142 #define OXS_VALUE_TYPE_SECURITY_CONTEXT_TOKEN_05_12 "http://docs.oasis-open.org/ws-sx/ws-secureconversation/200512/sct"
00143 
00144 /************************
00145     SAML nodes
00146 *************************/
00147 #define OXS_NODE_SAML_ASSERTION  "Assertion"
00148 #define OXS_NODE_SAML_PREFIX    "saml"
00149 #define OXS_NODE_SAML_SUBJECT_CONFIRMATION_METHOD "ConfirmationMethod"
00150     /****************************************************************
00151         Attributes
00152     ****************************************************************/
00153 #define OXS_ATTR_ID            "Id"
00154 #define OXS_ATTR_URI           "URI"
00155 #define OXS_ATTR_TYPE          "Type"
00156 #define OXS_ATTR_MIMETYPE      "MimeType"
00157 #define OXS_ATTR_ENCODING      "Encoding"
00158 #define OXS_ATTR_ALGORITHM     "Algorithm"
00159 #define OXS_ATTR_FILTER        "Filter"
00160 #define OXS_ATTR_RECIPIENT     "Recipient"
00161 #define OXS_ATTR_TARGET        "Target"
00162 #define OXS_ATTR_ENCODING_TYPE  "EncodingType"
00163 #define OXS_ATTR_VALUE_TYPE     "ValueType"
00164 #define OXS_ATTR_VALUE     "Value"
00165 
00166 
00167     /****************************************************************
00168        AES 
00169     ****************************************************************/
00170 
00171 #define OXS_NAME_AES_128_CBC        "aes128-cbc"
00172 #define OXS_HREF_AES_128_CBC        "http://www.w3.org/2001/04/xmlenc#aes128-cbc"
00173 
00174 #define OXS_NAME_AES_192_CBC        "aes192-cbc"
00175 #define OXS_HREF_AES_192_CBC        "http://www.w3.org/2001/04/xmlenc#aes192-cbc"
00176 
00177 #define OXS_NAME_AES_256_CBC        "aes256-cbc"
00178 #define OXS_HREF_AES_256_CBC        "http://www.w3.org/2001/04/xmlenc#aes256-cbc"
00179 
00180 #define OXS_NAME_KW_AES_128         "kw-aes128"
00181 #define OXS_HREF_KW_AES_128         "http://www.w3.org/2001/04/xmlenc#kw-aes128"
00182 
00183 #define OXS_NAME_KW_AES_192         "kw-aes192"
00184 #define OXS_HREF_KW_AES_192         "http://www.w3.org/2001/04/xmlenc#kw-aes192"
00185 
00186 #define OXS_NAME_KW_AES_256         "kw-aes256"
00187 #define OXS_HREF_KW_AES_256         "http://www.w3.org/2001/04/xmlenc#kw-aes256"
00188 
00189     /****************************************************************
00190       BASE64 
00191     ****************************************************************/
00192 #define OXS_NAME_BASE64           "base64"
00193 #define OXS_HREF_BASE64           "http://www.w3.org/2000/09/xmldsig#base64"
00194 
00195 
00196     /****************************************************************
00197      DES 
00198     ****************************************************************/
00199 #define OXS_NAME_DES_KEY_VALUE       "des"
00200 
00201 #define OXS_NAME_DES3_CBC           "tripledes-cbc"
00202 #define OXS_HREF_DES3_CBC           "http://www.w3.org/2001/04/xmlenc#tripledes-cbc"
00203 
00204 #define OXS_NAME_KW_DES3            "kw-tripledes"
00205 #define OXS_HREF_KW_DES3            "http://www.w3.org/2001/04/xmlenc#kw-tripledes"
00206 
00207 
00208 
00209     /****************************************************************
00210         DSA 
00211     ****************************************************************/
00212 #define OXS_NAME_DSA_KEY_VALUE          "dsa"
00213 #define OXS_NODE_DSA_KEY_VALUE          "DSAKeyValue"
00214 #define OXS_HREF_DSA_KEY_VALUE          "http://www.w3.org/2000/09/xmldsig#DSAKeyValue"
00215 
00216 #define OXS_NAME_DSA_SHA1          "dsa-sha1"
00217 #define OXS_HREF_DSA_SHA1          "http://www.w3.org/2000/09/xmldsig#dsa-sha1"
00218 
00219     /****************************************************************
00220        HMAC
00221      ****************************************************************/
00222 #define OXS_NAME_HMAC_SHA1      "HmacSha1"
00223 #define OXS_HREF_HMAC_SHA1    "http://www.w3.org/2000/09/xmldsig#hmac-sha1"
00224 
00225     /****************************************************************
00226        EncryptedKey
00227     ****************************************************************/
00228 #define OXS_NAME_ENCRYPTED_KEY         "enc-key"
00229 #define OXS_NODE_ENCRYPTED_KEY         "EncryptedKey"
00230 #define OXS_HREF_ENCRYPTED_KEY         "http://www.w3.org/2001/04/xmlenc#EncryptedKey"
00231 
00232     /****************************************************************
00233        C14N
00234     ****************************************************************/
00235 
00236 #define OXS_HREF_XML_C14N                   "http://www.w3.org/TR/2001/REC-xml-c14n-20010315"
00237 #define OXS_HREF_XML_EXC_C14N     "http://www.w3.org/2001/10/xml-exc-c14n#"
00238 
00239 #define OXS_HREF_XML_C14N_WITH_COMMENTS         "http://www.w3.org/TR/2001/REC-xml-c14n-20010315#WithComments"
00240 #define OXS_HREF_XML_EXC_C14N_WITH_COMMENTS "http://www.w3.org/2001/10/xml-exc-c14n#WithComments"
00241     /****************************************************************
00242        Transforms
00243     ****************************************************************/
00244 #define OXS_HREF_TRANSFORM_XML_EXC_C14N     OXS_HREF_XML_EXC_C14N
00245 #define OXS_HREF_TRANSFORM_STR_TRANSFORM     "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#STR-Transform"
00246 #define OXS_HREF_TRANSFORM_ENVELOPED_SIGNATURE "http://www.w3.org/2000/09/xmldsig#enveloped-signature"
00247 
00248     /****************************************************************
00249         KeyNAME
00250     ****************************************************************/
00251 #define OXS_NAME_KEY_NAME          "key-name"
00252 #define OXS_NODE_KEY_NAME          "KeyName"
00253 
00254 
00255     /****************************************************************
00256         KeyValue 
00257     ****************************************************************/
00258 #define OXS_NAME_KEY_VALUE         "key-value"
00259 #define OXS_NODE_KEY_VALUE         "KeyValue"
00260 
00261 
00262     /****************************************************************
00263         MD5 
00264     ****************************************************************/
00265 #define OXS_NAME_MD5              "md5"
00266 #define OXS_HREF_MD5              "http://www.w3.org/2001/04/xmldsig-more#md5"
00267 
00268     /****************************************************************
00269         RetrievalMethod
00270     ****************************************************************/
00271 #define OXS_NAME_RETRIEVAL_METHOD      "retrieval-method"
00272 #define OXS_NODE_RETRIEVAL_METHOD      "RetrievalMethod"
00273 
00274     /****************************************************************
00275         RSA 
00276     ****************************************************************/
00277 #define OXS_NAME_RSAKEY_VALUE          "rsa"
00278 #define OXS_NODE_RSAKEY_VALUE          "RSAKeyValue"
00279 #define OXS_HREF_RSAKEY_VALUE          "http://www.w3.org/2000/09/xmldsig#RSAKeyValue"
00280 
00281 #define OXS_NAME_RSA_MD5           "rsa-md5"
00282 #define OXS_HREF_RSA_MD5           "http://www.w3.org/2001/04/xmldsig-more#rsa-md5"
00283 
00284 #define OXS_NAME_RSA_RIPEMD160         "rsa-ripemd160"
00285 #define OXS_HREF_RSA_RIPEMD160         "http://www.w3.org/2001/04/xmldsig-more#rsa-ripemd160"
00286 
00287 #define OXS_NAME_RSA_SHA1          "rsa-sha1"
00288 #define OXS_HREF_RSA_SHA1          "http://www.w3.org/2000/09/xmldsig#rsa-sha1"
00289 
00290 #define OXS_NAME_RSA_SHA224        "rsa-sha224"
00291 #define OXS_HREF_RSA_SHA224        "http://www.w3.org/2001/04/xmldsig-more#rsa-sha224"
00292 
00293 #define OXS_NAME_RSA_SHA256        "rsa-sha256"
00294 #define OXS_HREF_RSA_SHA256        "http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"
00295 
00296 #define OXS_NAME_RSA_SHA384        "rsa-sha384"
00297 #define OXS_HREF_RSA_SHA384        "http://www.w3.org/2001/04/xmldsig-more#rsa-sha384"
00298 
00299 #define OXS_NAME_RSA_SHA512        "rsa-sha512"
00300 #define OXS_HREF_RSA_SHA512        "http://www.w3.org/2001/04/xmldsig-more#rsa-sha512"
00301 
00302 #define OXS_NAME_RSA_PKCS1         "rsa-1_5"
00303 #define OXS_HREF_RSA_PKCS1         "http://www.w3.org/2001/04/xmlenc#rsa-1_5"
00304 
00305 #define OXS_NAME_RSA_OAEP          "rsa-oaep-mgf1p"
00306 #define OXS_HREF_RSA_OAEP          "http://www.w3.org/2001/04/xmlenc#rsa-oaep-mgf1p"
00307 #define OXS_NODE_RSA_OAEP_PARAMS        "OAEPparams"
00308 
00309 
00310     /****************************************************************
00311         SHA1 
00312     ****************************************************************/
00313 #define OXS_NAME_SHA1             "sha1"
00314 #define OXS_HREF_SHA1             "http://www.w3.org/2000/09/xmldsig#sha1"
00315 
00316 #define OXS_NAME_SHA224           "sha224"
00317 #define OXS_HREF_SHA224           "http://www.w3.org/2001/04/xmldsig-more#sha224"
00318 
00319 #define OXS_NAME_SHA256           "sha256"
00320 #define OXS_HREF_SHA256           "http://www.w3.org/2001/04/xmlenc#sha256"
00321 
00322 #define OXS_NAME_SHA384           "sha384"
00323 #define OXS_HREF_SHA384           "http://www.w3.org/2001/04/xmldsig-more#sha384"
00324 
00325 #define OXS_NAME_SHA512           "sha512"
00326 #define OXS_HREF_SHA512           "http://www.w3.org/2001/04/xmlenc#sha512"
00327 
00328 #define OXS_SC_DK_NAME_P_SHA1     "P_SHA-1"
00329 #define OXS_SC_DK_HREF_P_SHA1     "http://schemas.xmlsoap.org/ws/2005/02/sc/dk/p_sha1"
00330     /****************************************************************
00331         X509 
00332     ****************************************************************/
00333 #define OXS_NAME_X509_DATA         "x509"
00334 #define OXS_NODE_X509_DATA         "X509Data"
00335 #define OXS_HREF_X509_DATA         "http://www.w3.org/2000/09/xmldsig#X509Data"
00336 
00337 #define OXS_NODE_X509_CERTIFICATE      "X509Certificate"
00338 #define OXS_NODE_X509_CRL          "X509CRL"
00339 #define OXS_NODE_X509_SUBJECT_NAME      "X509SubjectName"
00340 #define OXS_NODE_X509_ISSUER_SERIAL     "X509IssuerSerial"
00341 #define OXS_NODE_X509_ISSUER_NAME       "X509IssuerName"
00342 #define OXS_NODE_X509_SERIAL_NUMBER     "X509SerialNumber"
00343 #define OXS_NODE_X509_SKI          "X509SKI"
00344 
00345 #define OXS_NAME_RAW_X509_CERT          "raw-x509-cert"
00346 #define OXS_HREF_RAW_X509_CERT          "http://www.w3.org/2000/09/xmldsig#rawX509Certificate"
00347 
00348 #define OXS_NAME_X509_STORE        "x509-store"
00349 
00350     /****************************************************************
00351         SOAP 1.1/1.2
00352     ****************************************************************/
00353 #define OXS_NODE_ENVELOPE         "Envelope"
00354 #define OXS_NODE_HEADER           "Header"
00355 #define OXS_NODE_BODY                 "Body"
00356 #define OXS_NODE_FAULT                "Fault"
00357 #define OXS_NODE_FAULT_CODE        "faultcode"
00358 #define OXS_NODE_FAULT_STRING              "faultstring"
00359 #define OXS_NODE_FAULT_ACTOR               "faultactor"
00360 #define OXS_NODE_FAULT_DETAIL              "detail"
00361 #define OXS_NODE_CODE             "Code"
00362 #define OXS_NODE_REASON           "Reason"
00363 #define OXS_NODE_NODE             "Node"
00364 #define OXS_NODE_ROLE             "Role"
00365 #define OXS_NODE_DETAIL           "Detail"
00366 #define OXS_NODE_VALUE            "Value"
00367 #define OXS_NODE_SUBCODE          "Subcode"
00368 #define OXS_NODE_TEXT             "Text"
00369 
00370 
00371 #define OXS_SOAP_FAULT_CODE_VERSION_MISMATCH     "VersionMismatch"
00372 #define OXS_SOAP_FAULT_CODE_MUST_UNDERSTAND      "MustUnderstand"
00373 #define OXS_SOAP_FAULT_CODE_CLIENT          "Client"
00374 #define OXS_SOAP_FAULT_CODE_SERVER          "Server"
00375 #define OXS_SOAP_FAULT_CODE_RECEIVER        "Receiver"
00376 #define OXS_SOAP_FAULT_CODE_SENDER          "Sender"
00377 #define OXS_SOAP_FAULT_DATA_ENCODNING_UNKNOWN    "DataEncodingUnknown"
00378 
00379     /****************************************************************
00380         Ext
00381     ****************************************************************/
00382 #define OXS_ENCODING_BASE64BINARY "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary"
00383 #define OXS_VALUE_X509V3 "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509v3"
00384 #define OXS_X509_SUBJ_KI "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509SubjectKeyIdentifier"
00385 #define OXS_X509_TUMBP_PRINT_SHA1 "http://docs.oasis-open.org/wss/oasis-wss-soap-message-security-1.1#ThumbprintSHA1"
00386 #define OXS_X509_ENCRYPTED_KEY_SHA1 "http://docs.oasis-open.org/wss/oasis-wss-soap-message-security-1.1#EncryptedKeySHA1"
00387     /****************************************************************
00388         ST References
00389     ****************************************************************/
00390 #define OXS_STR_DIRECT_REFERENCE "DirectReference"
00391 #define OXS_STR_KEY_IDENTIFIER  OXS_NODE_KEY_IDENTIFIER
00392 #define OXS_STR_EMBEDDED        OXS_NODE_EMBEDDED
00393 #define OXS_STR_ISSUER_SERIAL "IssuerSerial"
00394 #define OXS_STR_THUMB_PRINT "ThumbPrint"
00395 #define OXS_STR_EXTERNAL_URI "ExternalUri"
00396 #define OXS_STR_ENCRYPTED_KEY "Encryptedkey"
00397 
00398     
00399     /****************************************************************
00400         WS Security 1.1
00401     ****************************************************************/
00402 #define OXS_WSS_11_VALUE_TYPE_ENCRYPTED_KEY "http://docs.oasis-open.org/wss/oasis-wss-soap-message-security-1.1#EncryptedKey"
00403 #define OXS_NODE_ENCRYPTED_HEADER "EncryptedHeader"
00404     /*************************************************************************/
00405 
00406 
00408 #ifdef __cplusplus
00409 }
00410 #endif
00411 
00412 #endif /* OXS_CONSTANTS_H*/

Generated on Wed Oct 14 01:02:15 2009 for Rampart/C by  doxygen 1.5.7.1