The Request
type provides accessors for the request method and the request version but not for the bit in between.
So if I have the following request:
GET http://www.example.org/index.html HTTP/1.1
I want the http://www.example.org/index.html
in between
RFC7230 Section 5.3.2 allows for this when making a request to a proxy. Section 5.4 says that the Host
header should be overriden by the proxy with the host in the URI if the request is in absolute-form
. This seems good enough for me, I don't know if WAI would handle this correctly if a client was not behaving correctly and sending a Host header different from the absolute-form
URI.
Alternatively, if this is not possible: I'd like to ask if there is a more low level HTTP library than WAI available in Haskell?