1
Fork 0
Commit graph

10 commits

Author SHA1 Message Date
Jan-Erik Rediger 53a13840bd Add Host header into target uri
Previously this would lead to an abort for an empty path (`/`), because
`http:/` cannot be parsed correctly.
The URI becomes the `target` in `request`, so it seems best to add the
`Host` header value too.

Note that this is still not 100% correct:
HTTP headers are case-insensitive, so it could also be `host:` or `HoSt`.
Right now headers are not normalized.
However it will not abort if `Host` is missing:
In that case `header_get` returns an empty string and then `http:///`
(three slashes) is parsed with an empty host name as expected.
2024-05-27 22:49:41 +02:00
Drew DeVault 9237448725 Updates for Hare upstream changes
Signed-off-by: Drew DeVault <sir@cmpwn.com>
2024-04-19 11:24:02 +02:00
Willow Barraco 1d5c710f55 Implement server-side HTTP support
Co-authored-by: Drew DeVault <sir@cmpwn.com>
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
Signed-off-by: Drew DeVault <sir@cmpwn.com>
2024-04-19 11:22:15 +02:00
Drew DeVault 2acf7fa873 net::http: export new_request{,_body} 2023-10-08 11:14:26 +02:00
Drew DeVault c63af5d3ec Improve documentation and transport semantics 2023-02-12 13:05:11 +01:00
Drew DeVault 5e205199dc Fish transport config through various types 2023-02-12 12:55:16 +01:00
Drew DeVault 26b21689b5 (Partially) implement net::http::do 2023-02-10 10:13:30 +01:00
Drew DeVault 4bb0cd5c7e Add client struct and request helpers 2023-02-09 23:23:05 +01:00
Drew DeVault a0bfaef6ba Initial commit 2023-02-09 20:56:48 +01:00
Drew DeVault ea1a5ceb8d Initial commit 2023-02-09 11:45:25 +01:00