代理服务器配置 [英] proxy server configuration

查看:198
本文介绍了代理服务器配置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我被分配执行(或更高配置)一种HTTP代理服务器。像下面介绍的服务器应支持流程:

I am assigned to implement (or better configure) a kind of http proxy server. The server should support processes like described below:

-A用户打开他的浏览器中的URL具有以下结构:HTTP://:/ RESOURCE_NAME

-A user opens an URL in his browser which has the following structure: http://:/resource_name

-proxy服务器在传入http请求的URL验证资源名并确定是否应转发来自客户端的原始请求的web资源的URL来

-Proxy server validates the resource name in the URL of the incoming http-request and determines the URL of a web-resource it should forward the original request from the client to

-proxy服务器转发原始请求,等待直到从外部Web服务器的应答,和讯息回给用户

-Proxy server forwards the original request, waits until it gets an answer from the external web-server, and posts it back to the user

我的java中工作,但我不希望由我自己来实现代理服务器与插座玩。相反,我想使用Apache HTTP服务器。有谁知道如果能够实现使用Apache HTTP服务器的配置水平这样的任务?如果是这样,怎么样?

I'm working within java, but I wouldn't like to implement a proxy server by myself playing with sockets. Instead I'd like to use an apache http server. Does anybody know if its possible to accomplish such a task on the configuration level using apache http server? If so, how?

感谢您提前为您解答!

推荐答案

您可以在Apache中使用模块mod_proxy的(代理转发您的要求),并mod_rewrite的(到外部URL的URL映射您的应用程序服务器上)做到这一点

You can do this in Apache using the modules mod_proxy (to proxy your requests forward) and mod_rewrite (to map your external URL to the URL on your application server)

http://httpd.apache.org/docs/2.0/mod/ mod_proxy.html

http://httpd.apache.org/docs/current/mod/ mod_rewrite.html

这篇关于代理服务器配置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆