shibboleth.HttpServletRequestSupplier not working when customObject is a map
Hendrik Tilger
tilger at ice.mpg.de
Thu Mar 6 13:59:19 UTC 2025
Hi everyone,
we are running Shibboleth IdP Version 5.1.3, Java 17on Ubuntu 24.02 LTS.
(We are trying to implement an authentication flow where the client IP is important for our nextFlowStrategy)
In /opt/shibboleth-idp/conf/authn/mfa-authn-config.xml I have defined a map:
<util:map id="mfa-input-data">
<entry key="attributeResolver" value-ref="shibboleth.AttributeResolverService"/>
<entry key="servletRequest" value-ref="shibboleth.HttpServletRequestSupplier"/>
</util:map>
This map is been used as custom object:
<bean id="checkSecondFactor" parent="shibboleth.ContextFunctions.Scripted" factory-method="inlineScript" p:customObject-ref="mfa-input-data">
Then we try the following within the bean:
[...]
CDATA:
userIPrequest = custom.get("servletRequest");
userIPstring = userIPrequest.getRemoteAddr();
... failed. Error:
org.openjdk.nashorn.internal.runtime.ECMAException: TypeError: userIPrequest.getRemoteAddr is not a function
Based on examples it should work, only difference is: we're using a map.
Could anyone help us with this?
Best
Hendrik
--
Hendrik Tilger
EDV
Max-Planck-Institut für chemische Ökologie
Beutenberg Campus
Hans-Knöll-Strasse 8
D-07743 Jena
T: +49 3641 572303 | +49 151 29158322
https://www.ice.mpg.de | https://www.mpg.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2812 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://shibboleth.net/pipermail/users/attachments/20250306/2b02593c/attachment.p7s>
More information about the users
mailing list