<div dir="ltr">Keith -<div><br></div><div> I was able to replicate your issue in my sandbox environment... after poking around for a while I was able to get the desired output by adding a space on either side (or both sides, for symmetry) of the $1, as below:</div><div><br></div><div> <Regex match="^(.+)$" dest="foo"> $1 </Regex></div><div><br></div><div> The extra white space appears to be trimmed out when I view the transformed attribute in the output of /Shibboleth.sso/Session, but I am not 100% positive that is the case.</div><div><div><br></div><div> I'll defer to others if this is a bug or a feature.</div></div><div><br></div><div>Steve.</div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Thu, Sep 18, 2025 at 2:59 PM Wessel, Keith via users <<a href="mailto:users@shibboleth.net">users@shibboleth.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi, all,<br>
<br>
We've got an SP that needs to have a SAML 2 attribute made available multiple times under different environment variables. I know the aliases attribute on the <Attribute> element of the attribute map is deprecated, but I'm confused on the right way to do this.<br>
<br>
Gemini (heaven help us all) keeps telling me I can just have multiple entries in the attribute map. I think it's confused... Shocking, I know. I know this works for mapping multiple SAML 2 names to the same internal ID to handle working with different IdPs to map different names from outside to a common place, but I don't think this works for mapping a single SAML 2 attribute to multiple internal ids. My test made it look like the SP matched the first entry it found with the given SAML 2 name, ignoring subsequent mappings to other IDs.<br>
<br>
So, we tried the Transform AttributeResolver in shibboleth2.xml after adding the plugins.so library to the OutOfProcess block. We added this inside the shibboleth2.xml:<br>
<br>
<AttributeResolver type="Transform" source="uid"> <br>
<Regex match="^(.+)$" dest="foo">$1</Regex> <br>
</AttributeResolver><br>
<br>
This produces, oddly, an empty env var called foo instead of one containing my uid.<br>
<br>
This also seems a little overly complex to just alias an attribute.<br>
<br>
What's the best way to make an attribute available under multiple IDs if we aren't doing any transforms on the values? And if it is the Transform plugin, what might I be doing wrong?<br>
<br>
Thanks,<br>
Keith<br>
<br>
-- <br>
For Consortium Member technical support, see <a href="https://shibboleth.atlassian.net/wiki/x/ZYEpPw" rel="noreferrer" target="_blank">https://shibboleth.atlassian.net/wiki/x/ZYEpPw</a><br>
To unsubscribe from this list send an email to <a href="mailto:users-unsubscribe@shibboleth.net" target="_blank">users-unsubscribe@shibboleth.net</a><br>
</blockquote></div>