summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIvan Kanakarakis <ivan.kanak@gmail.com>2021-01-21 01:02:25 +0200
committerIvan Kanakarakis <ivan.kanak@gmail.com>2021-01-21 01:02:25 +0200
commit3c4681661bf405c3692b7584f53c89c624d5431b (patch)
treeff4bad47e37beb9e7d0da02d89d45d8bbdab419b
parent12ec4a70c5aaf4c144f6b30a158193ca99bc76cd (diff)
downloadpysaml2-3c4681661bf405c3692b7584f53c89c624d5431b.tar.gz
Fix the parser to take into account both the xs and xsd namespace prefixes
Signed-off-by: Ivan Kanakarakis <ivan.kanak@gmail.com>
-rw-r--r--src/saml2/saml.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/saml2/saml.py b/src/saml2/saml.py
index 27808371..1b60822b 100644
--- a/src/saml2/saml.py
+++ b/src/saml2/saml.py
@@ -145,6 +145,12 @@ class AttributeValueBase(SamlBase):
except AttributeError:
self._extatt['xmlns:xs'] = XS_NAMESPACE
+ if typ.startswith('xsd:'):
+ try:
+ self.extension_attributes['xmlns:xsd'] = XS_NAMESPACE
+ except AttributeError:
+ self._extatt['xmlns:xsd'] = XS_NAMESPACE
+
def get_type(self):
try:
return self.extension_attributes[XSI_TYPE]