ELinks 0.18.0
cgi.c File Reference
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include <sys/stat.h>
#include "elinks.h"
#include "config/options.h"
#include "cookies/cookies.h"
#include "intl/libintl.h"
#include "mime/backend/common.h"
#include "network/connection.h"
#include "network/progress.h"
#include "network/socket.h"
#include "osdep/osdep.h"
#include "osdep/sysname.h"
#include "osdep/types.h"
#include "protocol/common.h"
#include "protocol/file/cgi.h"
#include "protocol/http/http.h"
#include "protocol/uri.h"
#include "terminal/terminal.h"
#include "util/conv.h"
#include "util/env.h"
#include "util/string.h"
Include dependency graph for cgi.c:

Macros

#define POST_BUFFER_SIZE   32768
 

Functions

static void close_pipe_and_read (struct socket *data_socket)
 
static void send_more_post_data (struct socket *socket)
 
static void send_post_data (struct connection *conn)
 
static void send_request (struct connection *conn)
 
static int set_vars (struct connection *conn, char *script)
 
static int test_path (char *path)
 
int execute_cgi (struct connection *conn)
 

Variables

static union option_info cgi_options []
 
struct module cgi_protocol_module
 

Macro Definition Documentation

◆ POST_BUFFER_SIZE

#define POST_BUFFER_SIZE   32768

Function Documentation

◆ close_pipe_and_read()

static void close_pipe_and_read ( struct socket * data_socket)
static

◆ execute_cgi()

int execute_cgi ( struct connection * conn)

◆ send_more_post_data()

static void send_more_post_data ( struct socket * socket)
static

◆ send_post_data()

static void send_post_data ( struct connection * conn)
static

◆ send_request()

static void send_request ( struct connection * conn)
static

◆ set_vars()

static int set_vars ( struct connection * conn,
char * script )
static

◆ test_path()

static int test_path ( char * path)
static

Variable Documentation

◆ cgi_options

union option_info cgi_options[]
static
Initial value:
= {
INIT_OPT_TREE("protocol.file", N_("Local CGI"),
"cgi", OPT_ZERO,
N_("Local CGI specific options.")),
INIT_OPT_STRING("protocol.file.cgi", N_("Path"),
"path", OPT_ZERO, "",
N_("Colon separated list of directories, "
"where CGI scripts are stored.")),
INIT_OPT_BOOL("protocol.file.cgi", N_("Allow local CGI"),
"policy", OPT_ZERO, 0,
N_("Whether to execute local CGI scripts.")),
NULL_OPTION_INFO,
}
@ OPT_ZERO
Definition options.h:23
#define N_(msg)
Definition libintl.h:25

◆ cgi_protocol_module

struct module cgi_protocol_module
Initial value:
N_("CGI"),
)
static union option_info cgi_options[]
Definition cgi.c:43
#define NULL
Definition explodename.c:35
#define struct_module(name, options, hooks, submods, data, init, done, getname)
Definition module.h:47