mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-28 12:30:58 +00:00
Mongoose forwarding
PUBLISHED_FROM=51652f0157bb951a43508f0fe948c62c351e96ba
This commit is contained in:
1 parent
f5a2857620
commit
900bbe724a
8 files changed
+327
-35
No files matched your search
@@ -8,6 +8,7 @@ items:
|
||||
- { name: mg_get_http_var.md }
|
||||
- { name: mg_http_check_digest_auth.md }
|
||||
- { name: mg_http_parse_header.md }
|
||||
- { name: mg_http_send_error.md }
|
||||
- { name: mg_http_send_redirect.md }
|
||||
- { name: mg_http_serve_file.md }
|
||||
- { name: mg_parse_http.md }
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
---
|
||||
title: "mg_http_send_error()"
|
||||
decl_name: "mg_http_send_error"
|
||||
symbol_kind: "func"
|
||||
signature: |
|
||||
void mg_http_send_error(struct mg_connection *nc, int code, const char *reason);
|
||||
---
|
||||
|
||||
Sends an error response. If reason is NULL, the message will be inferred
|
||||
from the error code (if supported).
|
||||
|
||||
@@ -100,16 +100,19 @@ signature: |
|
||||
/* IP ACL. By default, NULL, meaning all IPs are allowed to connect */
|
||||
const char *ip_acl;
|
||||
|
||||
#if MG_ENABLE_HTTP_URL_REWRITES
|
||||
/* URL rewrites.
|
||||
*
|
||||
* Comma-separated list of `uri_pattern=file_or_directory_path` rewrites.
|
||||
* Comma-separated list of `uri_pattern=url_file_or_directory_path` rewrites.
|
||||
* When HTTP request is received, Mongoose constructs a file name from the
|
||||
* requested URI by combining `document_root` and the URI. However, if the
|
||||
* rewrite option is used and `uri_pattern` matches requested URI, then
|
||||
* `document_root` is ignored. Instead, `file_or_directory_path` is used,
|
||||
* `document_root` is ignored. Instead, `url_file_or_directory_path` is used,
|
||||
* which should be a full path name or a path relative to the web server's
|
||||
* current working directory. Note that `uri_pattern`, as all Mongoose
|
||||
* patterns, is a prefix pattern.
|
||||
* current working directory. It can also be an URI (http:// or https://)
|
||||
* in which case mongoose will behave as a reverse proxy for that destination.
|
||||
*
|
||||
* Note that `uri_pattern`, as all Mongoose patterns, is a prefix pattern.
|
||||
*
|
||||
* If uri_pattern starts with `@` symbol, then Mongoose compares it with the
|
||||
* HOST header of the request. If they are equal, Mongoose sets document root
|
||||
@@ -123,6 +126,7 @@ signature: |
|
||||
* automatically appended to the redirect location.
|
||||
*/
|
||||
const char *url_rewrites;
|
||||
#endif
|
||||
|
||||
/* DAV document root. If NULL, DAV requests are going to fail. */
|
||||
const char *dav_document_root;
|
||||
|
||||
Reference in new issue
Block a user