aboutsummaryrefslogtreecommitdiffstats
path: root/src/gun_http.erl
AgeCommit message (Collapse)Author
2019-07-25Fix missing response_end event for HTTP/1.0 body_closeLoïc Hoguin
2019-07-24Add the cancel event for local/remote stream cancellationLoïc Hoguin
2019-07-15Add Websocket frames related eventsLoïc Hoguin
2019-07-13Add ws_upgrade/protocol_changed eventsLoïc Hoguin
And ensure that Websocket triggers all the request/response events.
2019-07-03Add the response_trailers eventLoïc Hoguin
2019-07-03Add the response_start eventLoïc Hoguin
Thought it needed cow_http2_machine changes but everything was available. For HTTP/1.1 it is triggered when receiving data while expecting headers. For HTTP/2 it is triggered after we have received a HEADERS frame for streams in idle state.
2019-07-02Add response_inform/response_headers/response_end eventsLoïc Hoguin
This covers many scenarios but more need to be added.
2019-06-02Add request_start, request_headers and request_end eventsLoïc Hoguin
2019-04-25Fix Websocket upgrade host header when it's an IP addressSergey Tupchiy
2019-04-22Make gun_tls_proxy work for HTTP/2 connectionsLoïc Hoguin
2019-04-19Integrate gun_tls_proxy into gun properLoïc Hoguin
Still need to add ALPN support and to wait before trying to send data on a proxied TLS connection that didn't complete its handshake.
2019-01-09Add function gun:stream_info/2Loïc Hoguin
2019-01-06Fix KilledStreams value for HTTP for connection: close responsesLoïc Hoguin
2019-01-05Fix atom hostnamesLoïc Hoguin
2019-01-05Fix transfer-encoding precedence over content-lengthLoïc Hoguin
2019-01-03Update copyright yearsLoïc Hoguin
2019-01-02Don't send the default port in the host header for HTTP/2Loïc Hoguin
2019-01-02Don't send the default port in the host header for HTTP/1.1Loïc Hoguin
2018-12-31Separate request/4,5,6 into headers/4,5 and request/5,6Loïc Hoguin
This cleaner separation gets rid of the implicit body check that was causing issues for many users. Now the body is either given explicitly or it is expected via future gun:data/3 calls.
2018-12-31Fix stripping stream reference in gun_httpPiotr Bober
An invalid stream reference (the websocket tuple wrapper) was sent in the gun_data message. Also moves autobahn to its own test suite.
2018-12-19Convert the gun process to gen_statemLoïc Hoguin
2018-09-26Don't send keep-alive while waiting for CONNECT responsesLoïc Hoguin
Otherwise this can mess up the underlying protocol we will switch to, like TLS or HTTP/2.
2018-09-26Keep track of the intermediaries the connection go throughLoïc Hoguin
Also augment the CONNECT tests to confirm that the intermediaries are accounted for.
2018-09-20Use ALPN when proxying TLS connections using CONNECTLoïc Hoguin
This fixes HTTP/2 over TLS connections. The protocol destination option has been deprecated in favor of a protocols option.
2018-09-17Add HTTP/1.1 CONNECT supportLoïc Hoguin
Gun can now be used to connect through TCP HTTP/1.1 proxies using all supported protocols. It is also possible to create a tunnel through multiple proxies. Also updates Cowlib to 2.6.0.
2018-06-04Support Unix domain sockets when building host headersSimon Thörnqvist
2018-06-04Update copyright yearsLoïc Hoguin
2018-06-04Remove the dependency on RanchLoïc Hoguin
We instead of two new modules, gun_tcp and gun_tls. They only have 6 functions so far, much less than what Ranch provided before. Also renames ssl to tls where applicable. It's still possible to use the ssl transport option but it's now undocumented.
2018-06-03Rename gun_data and gun_sse to gun_data_h and gun_sse_hLoïc Hoguin
2018-06-03Change messages to gun_upgrade and gun_ws with stream referenceLoïc Hoguin
2018-06-03Reorder the option checksLoïc Hoguin
2018-05-15Allow IP tuple for host #152Seudin Kasumovic
2018-01-21Do not expect a message body for 204, 304 status codes of HTTP/1.1Andrei Nesterov
2018-01-21Fix HTTP/1 cancel #140Peter Hizalev
2017-12-06Don't send transfer-encoding for HTTP/1.0Loïc Hoguin
2017-11-15Fix a potential issue finding end of headers in HTTP/1.1Loïc Hoguin
This is a bit less efficient but necessary in case we start getting the beginning of \r\n\r\n and it cuts just there.
2017-11-15Add preliminary support for trailersLoïc Hoguin
The code is definitely not the best, but as long as it doesn't break anything it should be OK for now.
2017-10-29Add support for informational responsesLoïc Hoguin
2017-08-14Allow an infinity keepalive value1.0.0-pre.4Loïc Hoguin
This disables the keepalive mechanism entirely.
2017-05-01Add transform_header_name http option.Gustaf Sjoberg
2017-05-01Add support for choosing a process to reply toAndrei Nesterov
2017-04-28Add Gun Websocket handlers and protocol supportLoïc Hoguin
This functionality can be used to implement custom protocols on top of Websocket, but may also be used to decode frame contents on the fly if necessary. The default_protocol option defines what module should be used when no protocol was selected. The protocols option is a list of key/value pairs used to select the handler depending on the protocol that the server accepted. The feature is currently experimental.
2017-04-27Add content handlers and built-in SSE supportLoïc Hoguin
Content handlers are a chain of modules implementing callbacks that receive the body of responses and may modify it (for example for decompressing the content) or act upon it (like sending a message to the owner process. The gun_sse content handler module can be used to translate text/event-stream events on the fly and deliver them to the owner process as a {gun_sse...} message. This feature is currently not documented and is only tested against a public server. It requires an up to date Cowlib.
2017-01-02Fix sending of body as iodata() with HTTPLoïc Hoguin
2016-06-28Properly handle HTTP/1.1 HEAD requestsLoïc Hoguin
No response body is expected from now on.
2015-08-17Fix compilation issueLoïc Hoguin
Oops!
2015-08-16Handle 204 responses properlyLoïc Hoguin
Thanks @petrohi for the initial patch.
2015-08-16Include user headers in HTTP/1 requestsLoïc Hoguin
Oops! Thanks everyone who reported/submitted patches.
2015-05-03Add a missing Transfer-Encoding: chunked header in HTTPLoïc Hoguin
When we stream content we need to set this header manually from Gun.
2015-04-12Add a SPDY test and improve a few badstate messagesLoïc Hoguin