docs: public static String getRemoteAddrFromRequest(Request request, Set<IpSubnet> trustedSubnets) {
          final String remoteAddr = request.getRemoteAddr();
          final String XForwardedFor = request.getHeader("X-Forwarded-For");
          if (XForwardedFor != null) {
              for (IpSubnet s : trustedSubnets) {
                  try {
                      if (s.contains(remoteAddr)) {
                          // Request came from trusted source, trust X-Forwarded-For and return it
                          return XForwardedFor;
                      }
                  } catch (UnknownHostException e) {
                      // ignore silently, probably not worth logging
                  }
              }
          }
  
          // Request did not come from a trusted source, or the X-Forwarded-For header was not set
          return remoteAddr;
      }