Go to the source code of this file.
Defines | |
#define | HOST 1 |
#define | WRAPPER 2 |
#define | INETADDR 3 |
Functions | |
void | start_httpd (int port, int backlog, char *bindAddr) |
Start the HTTPD server. | |
void | stop_httpd () |
Stop the HTTPD server. | |
int | add_host_allow (char *name) |
Add hosts allowed to connect to this server. | |
int | has_hosts_allow () |
Are any hosts present in the host allow list? | |
void | destroy_hosts_allow () |
Free the host allow list. | |
Variables | |
ssl_server_connection * | mySSLServerConnection = NULL |
The server delegates handling of a HTTP request and response to the processor module.
NOTE This server does not use threads or forks; Requests are serialized and pending requests will be popped from the connection queue when the current request finish.
Since this server is written for monit, low traffic is expected. Connect from not-authenicated clients will be closed down promptly. The authentication schema or access control is based on client name/address and only requests from known clients are accepted. Hosts allowed to connect to this server should be added to the access control list by calling add_host_allow().
Definition in file engine.c.
|
|
|
|
|
|
|
Add hosts allowed to connect to this server.
Definition at line 230 of file engine.c. References END_LOCK, LOCK, host_allow::name, NEW, host_allow::next, and xstrdup(). |
|
Free the host allow list.
Definition at line 303 of file engine.c. References END_LOCK, has_hosts_allow(), and LOCK. |
|
Are any hosts present in the host allow list?
Definition at line 287 of file engine.c. References END_LOCK, and LOCK. Referenced by can_http(), and destroy_hosts_allow(). |
|
Start the HTTPD server.
Definition at line 111 of file engine.c. References check_socket(), create_server_socket(), destroy_wrapper(), embed_accepted_ssl_socket(), error(), http_processor(), myrun::httpdssl, myrun::httpsslclientpem, myrun::httpsslpem, init_ssl_server(), insert_accepted_ssl_socket(), mySSLServerConnection, Run, requestwrapper::socket, requestwrapper::ssl, requestwrapper::status, and STRERROR. |
|
Stop the HTTPD server.
Definition at line 213 of file engine.c. References close_socket(), delete_ssl_server_socket(), and mySSLServerConnection. Referenced by monit_http(). |
|
Definition at line 62 of file engine.c. Referenced by destroy_wrapper(), start_httpd(), and stop_httpd(). |