private String getRemoteIp(final RequestContext context) {
        val request = WebUtils.getHttpServletRequestFromExternalWebflowContext(context);
        var userAddress = request.getRemoteAddr();
        LOGGER.debug("Remote Address = [{}]", userAddress);
        if (StringUtils.isNotBlank(this.alternativeRemoteHostAttribute)) {
            userAddress = request.getHeader(this.alternativeRemoteHostAttribute);
            LOGGER.debug("Header Attribute [{}] = [{}]", this.alternativeRemoteHostAttribute, userAddress);
            if (StringUtils.isBlank(userAddress)) {
                userAddress = request.getRemoteAddr();
                LOGGER.warn("No value could be retrieved from the header [{}]. Falling back to [{}].", this.alternativeRemoteHostAttribute, userAddress);
            }
        }
        return userAddress;
    }
Pulls the remote IP from the current HttpServletRequest, or grabs the value
for the specified alternative attribute (say, for proxied requests).  Falls
back to providing the "normal" remote address if no value can be retrieved
from the specified alternative header value.

@param context the context
@return the remote ip
support/cas-server-support-spnego-webflow/src/main/java/org/apereo/cas/web/flow/client/BaseSpnegoKnownClientSystemsFilterAction.java