当前位置: 首页 > 图文教程 > 操作系统 > Unix/Linux > Apache API note(2)

Unix/Linux
suckit后门程序的分析 (二)
Oracle 数据库之克隆方法 (for Redhat Linux7.2,原创)
如何恢复引导菜单
RedHat Linux AS4 系统设置命令变了
限制同一ID不能两人同时登录
中文化问题(输入法)
中国黑客给黑客正名:黑客的本职是维护网络环境 (哈哈笑死我了)
更改GUI的刷新率问题
Linux 之父改用苹果电脑 工作因素?有便宜捡?
使用vnc远程控制linux桌面
我的debian安装以及汉化过程
剖析Linux系统启动过程(1)
剖析Linux系统启动过程(2)
剖析Linux系统启动过程(3)
剖析Linux系统启动过程(4)
剖析Linux系统启动过程(5)
设置apache目录访问身份验证(目录访问控制)
开放源码授权协议GPL何去何从
黑客入侵 SCO 网站
Linux Shell(也算是我的shell入门文章吧)

Unix/Linux 中的 Apache API note(2)


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-11-01   浏览: 59 ::
收藏到网摘: n/a

似乎这个blog对于发表文章的字数有限制。当文章比较长时,会出现 the Document no data的错误信息。也许是溢出了吧。下面是继续Apache API note的未完部分。How handlers workThe sole argument to handlers is a request_rec structure. Thisstructure describes a particular request which has been made to theserver, on behalf of a client. In most cases, each connection to theclient generates only one request_rec structure.句柄是如何工作的 。句柄中最核心的参数是一个request_rec的结构。这个结构描述了一个由客户端已经发送发送到服务端的具体请求。在大多数情况下,每个来自客户端的连接只产生一个request_rec结构。A brief tour of the request_recrequest_rec结构的简要介绍The request_rec contains pointers to a resource pool which will becleared when the server is finished handling the request; to structurescontaining per-server and per-connection information, and mostimportantly, information on the request itself.request_rec包括指向一个资源库的一些指针,这个资源库会在服务程序处理完请求后被清理。这个结构包含了每服务器和每连接的信息,最重要的是,包括这个请求本身的信息。
The most important such information is a small set of character stringsdescribing attributes of the object being requested, including its URI,filename, content-type and content-encoding (these being filled in bythe translation and type-check handlers which handle the request,respectively).这些信息中最重要的是一个小的字符串的集合,他们描述了被请求对象的属性,包括它的URI,文件名,内容类型和内容编码(它们在处理请求时,被分别填入翻译和类型检查句柄)。Other commonly used data items are tables giving the MIME headers onthe client's original request, MIME headers to be sent back with theppppresponse (which modules can add to at will), and environmentvariables for any subprocesses which are spawned off in the course ofservicing the request. These tables are manipulated using the table_getand table_set routines.客户端原始请求中其它常用的数据元素,加入MIME头后,做成表格状,MIME头会随着pppresponse(这个模块可以被加入而生效)被返回,并且环境变量任何子进程的环境变量,在服务端处理请求的过程中被激发。这些表格可以使用table_get和table_set例程来处理。