Skip to content

Commit 611f5f4

Browse files
authored
SOAP and AttributeQuery class check
SOAP and AttributeQuery class check extending to namespaced classes
1 parent d09f5b8 commit 611f5f4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/AA/SAML2.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,12 @@ public function getBinding()
4444
{
4545
/* Receiving the attribute query */
4646
$binding = SAML2_Binding::getCurrentBinding();
47+
SimpleSAML_Logger::debug('[aa] binding: '.var_export($binding, true));
4748

4849
/* Supported binding is SOAP */
49-
if (!($binding instanceof SAML2_SOAP)) {
50+
if (!($binding instanceof SAML2_SOAP || $binding instanceof SAML2\SOAP)) {
5051
throw new SimpleSAML_Error_BadRequest('[aa] Unsupported binding. It must be SAML2_SOAP.');
5152
}
52-
SimpleSAML_Logger::debug('[aa] binding: '.var_export($binding, true));
5353

5454
return $binding;
5555
}
@@ -59,7 +59,7 @@ private function getQuery()
5959
$query = $this->binding->receive();
6060
SimpleSAML_Logger::debug('[aa] query: '.var_export($query, true));
6161

62-
if (!($query instanceof SAML2_AttributeQuery)) {
62+
if (!($query instanceof SAML2_AttributeQuery || $query instanceof SAML2\AttributeQuery)) {
6363
throw new SimpleSAML_Error_BadRequest('Invalid message received on AttributeQuery endpoint.');
6464
}
6565

0 commit comments

Comments
 (0)