zephyr/subsys/net/lib/http
Michael Scott e04a5412a1 net: http: client: remove payload send_chunk logic
Logic for sending chunks of data is incompatible with adding
Content-Length: header.

Per https://tools.ietf.org/html/rfc7230#section-3.3.1:
"A sender MUST NOT send a Content-Length header field in any
message that contains a Transfer-Encoding header field."

Going a bit further in my mind: also don't send Transfer-Encoded
chunked data either when the Content-Length header is present.

In general, there will be problems if the http client library
makes payload changes without the user code knowing about it.

This patch removes the use of http_send_chunk() from the new
HTTP client code and instead sends the payload directly to
http_prepare_and_send()

This fixes an issue where every available buffer would be allocated
with repeating payload data because the for loop in http_request()
wasn't ending until we ran out of memory.

Signed-off-by: Michael Scott <michael@opensourcefoundries.com>
2017-11-14 09:52:59 +02:00
..
CMakeLists.txt Introduce cmake-based rewrite of KBuild 2017-11-08 20:00:22 -05:00
Kconfig net: http: Create HTTP library that uses net-app 2017-11-06 09:33:00 -05:00
README_http_parser net: lib: http: split out URL parsing as a separate CONFIG 2017-10-17 08:08:16 -04:00
http_app.c net: http: Create HTTP library that uses net-app 2017-11-06 09:33:00 -05:00
http_app_client.c net: http: client: remove payload send_chunk logic 2017-11-14 09:52:59 +02:00
http_app_server.c net: http: Add error status string to HTTP server error 2017-11-14 09:52:46 +02:00
http_client.c net: lib: http: fix check for invalid body_start pointer 2017-10-27 17:42:01 -04:00
http_parser.c net: lib: http: split out URL parsing as a separate CONFIG 2017-10-17 08:08:16 -04:00
http_parser_url.c net: lib: http: split out URL parsing as a separate CONFIG 2017-10-17 08:08:16 -04:00
http_server.c net: http: Check that we could install recv_cb in accept 2017-10-27 15:35:59 +03:00