<div dir="ltr">Using ValueRegex, this seems to work:<div><br></div><div>    <AttributeFilterPolicy id="example"><br>        <PolicyRequirementRule xsi:type="Requester"<br>                value="<a href="https://example.com/sp">https://example.com/sp</a>" /><br><br>        <AttributeRule attributeID="attrFoo"><br>            <PermitValueRule xsi:type="NOT"><br>               <Rule xsi:type="ValueRegex" attributeID="attrBar" regex="." /><br>            </PermitValueRule><br>        </AttributeRule><br><br>        <AttributeRule attributeID="uhAltUid"><br>            <PermitValueRule xsi:type="ANY" /><br>        </AttributeRule><br><br>    </AttributeFilterPolicy><br></div><div><br></div><div>I originally also looked at using ValueRegex, but on the ValueRegexConfiguration wiki page at <<a href="https://shibboleth.atlassian.net/wiki/spaces/IDP4/pages/1265631548/ValueRegexConfiguration">https://shibboleth.atlassian.net/wiki/spaces/IDP4/pages/1265631548/ValueRegexConfiguration</a>>, this approach looks like the Compound Matcher example which is labeled as deprecated, so that gave me pause and is why I settled on non-viable NumberOfAttributeValues attempt. Is this not a deprecated Compound Matcher as in that example?</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Nov 18, 2022 at 2:13 AM Rod Widdowson <<a href="mailto:rdw@steadingsoftware.com">rdw@steadingsoftware.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">It turns out that right now if you do a ValueRegex PolicyRule and the attribute doesn't exist then the PolicyRule is false.  So <br>
<br>
        <PolicyRequirementRule xsi:type="ValueRegex" regex=".*" attributeID="attrfoo"/><br>
<br>
Right now (and only right now), you are testing for the attribute having any (String) value and thus being present.<br>
<br>
However this behavior is not documented and may change in a future release.  In particular this area of code (how we deal with things not being there) is under active development so I'd defer strongly to Scott about this.  <br>
<br>
Me, I'd not rely on this until I saw it documented.<br>
<br>
        /Rod<br>
<br>
<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><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><font face="arial, sans-serif">Baron Fujimoto <<a href="mailto:baron@hawaii.edu" target="_blank">baron@hawaii.edu</a>> ::: UH Information Technology Services<br>minutas cantorum, minutas balorum, minutas carboratum descendus pantorum</font></div></div>