Clean the HTTP connection state when ia request/response has been fully
buffered and handler invoked.
Fixes https://github.com/cesanta/mongoose/issues/971
CL: mg: Fix handling of keepalive HTTP requests/responses
PUBLISHED_FROM=70c854aa306aacb9161f6ee48841f38dc0312e6b
Do not clear buffer at the end of multipart request to allow following request to proceed.
Closes https://github.com/cesanta/mongoose/pull/940
CL: mg: Fix pipelining issue with multipart upload
PUBLISHED_FROM=cc7d38b126eaa863553ee4e124cfafcd72030fcf
curl -F file1 -F file2 ...
Add a unit test and fix a minor memory leak when returning an error.
CL: mg_file_upload_handler: Support multiple files
PUBLISHED_FROM=5c4bf2be676346fb782e80f50f79df6a6721ac88
Per standard, cookies are delimited by `; `.
CL: Fix mg_http_parse_header: treat ";" as a delimiter.
PUBLISHED_FROM=039243c30f5fabf4a4700a43506f841b3268306a
A major cleanup, disentangling net_if and ssl_if.
Pulled a lot of common logic into the core and reduced size of net_if implementations.
CL: Mongoose net_if and ssl_if refactoring
PUBLISHED_FROM=29bd4dcb264a1fd96b3dd164e2d880e1c2c0921e
E.g. if `ASSERT_EQ(myfunc(), 123)` fails, `myfunc()` would be invoked again to print the actual value.
This can cause confusion sometimes.
To avoid this, we cast arguments to double, which is wide enough for most cases and we provide a variant for 64 bit value types for when it's not.
We also perform a check and fail if argument to the check results in loss of precision.
CL: none
PUBLISHED_FROM=a14551289d92e8a5dead21d16471ebddebe938a8
Which is a replacement of (deprecated) `mg_http_parse_header`, but,
similarly to `asprintf`, allocates a new buffer if the client-provided
one is not large enough.
Also use it throughout mongoose code, and thus some header-related
limitations are removed; in particular,
https://github.com/cesanta/mongoose/issues/813 is fixed.
CL: Mongoose Web Server: Deprecate `mg_http_parse_header()` and implement `mg_http_parse_header2()` instead, which allocates a new buffer if the client-provided one is not large enough (similarly to `asprintf`).
CL: Mongoose Web Server: Fix limitations of header value lengths, e.g. when parsing authentication headers such as nonce, etc.
PUBLISHED_FROM=c75b1bbbbdb294ea85075ce69b1368f115fdd1ef
If the uri is something like '/js/...jquery.js', remove_double_dots_and_double_slashes will remove the 3 dots and the http server will serves the /js/jquery.js file.
remove_double_dots_and_double_slashes should check if a dot or double dots is followed by a slash (or backslash) and only remove this to avoid disclosure attack.