<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body dir="auto">
<div dir="ltr"></div>
<div dir="ltr"><br>
</div>
<div dir="ltr"><br>
<blockquote type="cite">On 3 Apr 2025, at 22:02, Cantor, Scott <cantor.2@osu.edu> wrote:<br>
<br>
</blockquote>
</div>
<blockquote type="cite">
<div dir="ltr">
<blockquote type="cite"><span>But since I may have multiple ranges I was wondering is</span><br>
</blockquote>
<blockquote type="cite"><span>there is any trick to IPRangePredicate</span><br>
</blockquote>
<span></span><br>
<span>If by trick you mean "give the predicate multiple ranges"; the input setter for that class takes a collection, not a single range.</span><br>
<span></span><br>
<span>https://urldefense.com/v3/__https://shibboleth.net/api/java-opensaml/5.1.4/org/opensaml/profile/logic/IPRangePredicate.html__;!!JFdNOqOXpB6UZW0!oiT7ta2A4XFxvWE04DqsrX29tW1gVxq6GDjifHPQBRZ54CGsOQsUCUIWowzKojyiy2Xam4_xDU2VsDxG_so3LczNdg$
</span><br>
<span></span><br>
<span>The only reason giving it one works is that Spring converts singletons to collections automatically.</span><br>
</div>
</blockquote>
<br>
<div>Sorry I wasn’t that clear in my statement. I was meant to say that I made the logic work using a simple if (request.getRemoteAddr().startsWith("192.168.42."))</div>
<div><br>
</div>
<div>But given that I’ll be having multiple IP ranges/subnets it will be tedious to make itwork with just chained startsWith() checks, hence the idea to use IPRangePredicate that seems to target what I’m looking for, but I must confess I wan’t able to correctly
call IPRangePredicate from withing the inline script, hence my call for assistance.</div>
<div><br>
</div>
<div>Youssef</div>
<div><br>
</div>
<span data-testid="renderer-code-block-line-13" data-ds--code--row="" class="" style="-webkit-text-size-adjust: auto; display: flex; margin-right: -8px; caret-color: rgb(41, 42, 46); color: rgb(41, 42, 46); font-family: "Atlassian Mono", ui-monospace, Menlo, "Segoe UI Mono", "Ubuntu Mono", monospace; white-space: pre; padding-right: 8px !important;"><br>
</span>
<div><span style="caret-color: rgb(41, 42, 46); color: rgb(41, 42, 46); font-family: "Atlassian Mono", ui-monospace, Menlo, "Segoe UI Mono", "Ubuntu Mono", monospace; white-space: pre; -webkit-text-size-adjust: auto;"> </span></div>
<span data-testid="renderer-code-block-line-14" data-ds--code--row="" class="" style="-webkit-text-size-adjust: auto; display: flex; margin-right: -8px; caret-color: rgb(41, 42, 46); color: rgb(41, 42, 46); font-family: "Atlassian Mono", ui-monospace, Menlo, "Segoe UI Mono", "Ubuntu Mono", monospace; font-size: 14px; white-space: pre; padding-right: 8px !important;"><span class="comment linenumber ds-line-number" data-ds--line-number="14" style="flex-shrink: 0; box-sizing: border-box; padding-left: 8px; margin-right: 8px; text-align: right; -webkit-user-select: none; float: left; display: inline-block !important; min-width: calc(2ch + 16px) !important; color: rgb(98, 111, 134); padding-right: 8px !important;"></span></span><br class="Apple-interchange-newline" style="-webkit-text-size-adjust: auto;">
</body>
</html>