Skip to Content.
Sympa Menu

shibboleth-dev - Re: [Shib-Dev] Mapped Attribute Definition

Subject: Shibboleth Developers

List archive

Re: [Shib-Dev] Mapped Attribute Definition


Chronological Thread 
  • From: Bradley Schwoerer <>
  • To:
  • Subject: Re: [Shib-Dev] Mapped Attribute Definition
  • Date: Sun, 09 Jan 2011 13:17:34 -0600

Yup, just double checked. That is what I have in production that fixed the
issues.

-Bradley


On 1/8/11 12:15 PM, "Chad La Joie"
<>
wrote:

> Bradley, just wanted to confirm, the patch you submitted on Jan 6 is the
> working patch you mentioned?
>
> On 12/28/10 2:40 PM, Bradley Schwoerer wrote:
>> The code below doesn't work as intended and I will include a working
>> patch to SC-132.
>>
>> -Bradley
>>
>>
>> On 12/24/10 12:04 AM, Bradley Schwoerer wrote:
>>> I submitted a bug about an NPE in MappedAttributeDefinition when the
>>> dependency attribute is null
>>> (https://bugs.internet2.edu/jira/browse/SC-132). I have a question
>>> about desired functionality though.
>>>
>>> In code it is setup to allow for multiple dependency attributes
>>> mapping to one new attribute. That is straight forward. What is not
>>> straight forward is the use of default value. If I have three
>>> dependency attributes like this instead of a single multivalued
>>> attribute:
>>>
>>> StudentRole = Withdrawn
>>> EmployeeRole = Staff
>>> AffiliateRole =
>>>
>>> And a rule setup like:
>>>
>>> <DefaultValue>AFFILIATE</DefaultValue>
>>>
>>> <ValueMap>
>>> <ReturnValue>STUDENT</ReturnValue>
>>> <SourceValue>enrolled</SourceValue>
>>> <SourceValue>eligible</SourceValue>
>>> </ValueMap>
>>>
>>> <ValueMap>
>>> <ReturnValue>EMPLOYEE</ReturnValue>
>>> <SourceValue>Staff</SourceValue>
>>> </ValueMap>
>>>
>>> <ValueMap>
>>> <ReturnValue>MEMBER</ReturnValue>
>>> <SourceValue>enrolled</SourceValue>
>>> <SourceValue>eligible</SourceValue>
>>> <SourceValue>Staff</SourceValue>
>>> </ValueMap>
>>>
>>> The result would be EMPLOYEE, MEMBER, and AFFILIATE, because on the
>>> third iteration of the for 'Object o' loop for the AffiliateRole
>>> attribute it would add the value defined as a default value. Is that
>>> the desired behavior? I would think that the default value rule would
>>> be added only after all attributes and values return no mapped value.
>>> In the above example the return would be EMPLOYEE and MEMBER instead.
>>> The exception would be if the passThru="true", then it would add each
>>> unmatched value so in code it would look like what is attached. I have
>>> included both a before and after instead of a diff for readability of
>>> logic.
>>>
>>> -Bradley
>>>
>>>
>>
>>





Archive powered by MHonArc 2.6.16.

Top of Page