cgicc: Overview of the Common Gateway Interface https://www.gnu.org/software/cgicc/doc/cgi_overview.html

Overview of the Common Gateway Interface

What is the Common Gateway Interface?

The Common Gateway Interface (CGI) is a standard for external gateway programs to interface with information servers, such as HTTP servers. The official specification for the Common Gateway Interface may be found at http://hoohoo.ncsa.uiuc.edu/cgi/interface.html

CGI scripts or CGI applications?

Historically, many CGI applications were written in scripting languages such as Perl. Not surprisingly, CGI code called by the HTTP server was referred to as a CGI script. As the popularity of the web grew and the need for dynamic content increased, CGI applications written in languages other than Perl became more and more popular. These applications were referred to simply as scripts. Although the term script does not make intuitive sense for a compiled program, the term has stuck. In this manual, the terms script and application are used interchangeably.

CGI Processing

When an HTTP server receives a request for a CGI script, the server communicates to the script the details of the request. The HTTP server and a CGI script communicate in four major ways:

  1. Environment variables The HTTP server uses environment variables to pass information about the request to the CGI script. Depending on the type of request, the environment variables may or may not contain all the information required by the script to function properly.
  2. The command line The command line is only used for isindex queries. Generally, isindex queries should not be used; since the command line is used directly, they present many potential security risks.
  3. Standard input For HTTP POST or PUT queries, the HTTP server communicates information to the CGI script via standard input. The amount of information written to standard input is stored in the CONTENT_LENGTH environment variable.
  4. Standard output A script returns its output on standard output. The output can be a document generated by the script, or instructions to the server for retrieving the desired output.

GNU cgicc - A C++ class library for writing CGI applications
Copyright © 1996 - 2004 Stephen F. Booth
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front Cover Texts, and with no Back-Cover Texts.
Documentation generated Sat Jan 19 21:15:59 2008 for cgicc by doxygen 1.5.1
 
 
 

When an HTTP server receives a request for a CGI script的更多相关文章

  1. Server.MapPath和Request.PhysicalApplicationPath的异同

    很多人对它们都不陌生,在众多的WEB程序中,使用Server.MapPath和Request.PhysicalApplicationPath来操作目录/文件的几率参半,我曾经也经常混用,然而时间久了. ...

  2. [DeploymentService:290066]Error occurred while downloading files from admin server for deployment request "0". Underlying error is: "null"

    weblogic 莫名无法启动: <Apr , :: PM CST> <Error> <Deployer> <BEA-> <Failed to i ...

  3. Home Web Server 1.9.1 build 164 - CGI Remote Code Execution复现

    一.  Home Web Server 1.9.1 build 164 - CGI Remote Code Execution复现 漏洞描述: Home Web Server允许调用CGI程序来通过P ...

  4. HTTP Server to Client Communication

    1. Client browser short polling The most simple solution, client use Ajax to sends a request to the ...

  5. http2协议翻译(转)

    超文本传输协议版本 2 IETF HTTP2草案(draft-ietf-httpbis-http2-13) 摘要 本规范描述了一种优化的超文本传输协议(HTTP).HTTP/2通过引进报头字段压缩以及 ...

  6. zmq 学习笔记

    0. PUB/SUB, XPUB/XSUB filtering happens at publisher sides when sockets are using a connected protoc ...

  7. Raft

    http://thesecretlivesofdata.com/raft/ https://github.com/coreos/etcd   1 Introduction Consensus algo ...

  8. RFC 2616

    Network Working Group R. Fielding Request for Comments: 2616 UC Irvine Obsoletes: 2068 J. Gettys Cat ...

  9. MDN > Web technology for developers > HTTP

    The Hypertext Transfer Protocol (HTTP) is an application-layer protocol for transmitting hypermedia ...

随机推荐

  1. mysql操作索引的sql语句

    创建索引 一:唯一索引alter table table_name add unique index_name(column_list); 例如:alter table users_game_task ...

  2. Redis(三):windows下Redis的安装配置以及注意事项

    一.下载windows版本的Redis 去官网找了很久,发现原来在官网上可以下载的windows版本的,现在官网以及没有下载地址,只能在github上下载,官网只提供linux版本的下载 官网下载地址 ...

  3. Excel累加上一行的数值

    默认一拖是每一行+1,现在想加任意: =A1+X 然后一拖就可以加X了.

  4. 筛选git最后一次文件列表

    需要写一个小程序,列出出最后一次git提交的文件列表 命令如下: git log -1 --name-only 操作后,发现并不能完整的显示文件列表,查询google后,发现是git默认配置只显示90 ...

  5. codeForces 574b Bear and Three Musketeers

    一种巧妙到暴力方式,这题到抽象化:在一个无向图中,找一个度数和最小到三阶到圈. 首先对边进行枚举,这样确定了两个顶点,然后在对点进行枚举,找到一个可以构成三元圈到点,则计算他们到度数和. 最后保存最小 ...

  6. ECMall 中URL体系的改造思路

    EC系列的产品都已停止更新很久了,但其对中国中小电商企业的影响无疑是巨大的.很多公司,都是直接拿来即改,改了即用. 但他们都有个问题,代码是比较传统的开发模式过来的,尤其ecshop.ECMall系统 ...

  7. 【Mac + Appium + Python3.6学习(四)】之常用的IOS自动化测试API总结

    环境: Appium:1.9.1 Appium-desktop:1.7.1 Xcode:10.0 IOS:iPhone5S(10.3.3) Mac:10.13.6 ①获取手机屏幕size:长.宽 &l ...

  8. jquery datagrid设置pageSize不起作用

    http://www.2cto.com/kf/201212/178098.html —————————————————————————————————————————————————————————— ...

  9. Jetty修改默认端口

    1.webserver: Jetty2.version:   7.6.5, 8.1.53.operation: 修改默认端口3.1 修改Jetty目录下的/etc/jetty.xml 文件中的[por ...

  10. 第一百六十一节,封装库--JavaScript,完整封装库文件

    封装库--JavaScript,完整封装库文件 /** *feng_zhuang_ku_1.0版本,js封装库,2016/12/29日:林贵秀 **/ /** 前台调用 * 每次调用$()创建库对象, ...