Skip to content
Snippets Groups Projects
Commit 0f9d215d authored by Hans Zandbelt's avatar Hans Zandbelt
Browse files

avoid sending empty attribute values

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@1708 44740490-163a-0410-bde0-09ae8108e29a
parent 3a204cf9
No related branches found
No related tags found
No related merge requests found
......@@ -51,6 +51,7 @@ function ADFS_GenerateResponse($issuer, $target, $nameid, $attributes) {
<saml:NameIdentifier Format="' . $nameidFormat . '">' . $nameid . '</saml:NameIdentifier>
</saml:Subject>';
foreach ($attributes as $name => $values) {
if ((!is_array($values)) || (count($values) == 0)) continue;
$result .= '<saml:Attribute AttributeNamespace="http://schemas.xmlsoap.org/claims" AttributeName="' . $name .'">';
foreach ($values as $value) {
$result .= '<saml:AttributeValue>' . $value . '</saml:AttributeValue>';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment