Examples of HmuxRequest


Examples of com.caucho.server.hmux.HmuxRequest

      res.sendError(HttpServletResponse.SC_NOT_FOUND);
      return false;
    }

    HmuxRequest hmuxRequest = (HmuxRequest) request;

    if (!request.getServletPath().equals("")) {
      log.warning(L.l("{0} attempt with invalid servlet-path '{1}' from address '{2}'",
                     _serviceName, request.getServletPath(), request.getRemoteAddr()));

      res.sendError(HttpServletResponse.SC_NOT_FOUND);
      return false;

    }

    if (request.getPathInfo() != null) {
      log.warning(L.l("{0} attempt with invalid path-info '{1}' from address '{2}'",
                      _serviceName, request.getPathInfo(), request.getRemoteAddr()));

      res.sendError(HttpServletResponse.SC_NOT_FOUND);
      return false;

    }

    // The remote test needs to be last to allow the other QA to work properly
    // XXX: this should be configurable, i.e. setReadConstraints and setWriteConstraints

    String remoteAddr = hmuxRequest.getRemoteAddr();

    boolean isValidAddr = false;
    for (int i = 0; i < _allowedNetworks.length; i++) {
      if (_allowedNetworks[i].isMatch(remoteAddr))
        isValidAddr = true;
View Full Code Here

Examples of com.caucho.server.hmux.HmuxRequest

      res.sendError(HttpServletResponse.SC_NOT_FOUND);
      return false;
    }

    HmuxRequest hmuxRequest = (HmuxRequest) request;

    if (!request.getServletPath().equals("")) {
      log.warning(L.l("{0} attempt with invalid servlet-path '{1}' from address '{2}'",
                     _serviceName, request.getServletPath(), request.getRemoteAddr()));

      res.sendError(HttpServletResponse.SC_NOT_FOUND);
      return false;

    }

    if (request.getPathInfo() != null) {
      log.warning(L.l("{0} attempt with invalid path-info '{1}' from address '{2}'",
                      _serviceName, request.getPathInfo(), request.getRemoteAddr()));

      res.sendError(HttpServletResponse.SC_NOT_FOUND);
      return false;

    }

    // The remote test needs to be last to allow the other QA to work properly
    // XXX: this should be configurable, i.e. setReadConstraints and setWriteConstraints

    String remoteAddr = hmuxRequest.getRemoteAddr();

    boolean isValidAddr = false;
    for (int i = 0; i < _allowedNetworks.length; i++) {
      if (_allowedNetworks[i].isMatch(remoteAddr))
        isValidAddr = true;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.