getInboundMessageTransport always returns a null value

Mark McCoy Mark.McCoy at
Tue May 26 11:49:28 EDT 2015

We are trying to add a check on the user’s IP address to determine whether or not the user is coming from on or off campus.

IdP version: 2.4.4
Tomcat: 6.0.24
Java: OpenJDK
OS: RHEL 6.6

In a scripted attribute, I’ve tried to use the following calls to get the user’s IP address. Every call results in the getInboundMessageTransport() returning a null value, which obviously causes the getPeerAddress() call to fail. Other calls to methods contained within the requestContext succeed (example, the getEntityId() call works fine).

try {
   var ipAddress = requestContext.getInboundMessageTransport().getPeerAddress();
} catch (err) {
   var ipAddress = 'unavailable'
   logger.warn(pre + err);
logger.debug(pre + "ipAddress = " + ipAddress);

The idp-process.log entries look like this:
2015-05-26 10:34:48.817 - WARN [edu.internet2.middleware.shibboleth.resolver.Script.validAuthContexts:-2] - TypeError: Cannot call method "getPeerAddress" of null
2015-05-26 10:34:48.817 - DEBUG [edu.internet2.middleware.shibboleth.resolver.Script.validAuthContexts:-1] - ipAddress = unavailable

Any suggestions?


Mark McCoy
Identity Management
The University of Texas at San Antonio

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the users mailing list