1378de8f6a485efdf4a6ad24688ea96fb5fca56a
[shibboleth/cpp-opensaml.git] / saml / saml1 / core / impl / AssertionsImpl.cpp
1 /*
2  *  Copyright 2001-2006 Internet2
3  * 
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *     http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 /**
18  * AssertionsImpl.cpp
19  * 
20  * Implementation classes for SAML 1.x Assertions schema
21  */
22
23 #include "internal.h"
24 #include "exceptions.h"
25 #include "saml1/core/Assertions.h"
26
27 #include <xmltooling/AbstractComplexElement.h>
28 #include <xmltooling/AbstractElementProxy.h>
29 #include <xmltooling/AbstractSimpleElement.h>
30 #include <xmltooling/impl/AnyElement.h>
31 #include <xmltooling/io/AbstractXMLObjectMarshaller.h>
32 #include <xmltooling/io/AbstractXMLObjectUnmarshaller.h>
33 #include <xmltooling/util/XMLHelper.h>
34
35 #include <ctime>
36 #include <limits.h>
37 #include <xercesc/util/XMLUniDefs.hpp>
38
39 using namespace opensaml::saml1;
40 using namespace opensaml;
41 using namespace xmlsignature;
42 using namespace xmltooling;
43 using namespace std;
44
45 #if defined (_MSC_VER)
46     #pragma warning( push )
47     #pragma warning( disable : 4250 4251 )
48 #endif
49
50 namespace opensaml {
51     namespace saml1 {
52     
53         DECL_XMLOBJECTIMPL_SIMPLE(SAML_DLLLOCAL,AssertionIDReference);
54         DECL_XMLOBJECTIMPL_SIMPLE(SAML_DLLLOCAL,Audience);
55         DECL_XMLOBJECTIMPL_SIMPLE(SAML_DLLLOCAL,ConfirmationMethod);
56         
57         class SAML_DLLLOCAL AudienceRestrictionConditionImpl : public virtual AudienceRestrictionCondition,
58             public AbstractComplexElement,
59             public AbstractDOMCachingXMLObject,
60             public AbstractXMLObjectMarshaller,
61             public AbstractXMLObjectUnmarshaller
62         {
63         public:
64             virtual ~AudienceRestrictionConditionImpl() {}
65     
66             AudienceRestrictionConditionImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
67                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
68             }
69                 
70             AudienceRestrictionConditionImpl(const AudienceRestrictionConditionImpl& src)
71                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
72                 VectorOf(Audience) v=getAudiences();
73                 for (vector<Audience*>::const_iterator i=src.m_Audiences.begin(); i!=src.m_Audiences.end(); i++) {
74                     if (*i) {
75                         v.push_back((*i)->cloneAudience());
76                     }
77                 }
78             }
79             
80             IMPL_XMLOBJECT_CLONE(AudienceRestrictionCondition);
81             Condition* cloneCondition() const {
82                 return cloneAudienceRestrictionCondition();
83             }
84             IMPL_TYPED_CHILDREN(Audience,m_children.end());
85     
86         protected:
87             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
88                 PROC_TYPED_CHILDREN(Audience,SAMLConstants::SAML1_NS,false);
89                 AbstractXMLObjectUnmarshaller::processChildElement(childXMLObject,root);
90             }
91         };
92
93         class SAML_DLLLOCAL DoNotCacheConditionImpl : public virtual DoNotCacheCondition,
94             public AbstractSimpleElement,
95             public AbstractDOMCachingXMLObject,
96             public AbstractXMLObjectMarshaller,
97             public AbstractXMLObjectUnmarshaller
98         {
99         public:
100             virtual ~DoNotCacheConditionImpl() {}
101     
102             DoNotCacheConditionImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
103                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
104             }
105                 
106             DoNotCacheConditionImpl(const DoNotCacheConditionImpl& src)
107                 : AbstractXMLObject(src), AbstractSimpleElement(src), AbstractDOMCachingXMLObject(src) {
108             }
109             
110             IMPL_XMLOBJECT_CLONE(DoNotCacheCondition);
111             Condition* cloneCondition() const {
112                 return cloneDoNotCacheCondition();
113             }
114         };
115
116         class SAML_DLLLOCAL ConditionsImpl : public virtual Conditions,
117             public AbstractComplexElement,
118             public AbstractDOMCachingXMLObject,
119             public AbstractXMLObjectMarshaller,
120             public AbstractXMLObjectUnmarshaller
121         {
122         public:
123             virtual ~ConditionsImpl() {
124                 delete m_NotBefore;
125                 delete m_NotOnOrAfter;
126             }
127     
128             ConditionsImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
129                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
130                 init();
131             }
132                 
133             ConditionsImpl(const ConditionsImpl& src)
134                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
135                 init();
136                 setNotBefore(src.getNotBefore());
137                 setNotOnOrAfter(src.getNotOnOrAfter());
138
139                 for (list<XMLObject*>::const_iterator i=src.m_children.begin(); i!=src.m_children.end(); i++) {
140                     if (*i) {
141                         AudienceRestrictionCondition* arc=dynamic_cast<AudienceRestrictionCondition*>(*i);
142                         if (arc) {
143                             getAudienceRestrictionConditions().push_back(arc->cloneAudienceRestrictionCondition());
144                             continue;
145                         }
146     
147                         DoNotCacheCondition* dncc=dynamic_cast<DoNotCacheCondition*>(*i);
148                         if (dncc) {
149                             getDoNotCacheConditions().push_back(dncc->cloneDoNotCacheCondition());
150                             continue;
151                         }
152     
153                         Condition* c=dynamic_cast<Condition*>(*i);
154                         if (c) {
155                             getConditions().push_back(c->cloneCondition());
156                             continue;
157                         }
158                     }
159                 }
160             }
161             
162             void init() {
163                 m_NotBefore=m_NotOnOrAfter=NULL;
164             }
165             
166             IMPL_XMLOBJECT_CLONE(Conditions);
167             IMPL_DATETIME_ATTRIB(NotBefore,0);
168             IMPL_DATETIME_ATTRIB(NotOnOrAfter,SAMLTIME_MAX);
169             IMPL_TYPED_CHILDREN(AudienceRestrictionCondition, m_children.end());
170             IMPL_TYPED_CHILDREN(DoNotCacheCondition,m_children.end());
171             IMPL_TYPED_CHILDREN(Condition,m_children.end());
172     
173         protected:
174             void marshallAttributes(DOMElement* domElement) const {
175                 MARSHALL_DATETIME_ATTRIB(NotBefore,NOTBEFORE,NULL);
176                 MARSHALL_DATETIME_ATTRIB(NotOnOrAfter,NOTONORAFTER,NULL);
177             }
178     
179             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
180                 PROC_TYPED_CHILDREN(AudienceRestrictionCondition,SAMLConstants::SAML1_NS,true);
181                 PROC_TYPED_CHILDREN(DoNotCacheCondition,SAMLConstants::SAML1_NS,true);
182                 PROC_TYPED_CHILDREN(Condition,SAMLConstants::SAML1_NS,true);
183                 AbstractXMLObjectUnmarshaller::processChildElement(childXMLObject,root);
184             }
185     
186             void processAttribute(const DOMAttr* attribute) {
187                 PROC_DATETIME_ATTRIB(NotBefore,NOTBEFORE,NULL);
188                 PROC_DATETIME_ATTRIB(NotOnOrAfter,NOTONORAFTER,NULL);
189             }
190         };
191
192         class SAML_DLLLOCAL NameIdentifierImpl : public virtual NameIdentifier,
193             public AbstractSimpleElement,
194             public AbstractDOMCachingXMLObject,
195             public AbstractXMLObjectMarshaller,
196             public AbstractXMLObjectUnmarshaller
197         {
198         public:
199             virtual ~NameIdentifierImpl() {
200                 XMLString::release(&m_Format);
201                 XMLString::release(&m_NameQualifier);
202             }
203     
204             NameIdentifierImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
205                     : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
206                 init();
207             }
208                 
209             NameIdentifierImpl(const NameIdentifierImpl& src)
210                     : AbstractXMLObject(src), AbstractSimpleElement(src), AbstractDOMCachingXMLObject(src) {
211                 init();
212                 setFormat(src.getFormat());
213                 setNameQualifier(src.getNameQualifier());
214             }
215             
216             void init() {
217                 m_Format=m_NameQualifier=NULL;
218             }
219             
220             IMPL_XMLOBJECT_CLONE(NameIdentifier);
221             IMPL_STRING_ATTRIB(Format);
222             IMPL_STRING_ATTRIB(NameQualifier);
223     
224         protected:
225             void marshallAttributes(DOMElement* domElement) const {
226                 MARSHALL_STRING_ATTRIB(Format,FORMAT,NULL);
227                 MARSHALL_STRING_ATTRIB(NameQualifier,NAMEQUALIFIER,NULL);
228             }
229
230             void processAttribute(const DOMAttr* attribute) {
231                 PROC_STRING_ATTRIB(Format,FORMAT,NULL);
232                 PROC_STRING_ATTRIB(NameQualifier,NAMEQUALIFIER,NULL);
233             }
234         };
235
236         class SAML_DLLLOCAL SubjectConfirmationDataImpl : public virtual SubjectConfirmationData, public AnyElementImpl
237         {
238         public:
239             virtual ~SubjectConfirmationDataImpl() {}
240     
241             SubjectConfirmationDataImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
242                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
243             }
244                 
245             SubjectConfirmationDataImpl(const SubjectConfirmationDataImpl& src) : AnyElementImpl(src) {
246             }
247             
248             IMPL_XMLOBJECT_CLONE(SubjectConfirmationData);
249         };
250
251         class SAML_DLLLOCAL SubjectConfirmationImpl : public virtual SubjectConfirmation,
252             public AbstractComplexElement,
253             public AbstractDOMCachingXMLObject,
254             public AbstractXMLObjectMarshaller,
255             public AbstractXMLObjectUnmarshaller
256         {
257         public:
258             virtual ~SubjectConfirmationImpl() {}
259     
260             SubjectConfirmationImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
261                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
262                 init();
263             }
264                 
265             SubjectConfirmationImpl(const SubjectConfirmationImpl& src)
266                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
267                 init();
268                 if (src.getSubjectConfirmationData())
269                     setSubjectConfirmationData(src.getSubjectConfirmationData()->clone());
270                 if (src.getKeyInfo())
271                     setKeyInfo(src.getKeyInfo()->cloneKeyInfo());
272                 VectorOf(ConfirmationMethod) v=getConfirmationMethods();
273                 for (vector<ConfirmationMethod*>::const_iterator i=src.m_ConfirmationMethods.begin(); i!=src.m_ConfirmationMethods.end(); i++) {
274                     if (*i) {
275                         v.push_back((*i)->cloneConfirmationMethod());
276                     }
277                 }
278             }
279             
280             void init() {
281                 m_SubjectConfirmationData=NULL;
282                 m_KeyInfo=NULL;
283                 m_children.push_back(NULL);
284                 m_children.push_back(NULL);
285                 m_pos_SubjectConfirmationData=m_children.begin();
286                 m_pos_KeyInfo=m_pos_SubjectConfirmationData;
287                 ++m_pos_KeyInfo;
288             }
289
290             IMPL_XMLOBJECT_CLONE(SubjectConfirmation);
291             IMPL_TYPED_CHILDREN(ConfirmationMethod,m_pos_SubjectConfirmationData);
292             IMPL_XMLOBJECT_CHILD(SubjectConfirmationData);
293             IMPL_TYPED_CHILD(KeyInfo);
294     
295         protected:
296             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
297                 PROC_TYPED_CHILDREN(ConfirmationMethod,SAMLConstants::SAML1_NS,false);
298                 PROC_TYPED_CHILD(KeyInfo,XMLConstants::XMLSIG_NS,false);
299                 
300                 // Anything else we'll assume is the data.
301                 if (getSubjectConfirmationData())
302                     throw UnmarshallingException("Invalid child element: $1",params(1,childXMLObject->getElementQName().toString().c_str()));
303                 setSubjectConfirmationData(childXMLObject);
304             }
305         };
306
307         class SAML_DLLLOCAL SubjectImpl : public virtual Subject,
308             public AbstractComplexElement,
309             public AbstractDOMCachingXMLObject,
310             public AbstractXMLObjectMarshaller,
311             public AbstractXMLObjectUnmarshaller
312         {
313         public:
314             virtual ~SubjectImpl() {}
315     
316             SubjectImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
317                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
318                 init();
319             }
320                 
321             SubjectImpl(const SubjectImpl& src)
322                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
323                 init();
324                 if (src.getNameIdentifier())
325                     setNameIdentifier(src.getNameIdentifier()->cloneNameIdentifier());
326                 if (src.getSubjectConfirmation())
327                     setSubjectConfirmation(src.getSubjectConfirmation()->cloneSubjectConfirmation());
328             }
329             
330             void init() {
331                 m_NameIdentifier=NULL;
332                 m_SubjectConfirmation=NULL;
333                 m_children.push_back(NULL);
334                 m_children.push_back(NULL);
335                 m_pos_NameIdentifier=m_children.begin();
336                 m_pos_SubjectConfirmation=m_pos_NameIdentifier;
337                 ++m_pos_SubjectConfirmation;
338             }
339
340             IMPL_XMLOBJECT_CLONE(Subject);
341             IMPL_TYPED_CHILD(NameIdentifier);
342             IMPL_TYPED_CHILD(SubjectConfirmation);
343     
344         protected:
345             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
346                 PROC_TYPED_CHILD(NameIdentifier,SAMLConstants::SAML1_NS,true);
347                 PROC_TYPED_CHILD(SubjectConfirmation,SAMLConstants::SAML1_NS,true);
348                 AbstractXMLObjectUnmarshaller::processChildElement(childXMLObject,root);
349             }
350         };
351
352         class SAML_DLLLOCAL SubjectStatementImpl : public virtual SubjectStatement,
353             public AbstractComplexElement,
354             public AbstractDOMCachingXMLObject,
355             public AbstractXMLObjectMarshaller,
356             public AbstractXMLObjectUnmarshaller
357         {
358             void init() {
359                 m_Subject=NULL;
360                 m_children.push_back(NULL);
361                 m_pos_Subject=m_children.begin();
362             }
363         protected:
364             SubjectStatementImpl() {
365                 init();
366             }
367         public:
368             virtual ~SubjectStatementImpl() {}
369     
370             SubjectStatementImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
371                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
372                 init();
373             }
374                 
375             SubjectStatementImpl(const SubjectStatementImpl& src)
376                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
377                 init();
378                 if (src.getSubject())
379                     setSubject(src.getSubject()->cloneSubject());
380             }
381             
382             IMPL_TYPED_CHILD(Subject);
383     
384         protected:
385             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
386                 PROC_TYPED_CHILD(Subject,SAMLConstants::SAML1_NS,true);
387                 AbstractXMLObjectUnmarshaller::processChildElement(childXMLObject,root);
388             }
389         };
390
391         class SAML_DLLLOCAL SubjectLocalityImpl : public virtual SubjectLocality,
392             public AbstractSimpleElement,
393             public AbstractDOMCachingXMLObject,
394             public AbstractXMLObjectMarshaller,
395             public AbstractXMLObjectUnmarshaller
396         {
397         public:
398             virtual ~SubjectLocalityImpl() {
399                 XMLString::release(&m_IPAddress);
400                 XMLString::release(&m_DNSAddress);
401             }
402     
403             SubjectLocalityImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
404                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
405                 init();
406             }
407                 
408             SubjectLocalityImpl(const SubjectLocalityImpl& src)
409                     : AbstractXMLObject(src), AbstractSimpleElement(src), AbstractDOMCachingXMLObject(src) {
410                 init();
411                 setIPAddress(src.getIPAddress());
412                 setDNSAddress(src.getDNSAddress());
413             }
414             
415             void init() {
416                 m_IPAddress=m_DNSAddress=NULL;
417             }
418             
419             IMPL_XMLOBJECT_CLONE(SubjectLocality);
420             IMPL_STRING_ATTRIB(IPAddress);
421             IMPL_STRING_ATTRIB(DNSAddress);
422     
423         protected:
424             void marshallAttributes(DOMElement* domElement) const {
425                 MARSHALL_STRING_ATTRIB(IPAddress,IPADDRESS,NULL);
426                 MARSHALL_STRING_ATTRIB(DNSAddress,DNSADDRESS,NULL);
427             }
428     
429             void processAttribute(const DOMAttr* attribute) {
430                 PROC_STRING_ATTRIB(IPAddress,IPADDRESS,NULL);
431                 PROC_STRING_ATTRIB(DNSAddress,DNSADDRESS,NULL);
432             }
433         };
434
435         class SAML_DLLLOCAL AuthorityBindingImpl : public virtual AuthorityBinding,
436             public AbstractSimpleElement,
437             public AbstractDOMCachingXMLObject,
438             public AbstractXMLObjectMarshaller,
439             public AbstractXMLObjectUnmarshaller
440         {
441         public:
442             virtual ~AuthorityBindingImpl() {
443                 delete m_AuthorityKind;
444                 XMLString::release(&m_Location);
445                 XMLString::release(&m_Binding);
446             }
447     
448             AuthorityBindingImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
449                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
450                 init();
451             }
452                 
453             AuthorityBindingImpl(const AuthorityBindingImpl& src)
454                     : AbstractXMLObject(src), AbstractSimpleElement(src), AbstractDOMCachingXMLObject(src) {
455                 init();
456                 setAuthorityKind(src.getAuthorityKind());
457                 setLocation(src.getLocation());
458                 setBinding(src.getBinding());
459             }
460             
461             void init() {
462                 m_AuthorityKind=NULL;
463                 m_Location=m_Binding=NULL;
464             }
465             
466             IMPL_XMLOBJECT_CLONE(AuthorityBinding);
467             IMPL_XMLOBJECT_ATTRIB(AuthorityKind,QName);
468             IMPL_STRING_ATTRIB(Location);
469             IMPL_STRING_ATTRIB(Binding);
470     
471         protected:
472             void marshallAttributes(DOMElement* domElement) const {
473                 MARSHALL_QNAME_ATTRIB(AuthorityKind,AUTHORITYKIND,NULL);
474                 MARSHALL_STRING_ATTRIB(Location,LOCATION,NULL);
475                 MARSHALL_STRING_ATTRIB(Binding,BINDING,NULL);
476             }
477     
478             void processAttribute(const DOMAttr* attribute) {
479                 PROC_QNAME_ATTRIB(AuthorityKind,AUTHORITYKIND,NULL);
480                 PROC_STRING_ATTRIB(Location,LOCATION,NULL);
481                 PROC_STRING_ATTRIB(Binding,BINDING,NULL);
482             }
483         };
484
485         class SAML_DLLLOCAL AuthenticationStatementImpl : public virtual AuthenticationStatement, public SubjectStatementImpl
486         {
487         public:
488             virtual ~AuthenticationStatementImpl() {
489                 XMLString::release(&m_AuthenticationMethod);
490                 delete m_AuthenticationInstant;
491             }
492     
493             AuthenticationStatementImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
494                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
495                 init();
496             }
497                 
498             AuthenticationStatementImpl(const AuthenticationStatementImpl& src) : AbstractXMLObject(src), SubjectStatementImpl(src) {
499                 init();
500                 setAuthenticationMethod(src.getAuthenticationMethod());
501                 setAuthenticationInstant(src.getAuthenticationInstant());
502                 if (src.getSubjectLocality())
503                     setSubjectLocality(src.getSubjectLocality()->cloneSubjectLocality());
504                 VectorOf(AuthorityBinding) v=getAuthorityBindings();
505                 for (vector<AuthorityBinding*>::const_iterator i=src.m_AuthorityBindings.begin(); i!=src.m_AuthorityBindings.end(); i++) {
506                     if (*i) {
507                         v.push_back((*i)->cloneAuthorityBinding());
508                     }
509                 }
510             }
511             
512             void init() {
513                 m_AuthenticationMethod=NULL;
514                 m_AuthenticationInstant=NULL;
515                 m_SubjectLocality=NULL;
516                 m_children.push_back(NULL);
517                 m_pos_SubjectLocality=m_pos_Subject;
518                 ++m_pos_SubjectLocality;
519             }
520             
521             IMPL_XMLOBJECT_CLONE(AuthenticationStatement);
522             SubjectStatement* cloneSubjectStatement() const {
523                 return cloneAuthenticationStatement();
524             }
525             Statement* cloneStatement() const {
526                 return cloneAuthenticationStatement();
527             }
528             IMPL_STRING_ATTRIB(AuthenticationMethod);
529             IMPL_DATETIME_ATTRIB(AuthenticationInstant,0);
530             IMPL_TYPED_CHILD(SubjectLocality);
531             IMPL_TYPED_CHILDREN(AuthorityBinding, m_children.end());
532     
533         protected:
534             void marshallAttributes(DOMElement* domElement) const {
535                 MARSHALL_STRING_ATTRIB(AuthenticationMethod,AUTHENTICATIONMETHOD,NULL);
536                 MARSHALL_DATETIME_ATTRIB(AuthenticationInstant,AUTHENTICATIONINSTANT,NULL);
537                 SubjectStatementImpl::marshallAttributes(domElement);
538             }
539     
540             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
541                 PROC_TYPED_CHILD(SubjectLocality,SAMLConstants::SAML1_NS,false);
542                 PROC_TYPED_CHILDREN(AuthorityBinding,SAMLConstants::SAML1_NS,false);
543                 SubjectStatementImpl::processChildElement(childXMLObject,root);
544             }
545     
546             void processAttribute(const DOMAttr* attribute) {
547                 PROC_STRING_ATTRIB(AuthenticationMethod,AUTHENTICATIONMETHOD,NULL);
548                 PROC_DATETIME_ATTRIB(AuthenticationInstant,AUTHENTICATIONINSTANT,NULL);
549                 SubjectStatementImpl::processAttribute(attribute);
550             }
551         };
552
553         class SAML_DLLLOCAL ActionImpl : public virtual Action,
554             public AbstractSimpleElement,
555             public AbstractDOMCachingXMLObject,
556             public AbstractXMLObjectMarshaller,
557             public AbstractXMLObjectUnmarshaller
558         {
559         public:
560             virtual ~ActionImpl() {
561                 XMLString::release(&m_Namespace);
562             }
563     
564             ActionImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
565                     : AbstractXMLObject(nsURI, localName, prefix, schemaType), m_Namespace(NULL) {
566             }
567                 
568             ActionImpl(const ActionImpl& src) : AbstractXMLObject(src), AbstractSimpleElement(src), AbstractDOMCachingXMLObject(src) {
569                 setNamespace(src.getNamespace());
570             }
571             
572             IMPL_XMLOBJECT_CLONE(Action);
573             IMPL_STRING_ATTRIB(Namespace);
574     
575         protected:
576             void marshallAttributes(DOMElement* domElement) const {
577                 MARSHALL_STRING_ATTRIB(Namespace,NAMESPACE,NULL);
578             }
579
580             void processAttribute(const DOMAttr* attribute) {
581                 PROC_STRING_ATTRIB(Namespace,NAMESPACE,NULL);
582             }
583         };
584
585         class SAML_DLLLOCAL EvidenceImpl : public virtual Evidence,
586             public AbstractComplexElement,
587             public AbstractDOMCachingXMLObject,
588             public AbstractXMLObjectMarshaller,
589             public AbstractXMLObjectUnmarshaller
590         {
591         public:
592             virtual ~EvidenceImpl() {}
593     
594             EvidenceImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
595                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
596             }
597                 
598             EvidenceImpl(const EvidenceImpl& src)
599                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
600                 for (list<XMLObject*>::const_iterator i=src.m_children.begin(); i!=src.m_children.end(); i++) {
601                     if (*i) {
602                         AssertionIDReference* ref=dynamic_cast<AssertionIDReference*>(*i);
603                         if (ref) {
604                             getAssertionIDReferences().push_back(ref->cloneAssertionIDReference());
605                             continue;
606                         }
607     
608                         Assertion* assertion=dynamic_cast<Assertion*>(*i);
609                         if (assertion) {
610                             getAssertions().push_back(assertion->cloneAssertion());
611                             continue;
612                         }
613                     }
614                 }
615             }
616             
617             IMPL_XMLOBJECT_CLONE(Evidence);
618             IMPL_TYPED_CHILDREN(AssertionIDReference,m_children.end());
619             IMPL_TYPED_CHILDREN(Assertion,m_children.end());
620     
621         protected:
622             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
623                 PROC_TYPED_CHILDREN(AssertionIDReference,SAMLConstants::SAML1_NS,false);
624                 PROC_TYPED_CHILDREN(Assertion,SAMLConstants::SAML1_NS,true);
625                 AbstractXMLObjectUnmarshaller::processChildElement(childXMLObject,root);
626             }
627         };
628
629         class SAML_DLLLOCAL AuthorizationDecisionStatementImpl
630             : public virtual AuthorizationDecisionStatement, public SubjectStatementImpl
631         {
632         public:
633             virtual ~AuthorizationDecisionStatementImpl() {
634                 XMLString::release(&m_Resource);
635                 XMLString::release(&m_Decision);
636             }
637     
638             AuthorizationDecisionStatementImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
639                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
640                 init();
641             }
642                 
643             AuthorizationDecisionStatementImpl(const AuthorizationDecisionStatementImpl& src)
644                     : AbstractXMLObject(src), SubjectStatementImpl(src) {
645                 init();
646                 setResource(src.getResource());
647                 setDecision(src.getDecision());
648                 if (src.getEvidence())
649                     setEvidence(src.getEvidence()->cloneEvidence());
650                 VectorOf(Action) v=getActions();
651                 for (vector<Action*>::const_iterator i=src.m_Actions.begin(); i!=src.m_Actions.end(); i++) {
652                     if (*i) {
653                         v.push_back((*i)->cloneAction());
654                     }
655                 }
656             }
657             
658             void init() {
659                 m_Resource=NULL;
660                 m_Decision=NULL;
661                 m_Evidence=NULL;
662                 m_children.push_back(NULL);
663                 m_pos_Evidence=m_pos_Subject;
664                 ++m_pos_Evidence;
665             }
666             
667             IMPL_XMLOBJECT_CLONE(AuthorizationDecisionStatement);
668             SubjectStatement* cloneSubjectStatement() const {
669                 return cloneAuthorizationDecisionStatement();
670             }
671             Statement* cloneStatement() const {
672                 return cloneAuthorizationDecisionStatement();
673             }
674             IMPL_STRING_ATTRIB(Resource);
675             IMPL_STRING_ATTRIB(Decision);
676             IMPL_TYPED_CHILD(Evidence);
677             IMPL_TYPED_CHILDREN(Action, m_pos_Evidence);
678     
679         protected:
680             void marshallAttributes(DOMElement* domElement) const {
681                 MARSHALL_STRING_ATTRIB(Resource,RESOURCE,NULL);
682                 MARSHALL_STRING_ATTRIB(Decision,DECISION,NULL);
683                 SubjectStatementImpl::marshallAttributes(domElement);
684             }
685     
686             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
687                 PROC_TYPED_CHILD(Evidence,SAMLConstants::SAML1_NS,false);
688                 PROC_TYPED_CHILDREN(Action,SAMLConstants::SAML1_NS,false);
689                 SubjectStatementImpl::processChildElement(childXMLObject,root);
690             }
691     
692             void processAttribute(const DOMAttr* attribute) {
693                 PROC_STRING_ATTRIB(Resource,RESOURCE,NULL);
694                 PROC_STRING_ATTRIB(Decision,DECISION,NULL);
695                 SubjectStatementImpl::processAttribute(attribute);
696             }
697         };
698
699         class SAML_DLLLOCAL AttributeDesignatorImpl : public virtual AttributeDesignator,
700             public AbstractSimpleElement,
701             public AbstractDOMCachingXMLObject,
702             public AbstractXMLObjectMarshaller,
703             public AbstractXMLObjectUnmarshaller
704         {
705         public:
706             virtual ~AttributeDesignatorImpl() {
707                 XMLString::release(&m_AttributeName);
708                 XMLString::release(&m_AttributeNamespace);
709             }
710     
711             AttributeDesignatorImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
712                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
713                 init();
714             }
715                 
716             AttributeDesignatorImpl(const AttributeDesignatorImpl& src)
717                     : AbstractXMLObject(src), AbstractSimpleElement(src), AbstractDOMCachingXMLObject(src) {
718                 init();
719                 setAttributeName(src.getAttributeName());
720                 setAttributeNamespace(src.getAttributeNamespace());
721             }
722             
723             void init() {
724                 m_AttributeName=m_AttributeNamespace=NULL;
725             }
726             
727             IMPL_XMLOBJECT_CLONE(AttributeDesignator);
728             IMPL_STRING_ATTRIB(AttributeName);
729             IMPL_STRING_ATTRIB(AttributeNamespace);
730     
731         protected:
732             void marshallAttributes(DOMElement* domElement) const {
733                 MARSHALL_STRING_ATTRIB(AttributeName,ATTRIBUTENAME,NULL);
734                 MARSHALL_STRING_ATTRIB(AttributeNamespace,ATTRIBUTENAMESPACE,NULL);
735             }
736     
737             void processAttribute(const DOMAttr* attribute) {
738                 PROC_STRING_ATTRIB(AttributeName,ATTRIBUTENAME,NULL);
739                 PROC_STRING_ATTRIB(AttributeNamespace,ATTRIBUTENAMESPACE,NULL);
740             }
741         };
742
743         class SAML_DLLLOCAL AttributeImpl : public virtual Attribute,
744             public AbstractComplexElement,
745             public AbstractDOMCachingXMLObject,
746             public AbstractXMLObjectMarshaller,
747             public AbstractXMLObjectUnmarshaller
748         {
749         public:
750             virtual ~AttributeImpl() {
751                 XMLString::release(&m_AttributeName);
752                 XMLString::release(&m_AttributeNamespace);
753             }
754     
755             AttributeImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
756                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
757                 init();
758             }
759                 
760             AttributeImpl(const AttributeImpl& src)
761                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
762                 init();
763                 setAttributeName(src.getAttributeName());
764                 setAttributeNamespace(src.getAttributeNamespace());
765                 VectorOf(XMLObject) v=getAttributeValues();
766                 for (vector<XMLObject*>::const_iterator i=src.m_AttributeValues.begin(); i!=src.m_AttributeValues.end(); i++) {
767                     if (*i) {
768                         v.push_back((*i)->clone());
769                     }
770                 }
771             }
772             
773             void init() {
774                 m_AttributeName=m_AttributeNamespace=NULL;
775             }
776             
777             IMPL_XMLOBJECT_CLONE(Attribute);
778             AttributeDesignator* cloneAttributeDesignator() const {
779                 return cloneAttribute();
780             }
781             IMPL_STRING_ATTRIB(AttributeName);
782             IMPL_STRING_ATTRIB(AttributeNamespace);
783             IMPL_XMLOBJECT_CHILDREN(AttributeValue,m_children.end());
784     
785         protected:
786             void marshallAttributes(DOMElement* domElement) const {
787                 MARSHALL_STRING_ATTRIB(AttributeName,ATTRIBUTENAME,NULL);
788                 MARSHALL_STRING_ATTRIB(AttributeNamespace,ATTRIBUTENAMESPACE,NULL);
789             }
790
791             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
792                 getAttributeValues().push_back(childXMLObject);
793             }
794
795             void processAttribute(const DOMAttr* attribute) {
796                 PROC_STRING_ATTRIB(AttributeName,ATTRIBUTENAME,NULL);
797                 PROC_STRING_ATTRIB(AttributeNamespace,ATTRIBUTENAMESPACE,NULL);
798             }
799         };
800
801         class SAML_DLLLOCAL AttributeValueImpl : public virtual AttributeValue, public AnyElementImpl
802         {
803         public:
804             virtual ~AttributeValueImpl() {}
805     
806             AttributeValueImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
807                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
808             }
809                 
810             AttributeValueImpl(const AttributeValueImpl& src) : AnyElementImpl(src) {}
811             
812             IMPL_XMLOBJECT_CLONE(AttributeValue);
813         };
814
815         class SAML_DLLLOCAL AttributeStatementImpl : public virtual AttributeStatement, public SubjectStatementImpl
816         {
817         public:
818             virtual ~AttributeStatementImpl() {}
819     
820             AttributeStatementImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
821                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
822             }
823                 
824             AttributeStatementImpl(const AttributeStatementImpl& src)
825                     : AbstractXMLObject(src), SubjectStatementImpl(src) {
826                 VectorOf(Attribute) v=getAttributes();
827                 for (vector<Attribute*>::const_iterator i=src.m_Attributes.begin(); i!=src.m_Attributes.end(); i++) {
828                     if (*i) {
829                         v.push_back((*i)->cloneAttribute());
830                     }
831                 }
832             }
833             
834             IMPL_XMLOBJECT_CLONE(AttributeStatement);
835             SubjectStatement* cloneSubjectStatement() const {
836                 return cloneAttributeStatement();
837             }
838             Statement* cloneStatement() const {
839                 return cloneAttributeStatement();
840             }
841             IMPL_TYPED_CHILDREN(Attribute, m_children.end());
842     
843         protected:
844             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
845                 PROC_TYPED_CHILDREN(Attribute,SAMLConstants::SAML1_NS,true);
846                 SubjectStatementImpl::processChildElement(childXMLObject,root);
847             }
848         };
849
850         class SAML_DLLLOCAL AdviceImpl : public virtual Advice,
851             public AbstractComplexElement,
852             public AbstractDOMCachingXMLObject,
853             public AbstractXMLObjectMarshaller,
854             public AbstractXMLObjectUnmarshaller
855         {
856         public:
857             virtual ~AdviceImpl() {}
858     
859             AdviceImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
860                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
861             }
862                 
863             AdviceImpl(const AdviceImpl& src)
864                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
865                 for (list<XMLObject*>::const_iterator i=src.m_children.begin(); i!=src.m_children.end(); i++) {
866                     if (*i) {
867                         AssertionIDReference* ref=dynamic_cast<AssertionIDReference*>(*i);
868                         if (ref) {
869                             getAssertionIDReferences().push_back(ref->cloneAssertionIDReference());
870                             continue;
871                         }
872     
873                         Assertion* assertion=dynamic_cast<Assertion*>(*i);
874                         if (assertion) {
875                             getAssertions().push_back(assertion->cloneAssertion());
876                             continue;
877                         }
878     
879                         getOthers().push_back((*i)->clone());
880                     }
881                 }
882             }
883             
884             IMPL_XMLOBJECT_CLONE(Advice);
885             IMPL_TYPED_CHILDREN(AssertionIDReference,m_children.end());
886             IMPL_TYPED_CHILDREN(Assertion,m_children.end());
887             IMPL_XMLOBJECT_CHILDREN(Other,m_children.end());
888     
889         protected:
890             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
891                 PROC_TYPED_CHILDREN(AssertionIDReference,SAMLConstants::SAML1_NS,false);
892                 PROC_TYPED_CHILDREN(Assertion,SAMLConstants::SAML1_NS,true);
893                 
894                 // Unknown child.
895                 const XMLCh* nsURI=root->getNamespaceURI();
896                 if (!XMLString::equals(nsURI,SAMLConstants::SAML1_NS) && nsURI && *nsURI) {
897                     getOthers().push_back(childXMLObject);
898                     return;
899                 }
900                 
901                 AbstractXMLObjectUnmarshaller::processChildElement(childXMLObject,root);
902             }
903         };
904
905         class SAML_DLLLOCAL AssertionImpl : public virtual Assertion,
906             public AbstractComplexElement,
907             public AbstractDOMCachingXMLObject,
908             public AbstractXMLObjectMarshaller,
909             public AbstractXMLObjectUnmarshaller
910         {
911             void init() {
912                 m_MinorVersion=NULL;
913                 m_AssertionID=NULL;
914                 m_Issuer=NULL;
915                 m_IssueInstant=NULL;
916                 m_children.push_back(NULL);
917                 m_children.push_back(NULL);
918                 m_children.push_back(NULL);
919                 m_Conditions=NULL;
920                 m_Advice=NULL;
921                 m_Signature=NULL;
922                 m_pos_Conditions=m_children.begin();
923                 m_pos_Advice=m_pos_Conditions;
924                 ++m_pos_Advice;
925                 m_pos_Signature=m_pos_Advice;
926                 ++m_pos_Signature;
927             }
928         public:
929             virtual ~AssertionImpl() {
930                 XMLString::release(&m_MinorVersion);
931                 XMLString::release(&m_AssertionID);
932                 XMLString::release(&m_Issuer);
933                 delete m_IssueInstant;
934             }
935     
936             AssertionImpl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const QName* schemaType)
937                 : AbstractXMLObject(nsURI, localName, prefix, schemaType) {
938                 init();
939             }
940                 
941             AssertionImpl(const AssertionImpl& src)
942                     : AbstractXMLObject(src), AbstractComplexElement(src), AbstractDOMCachingXMLObject(src) {
943                 init();
944                 setMinorVersion(src.m_MinorVersion);
945                 setAssertionID(src.getAssertionID());
946                 setIssuer(src.getIssuer());
947                 setIssueInstant(src.getIssueInstant());
948                 if (src.getConditions())
949                     setConditions(src.getConditions()->cloneConditions());
950                 if (src.getAdvice())
951                     setAdvice(src.getAdvice()->cloneAdvice());
952                 if (src.getSignature())
953                     setSignature(src.getSignature()->cloneSignature());
954                 for (list<XMLObject*>::const_iterator i=src.m_children.begin(); i!=src.m_children.end(); i++) {
955                     if (*i) {
956                         AuthenticationStatement* authst=dynamic_cast<AuthenticationStatement*>(*i);
957                         if (authst) {
958                             getAuthenticationStatements().push_back(authst->cloneAuthenticationStatement());
959                             continue;
960                         }
961
962                         AttributeStatement* attst=dynamic_cast<AttributeStatement*>(*i);
963                         if (attst) {
964                             getAttributeStatements().push_back(attst->cloneAttributeStatement());
965                             continue;
966                         }
967
968                         AuthorizationDecisionStatement* authzst=dynamic_cast<AuthorizationDecisionStatement*>(*i);
969                         if (authzst) {
970                             getAuthorizationDecisionStatements().push_back(authzst->cloneAuthorizationDecisionStatement());
971                             continue;
972                         }
973     
974                         SubjectStatement* subst=dynamic_cast<SubjectStatement*>(*i);
975                         if (subst) {
976                             getSubjectStatements().push_back(subst->cloneSubjectStatement());
977                             continue;
978                         }
979     
980                         Statement* st=dynamic_cast<Statement*>(*i);
981                         if (st) {
982                             getStatements().push_back(st->cloneStatement());
983                             continue;
984                         }
985                     }
986                 }
987             }
988             
989             //IMPL_TYPED_CHILD(Signature);
990             // Need customized setter.
991         protected:
992             Signature* m_Signature;
993             list<XMLObject*>::iterator m_pos_Signature;
994         public:
995             Signature* getSignature() const {
996                 return m_Signature;
997             }
998             
999             void setSignature(Signature* sig) {
1000                 prepareForAssignment(m_Signature,sig);
1001                 *m_pos_Signature=m_Signature=sig;
1002                 // Sync content reference back up.
1003                 if (m_Signature)
1004                     m_Signature->setContentReference(new opensaml::ContentReference(*this));
1005             }
1006             
1007             IMPL_XMLOBJECT_CLONE(Assertion);
1008             IMPL_INTEGER_ATTRIB(MinorVersion);
1009             IMPL_STRING_ATTRIB(AssertionID);    // have to special-case getXMLID
1010             const XMLCh* getXMLID() const {
1011                 pair<bool,int> v = getMinorVersion();
1012                 return (!v.first || v.second > 0) ? m_AssertionID : NULL;
1013             }
1014             IMPL_STRING_ATTRIB(Issuer);
1015             IMPL_DATETIME_ATTRIB(IssueInstant,0);
1016             IMPL_TYPED_CHILD(Conditions);
1017             IMPL_TYPED_CHILD(Advice);
1018             IMPL_TYPED_CHILDREN(Statement, m_pos_Signature);
1019             IMPL_TYPED_CHILDREN(SubjectStatement, m_pos_Signature);
1020             IMPL_TYPED_CHILDREN(AuthenticationStatement, m_pos_Signature);
1021             IMPL_TYPED_CHILDREN(AttributeStatement, m_pos_Signature);
1022             IMPL_TYPED_CHILDREN(AuthorizationDecisionStatement, m_pos_Signature);
1023     
1024         protected:
1025             void marshallAttributes(DOMElement* domElement) const {
1026                 static const XMLCh MAJORVERSION[] = UNICODE_LITERAL_12(M,a,j,o,r,V,e,r,s,i,o,n);
1027                 domElement->setAttributeNS(NULL,MAJORVERSION,XMLConstants::XML_ONE);
1028                 if (!m_MinorVersion)
1029                     const_cast<AssertionImpl*>(this)->m_MinorVersion=XMLString::replicate(XMLConstants::XML_ONE);
1030                 MARSHALL_INTEGER_ATTRIB(MinorVersion,MINORVERSION,NULL);
1031                 if (!m_AssertionID)
1032                     const_cast<AssertionImpl*>(this)->m_AssertionID=SAMLConfig::getConfig().generateIdentifier();
1033                 MARSHALL_ID_ATTRIB(AssertionID,ASSERTIONID,NULL);
1034                 MARSHALL_STRING_ATTRIB(Issuer,ISSUER,NULL);
1035                 if (!m_IssueInstant) {
1036                     const_cast<AssertionImpl*>(this)->m_IssueInstantEpoch=time(NULL);
1037                     const_cast<AssertionImpl*>(this)->m_IssueInstant=new DateTime(m_IssueInstantEpoch);
1038                 }
1039                 MARSHALL_DATETIME_ATTRIB(IssueInstant,ISSUEINSTANT,NULL);
1040             }
1041     
1042             void processChildElement(XMLObject* childXMLObject, const DOMElement* root) {
1043                 PROC_TYPED_CHILD(Conditions,SAMLConstants::SAML1_NS,false);
1044                 PROC_TYPED_CHILD(Advice,SAMLConstants::SAML1_NS,false);
1045                 PROC_TYPED_CHILD(Signature,XMLConstants::XMLSIG_NS,false);
1046                 PROC_TYPED_CHILDREN(AuthenticationStatement,SAMLConstants::SAML1_NS,false);
1047                 PROC_TYPED_CHILDREN(AttributeStatement,SAMLConstants::SAML1_NS,false);
1048                 PROC_TYPED_CHILDREN(AuthorizationDecisionStatement,SAMLConstants::SAML1_NS,false);
1049                 PROC_TYPED_CHILDREN(SubjectStatement,SAMLConstants::SAML1_NS,true);
1050                 PROC_TYPED_CHILDREN(Statement,SAMLConstants::SAML1_NS,true);
1051                 AbstractXMLObjectUnmarshaller::processChildElement(childXMLObject,root);
1052             }
1053     
1054             void processAttribute(const DOMAttr* attribute) {
1055                 static const XMLCh MAJORVERSION[] = UNICODE_LITERAL_12(M,a,j,o,r,V,e,r,s,i,o,n);
1056                 if (XMLHelper::isNodeNamed(attribute,NULL,MAJORVERSION)) {
1057                     if (!XMLString::equals(attribute->getValue(),XMLConstants::XML_ONE))
1058                         throw UnmarshallingException("Assertion has invalid major version.");
1059                 }
1060                 PROC_INTEGER_ATTRIB(MinorVersion,MINORVERSION,NULL);
1061                 PROC_ID_ATTRIB(AssertionID,ASSERTIONID,NULL);
1062                 PROC_STRING_ATTRIB(Issuer,ISSUER,NULL);
1063                 PROC_DATETIME_ATTRIB(IssueInstant,ISSUEINSTANT,NULL);
1064             }
1065         };
1066     
1067     };
1068 };
1069
1070 #if defined (_MSC_VER)
1071     #pragma warning( pop )
1072 #endif
1073
1074 // Builder Implementations
1075
1076 IMPL_XMLOBJECTBUILDER(Action);
1077 IMPL_XMLOBJECTBUILDER(Advice);
1078 IMPL_XMLOBJECTBUILDER(Assertion);
1079 IMPL_XMLOBJECTBUILDER(AssertionIDReference);
1080 IMPL_XMLOBJECTBUILDER(Attribute);
1081 IMPL_XMLOBJECTBUILDER(AttributeDesignator);
1082 IMPL_XMLOBJECTBUILDER(AttributeStatement);
1083 IMPL_XMLOBJECTBUILDER(AttributeValue);
1084 IMPL_XMLOBJECTBUILDER(Audience);
1085 IMPL_XMLOBJECTBUILDER(AudienceRestrictionCondition);
1086 IMPL_XMLOBJECTBUILDER(AuthenticationStatement);
1087 IMPL_XMLOBJECTBUILDER(AuthorizationDecisionStatement);
1088 IMPL_XMLOBJECTBUILDER(AuthorityBinding);
1089 IMPL_XMLOBJECTBUILDER(Conditions);
1090 IMPL_XMLOBJECTBUILDER(ConfirmationMethod);
1091 IMPL_XMLOBJECTBUILDER(DoNotCacheCondition);
1092 IMPL_XMLOBJECTBUILDER(Evidence);
1093 IMPL_XMLOBJECTBUILDER(NameIdentifier);
1094 IMPL_XMLOBJECTBUILDER(Subject);
1095 IMPL_XMLOBJECTBUILDER(SubjectConfirmation);
1096 IMPL_XMLOBJECTBUILDER(SubjectConfirmationData);
1097 IMPL_XMLOBJECTBUILDER(SubjectLocality);
1098
1099 // Unicode literals
1100 const XMLCh Action::LOCAL_NAME[] =                  UNICODE_LITERAL_6(A,c,t,i,o,n);
1101 const XMLCh Action::TYPE_NAME[] =                   UNICODE_LITERAL_10(A,c,t,i,o,n,T,y,p,e);
1102 const XMLCh Action::NAMESPACE_ATTRIB_NAME[] =       UNICODE_LITERAL_9(N,a,m,e,s,p,a,c,e);
1103 const XMLCh Advice::LOCAL_NAME[] =                  UNICODE_LITERAL_6(A,d,v,i,c,e);
1104 const XMLCh Advice::TYPE_NAME[] =                   UNICODE_LITERAL_10(A,d,v,i,c,e,T,y,p,e);
1105 const XMLCh Assertion::LOCAL_NAME[] =               UNICODE_LITERAL_9(A,s,s,e,r,t,i,o,n);
1106 const XMLCh Assertion::TYPE_NAME[] =                UNICODE_LITERAL_13(A,s,s,e,r,t,i,o,n,T,y,p,e);
1107 const XMLCh Assertion::MINORVERSION_ATTRIB_NAME[] = UNICODE_LITERAL_12(M,i,n,o,r,V,e,r,s,i,o,n);
1108 const XMLCh Assertion::ASSERTIONID_ATTRIB_NAME[] =  UNICODE_LITERAL_11(A,s,s,e,r,t,i,o,n,I,D);
1109 const XMLCh Assertion::ISSUER_ATTRIB_NAME[] =       UNICODE_LITERAL_6(I,s,s,u,e,r);
1110 const XMLCh Assertion::ISSUEINSTANT_ATTRIB_NAME[] = UNICODE_LITERAL_12(I,s,s,u,e,I,n,s,t,a,n,t);
1111 const XMLCh AssertionIDReference::LOCAL_NAME[] =    UNICODE_LITERAL_20(A,s,s,e,r,t,i,o,n,I,D,R,e,f,e,r,e,n,c,e);
1112 const XMLCh Attribute::LOCAL_NAME[] =               UNICODE_LITERAL_9(A,t,t,r,i,b,u,t,e);
1113 const XMLCh Attribute::TYPE_NAME[] =                UNICODE_LITERAL_13(A,t,t,r,i,b,u,t,e,T,y,p,e);
1114 const XMLCh AttributeDesignator::LOCAL_NAME[] =     UNICODE_LITERAL_19(A,t,t,r,i,b,u,t,e,D,e,s,i,g,n,a,t,o,r);
1115 const XMLCh AttributeDesignator::TYPE_NAME[] =      UNICODE_LITERAL_23(A,t,t,r,i,b,u,t,e,D,e,s,i,g,n,a,t,o,r,T,y,p,e);
1116 const XMLCh AttributeDesignator::ATTRIBUTENAME_ATTRIB_NAME[] =              UNICODE_LITERAL_13(A,t,t,r,i,b,u,t,e,N,a,m,e);
1117 const XMLCh AttributeDesignator::ATTRIBUTENAMESPACE_ATTRIB_NAME[] =         UNICODE_LITERAL_18(A,t,t,r,i,b,u,t,e,N,a,m,e,s,p,a,c,e);
1118 const XMLCh AttributeStatement::LOCAL_NAME[] =      UNICODE_LITERAL_18(A,t,t,r,i,b,u,t,e,S,t,a,t,e,m,e,n,t);
1119 const XMLCh AttributeStatement::TYPE_NAME[] =       UNICODE_LITERAL_22(A,t,t,r,i,b,u,t,e,S,t,a,t,e,m,e,n,t,T,y,p,e);
1120 const XMLCh AttributeValue::LOCAL_NAME[] =          UNICODE_LITERAL_14(A,t,t,r,i,b,u,t,e,V,a,l,u,e);
1121 const XMLCh Audience::LOCAL_NAME[] =                UNICODE_LITERAL_8(A,u,d,i,e,n,c,e);
1122 const XMLCh AudienceRestrictionCondition::LOCAL_NAME[] =    UNICODE_LITERAL_28(A,u,d,i,e,n,c,e,R,e,s,t,r,i,c,t,i,o,n,C,o,n,d,i,t,i,o,n);
1123 const XMLCh AudienceRestrictionCondition::TYPE_NAME[] =     UNICODE_LITERAL_32(A,u,d,i,e,n,c,e,R,e,s,t,r,i,c,t,i,o,n,C,o,n,d,i,t,i,o,n,T,y,p,e);
1124 const XMLCh AuthenticationStatement::LOCAL_NAME[] = UNICODE_LITERAL_23(A,u,t,h,e,n,t,i,c,a,t,i,o,n,S,t,a,t,e,m,e,n,t);
1125 const XMLCh AuthenticationStatement::TYPE_NAME[] =  UNICODE_LITERAL_27(A,u,t,h,e,n,t,i,c,a,t,i,o,n,S,t,a,t,e,m,e,n,t,T,y,p,e);
1126 const XMLCh AuthenticationStatement::AUTHENTICATIONMETHOD_ATTRIB_NAME[] =   UNICODE_LITERAL_20(A,u,t,h,e,n,t,i,c,a,t,i,o,n,M,e,t,h,o,d);
1127 const XMLCh AuthenticationStatement::AUTHENTICATIONINSTANT_ATTRIB_NAME[] =  UNICODE_LITERAL_21(A,u,t,h,e,n,t,i,c,a,t,i,o,n,I,n,s,t,a,n,t);
1128 const XMLCh AuthorityBinding::LOCAL_NAME[] =        UNICODE_LITERAL_16(A,u,t,h,o,r,i,t,y,B,i,n,d,i,n,g);
1129 const XMLCh AuthorityBinding::TYPE_NAME[] =         UNICODE_LITERAL_20(A,u,t,h,o,r,i,t,y,B,i,n,d,i,n,g,T,y,p,e);
1130 const XMLCh AuthorityBinding::AUTHORITYKIND_ATTRIB_NAME[] = UNICODE_LITERAL_13(A,u,t,h,o,r,i,t,y,K,i,n,d);
1131 const XMLCh AuthorityBinding::LOCATION_ATTRIB_NAME[] =      UNICODE_LITERAL_8(L,o,c,a,t,i,o,n);
1132 const XMLCh AuthorityBinding::BINDING_ATTRIB_NAME[] =       UNICODE_LITERAL_7(B,i,n,d,i,n,g);
1133 const XMLCh AuthorizationDecisionStatement::LOCAL_NAME[] =  UNICODE_LITERAL_30(A,u,t,h,o,r,i,z,a,t,i,o,n,D,e,c,i,s,i,o,n,S,t,a,t,e,m,e,n,t);
1134 const XMLCh AuthorizationDecisionStatement::TYPE_NAME[] =   UNICODE_LITERAL_34(A,u,t,h,o,r,i,z,a,t,i,o,n,D,e,c,i,s,i,o,n,S,t,a,t,e,m,e,n,t,T,y,p,e);
1135 const XMLCh AuthorizationDecisionStatement::RESOURCE_ATTRIB_NAME[] =        UNICODE_LITERAL_8(R,e,s,o,u,r,c,e);
1136 const XMLCh AuthorizationDecisionStatement::DECISION_ATTRIB_NAME[] =        UNICODE_LITERAL_8(D,e,c,i,s,i,o,n);
1137 const XMLCh AuthorizationDecisionStatement::DECISION_PERMIT[] =             UNICODE_LITERAL_6(P,e,r,m,i,t);
1138 const XMLCh AuthorizationDecisionStatement::DECISION_DENY[] =               UNICODE_LITERAL_4(D,e,n,y);
1139 const XMLCh AuthorizationDecisionStatement::DECISION_INDETERMINATE[] =      UNICODE_LITERAL_13(I,n,d,e,t,e,r,m,i,n,a,t,e);
1140 const XMLCh Condition::LOCAL_NAME[] =               UNICODE_LITERAL_9(C,o,n,d,i,t,i,o,n);
1141 const XMLCh Conditions::LOCAL_NAME[] =              UNICODE_LITERAL_10(C,o,n,d,i,t,i,o,n,s);
1142 const XMLCh Conditions::TYPE_NAME[] =               UNICODE_LITERAL_14(C,o,n,d,i,t,i,o,n,s,T,y,p,e);
1143 const XMLCh Conditions::NOTBEFORE_ATTRIB_NAME[] =   UNICODE_LITERAL_9(N,o,t,B,e,f,o,r,e);
1144 const XMLCh Conditions::NOTONORAFTER_ATTRIB_NAME[] =UNICODE_LITERAL_12(N,o,t,O,n,O,r,A,f,t,e,r);
1145 const XMLCh ConfirmationMethod::LOCAL_NAME[] =      UNICODE_LITERAL_18(C,o,n,f,i,r,m,a,t,i,o,n,M,e,t,h,o,d);
1146 const XMLCh DoNotCacheCondition::LOCAL_NAME[] =     UNICODE_LITERAL_19(D,o,N,o,t,C,a,c,h,e,C,o,n,d,i,t,i,o,n);
1147 const XMLCh DoNotCacheCondition::TYPE_NAME[] =      UNICODE_LITERAL_23(D,o,N,o,t,C,a,c,h,e,C,o,n,d,i,t,i,o,n,T,y,p,e);
1148 const XMLCh Evidence::LOCAL_NAME[] =                UNICODE_LITERAL_8(E,v,i,d,e,n,c,e);
1149 const XMLCh Evidence::TYPE_NAME[] =                 UNICODE_LITERAL_12(E,v,i,d,e,n,c,e,T,y,p,e);
1150 const XMLCh NameIdentifier::LOCAL_NAME[] =          UNICODE_LITERAL_14(N,a,m,e,I,d,e,n,t,i,f,i,e,r);
1151 const XMLCh NameIdentifier::TYPE_NAME[] =           UNICODE_LITERAL_18(N,a,m,e,I,d,e,n,t,i,f,i,e,r,T,y,p,e);
1152 const XMLCh NameIdentifier::NAMEQUALIFIER_ATTRIB_NAME[] =   UNICODE_LITERAL_13(N,a,m,e,Q,u,a,l,i,f,i,e,r);
1153 const XMLCh NameIdentifier::FORMAT_ATTRIB_NAME[] =  UNICODE_LITERAL_6(F,o,r,m,a,t);
1154 const XMLCh Statement::LOCAL_NAME[] =               UNICODE_LITERAL_9(S,t,a,t,e,m,e,n,t);
1155 const XMLCh Subject::LOCAL_NAME[] =                 UNICODE_LITERAL_7(S,u,b,j,e,c,t);
1156 const XMLCh Subject::TYPE_NAME[] =                  UNICODE_LITERAL_11(S,u,b,j,e,c,t,T,y,p,e);
1157 const XMLCh SubjectConfirmation::LOCAL_NAME[] =     UNICODE_LITERAL_19(S,u,b,j,e,c,t,C,o,n,f,i,r,m,a,t,i,o,n);
1158 const XMLCh SubjectConfirmation::TYPE_NAME[] =      UNICODE_LITERAL_23(S,u,b,j,e,c,t,C,o,n,f,i,r,m,a,t,i,o,n,T,y,p,e);
1159 const XMLCh SubjectConfirmationData::LOCAL_NAME[] = UNICODE_LITERAL_23(S,u,b,j,e,c,t,C,o,n,f,i,r,m,a,t,i,o,n,D,a,t,a);
1160 const XMLCh SubjectLocality::LOCAL_NAME[] =         UNICODE_LITERAL_15(S,u,b,j,e,c,t,L,o,c,a,l,i,t,y);
1161 const XMLCh SubjectLocality::TYPE_NAME[] =          UNICODE_LITERAL_19(S,u,b,j,e,c,t,L,o,c,a,l,i,t,y,T,y,p,e);
1162 const XMLCh SubjectLocality::IPADDRESS_ATTRIB_NAME[] =      UNICODE_LITERAL_9(I,P,A,d,d,r,e,s,s);
1163 const XMLCh SubjectLocality::DNSADDRESS_ATTRIB_NAME[] =     UNICODE_LITERAL_10(D,N,S,A,d,d,r,e,s,s);
1164 const XMLCh SubjectStatement::LOCAL_NAME[] =        UNICODE_LITERAL_16(S,u,b,j,e,c,t,S,t,a,t,e,m,e,n,t);
1165
1166 const XMLCh NameIdentifier::UNSPECIFIED[] = // urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified
1167 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1168   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1169   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_1, chColon,
1170   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_i, chLatin_d, chDash,
1171   chLatin_f, chLatin_o, chLatin_r, chLatin_m, chLatin_a, chLatin_t, chColon,
1172   chLatin_u, chLatin_n, chLatin_s, chLatin_p, chLatin_e, chLatin_c, chLatin_i, chLatin_f, chLatin_i, chLatin_e, chLatin_d, chLatin_d, chNull
1173 };
1174
1175 const XMLCh NameIdentifier::EMAIL[] = // urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress
1176 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1177   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1178   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_1, chColon,
1179   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_i, chLatin_d, chDash,
1180   chLatin_f, chLatin_o, chLatin_r, chLatin_m, chLatin_a, chLatin_t, chColon,
1181   chLatin_e, chLatin_m, chLatin_a, chLatin_i, chLatin_l, chLatin_A, chLatin_d, chLatin_d, chLatin_r, chLatin_e, chLatin_s, chLatin_s, chNull
1182 };
1183
1184 const XMLCh NameIdentifier::X509_SUBJECT[] = // urn:oasis:names:tc:SAML:1.1:nameid-format:X509SubjectName
1185 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1186   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1187   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_1, chColon,
1188   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_i, chLatin_d, chDash,
1189   chLatin_f, chLatin_o, chLatin_r, chLatin_m, chLatin_a, chLatin_t, chColon,
1190   chLatin_X, chDigit_5, chDigit_0, chDigit_9, chLatin_S, chLatin_u, chLatin_b, chLatin_j, chLatin_e, chLatin_c, chLatin_t,
1191   chLatin_N, chLatin_a, chLatin_m, chLatin_e, chNull
1192 };
1193
1194 const XMLCh NameIdentifier::WIN_DOMAIN_QUALIFIED[] = // urn:oasis:names:tc:SAML:1.1:nameid-format:WindowsDomainQualifiedName
1195 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1196   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1197   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_1, chColon,
1198   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_i, chLatin_d, chDash,
1199   chLatin_f, chLatin_o, chLatin_r, chLatin_m, chLatin_a, chLatin_t, chColon,
1200   chLatin_W, chLatin_i, chLatin_n, chLatin_d, chLatin_o, chLatin_w, chLatin_s,
1201   chLatin_D, chLatin_o, chLatin_m, chLatin_a, chLatin_i, chLatin_n,
1202   chLatin_Q, chLatin_u, chLatin_a, chLatin_l, chLatin_i, chLatin_f, chLatin_i, chLatin_e, chLatin_d,
1203   chLatin_N, chLatin_a, chLatin_m, chLatin_e, chNull
1204 };
1205
1206 const XMLCh SubjectConfirmation::ARTIFACT01[] = // urn:oasis:names:tc:SAML:1.0:cm:artifact-01
1207 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1208   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1209   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1210   chLatin_c, chLatin_m, chColon, chLatin_a, chLatin_r, chLatin_t, chLatin_i, chLatin_f, chLatin_a, chLatin_c, chLatin_t,
1211       chDash, chDigit_0, chDigit_1, chNull
1212 };
1213
1214 const XMLCh SubjectConfirmation::ARTIFACT[] = // urn:oasis:names:tc:SAML:1.0:cm:artifact
1215 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1216   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1217   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1218   chLatin_c, chLatin_m, chColon, chLatin_a, chLatin_r, chLatin_t, chLatin_i, chLatin_f, chLatin_a, chLatin_c, chLatin_t, chNull
1219 };
1220
1221 const XMLCh SubjectConfirmation::BEARER[] = // urn:oasis:names:tc:SAML:1.0:cm:bearer
1222 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1223   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1224   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1225   chLatin_c, chLatin_m, chColon, chLatin_b, chLatin_e, chLatin_a, chLatin_r, chLatin_e, chLatin_r, chNull
1226 };
1227
1228 const XMLCh SubjectConfirmation::HOLDER_KEY[] = // urn:oasis:names:tc:SAML:1.0:cm:holder-of-key
1229 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1230   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1231   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1232   chLatin_c, chLatin_m, chColon, chLatin_h, chLatin_o, chLatin_l, chLatin_d, chLatin_e, chLatin_r, chDash,
1233       chLatin_o, chLatin_f, chDash, chLatin_k, chLatin_e, chLatin_y, chNull
1234 };
1235
1236 const XMLCh SubjectConfirmation::SENDER_VOUCHES[] = // urn:oasis:names:tc:SAML:1.0:cm:sender-vouches
1237 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1238   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1239   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1240   chLatin_c, chLatin_m, chColon, chLatin_s, chLatin_e, chLatin_n, chLatin_d, chLatin_e, chLatin_r, chDash,
1241       chLatin_v, chLatin_o, chLatin_u, chLatin_c, chLatin_h, chLatin_e, chLatin_s, chNull
1242 };
1243
1244 const XMLCh Action::RWEDC_ACTION_NAMESPACE[] = // urn:oasis:names:tc:SAML:1.0:action:rwedc
1245 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1246   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1247   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1248   chLatin_a, chLatin_c, chLatin_t, chLatin_i, chLatin_o, chLatin_n, chColon,
1249   chLatin_r, chLatin_w, chLatin_e, chLatin_d, chLatin_c, chNull
1250 };
1251
1252 const XMLCh Action::RWEDC_NEG_ACTION_NAMESPACE[] = // urn:oasis:names:tc:SAML:1.0:action:rwedc-negation
1253 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1254   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1255   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1256   chLatin_a, chLatin_c, chLatin_t, chLatin_i, chLatin_o, chLatin_n, chColon,
1257   chLatin_r, chLatin_w, chLatin_e, chLatin_d, chLatin_c, chDash,
1258   chLatin_n, chLatin_e, chLatin_g, chLatin_a, chLatin_t, chLatin_i, chLatin_o, chLatin_n, chNull
1259 };
1260
1261 const XMLCh Action::GHPP_ACTION_NAMESPACE[] = // urn:oasis:names:tc:SAML:1.0:action:ghpp
1262 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1263   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1264   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1265   chLatin_a, chLatin_c, chLatin_t, chLatin_i, chLatin_o, chLatin_n, chColon,
1266   chLatin_g, chLatin_h, chLatin_p, chLatin_p, chNull
1267 };
1268
1269 const XMLCh Action::UNIX_ACTION_NAMESPACE[] = // urn:oasis:names:tc:SAML:1.0:action:unix
1270 { chLatin_u, chLatin_r, chLatin_n, chColon, chLatin_o, chLatin_a, chLatin_s, chLatin_i, chLatin_s, chColon,
1271   chLatin_n, chLatin_a, chLatin_m, chLatin_e, chLatin_s, chColon, chLatin_t, chLatin_c, chColon,
1272   chLatin_S, chLatin_A, chLatin_M, chLatin_L, chColon, chDigit_1, chPeriod, chDigit_0, chColon,
1273   chLatin_a, chLatin_c, chLatin_t, chLatin_i, chLatin_o, chLatin_n, chColon,
1274   chLatin_u, chLatin_n, chLatin_i, chLatin_x, chNull
1275 };