From 3e5f6efda0c5fb10e4418e8ef27bdadb2670d418 Mon Sep 17 00:00:00 2001
From: Olav Morken <olav.morken@uninett.no>
Date: Thu, 27 Aug 2009 09:31:56 +0000
Subject: [PATCH] core_Auth_Process_TargetedID: Fix creation of
 eduPersonTargetetdID attribute.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

When using the 'attribute' option on the core:TargetedID-filter, the
resulting attribute would always contain the same value. This patch
fixes that.

Patch by José Alfonso.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@1713 44740490-163a-0410-bde0-09ae8108e29a
---
 modules/core/lib/Auth/Process/TargetedID.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/core/lib/Auth/Process/TargetedID.php b/modules/core/lib/Auth/Process/TargetedID.php
index 939ef9efc..98bc8910f 100644
--- a/modules/core/lib/Auth/Process/TargetedID.php
+++ b/modules/core/lib/Auth/Process/TargetedID.php
@@ -97,7 +97,7 @@ class sspmod_core_Auth_Process_TargetedID extends SimpleSAML_Auth_ProcessingFilt
 					'\', which is needed to generate the targeted ID.');
 			}
 
-			$userID = $state['Attributes'][$this->attribute];
+			$userID = $state['Attributes'][$this->attribute][0];
 		}
 
 
-- 
GitLab