There is no safe way to get it, but basically you can interpret the request headers as described here: https://stackoverflow.com/questions/16558869/getting-ip-address-of-client
To get access to this API you just need to cast the the IRequest instance up:
(HttpServletRequest)Ivy.request()).getHttpServletRequest()
IRequest request = Ivy.request();
if (request instanceof IHttpRequest)
{
HttpServletRequest tomcatRequest = (IHttpRequest)Ivy.request()).getHttpServletRequest();
// do header analysis...
}