Commit graph

166 commits

Author SHA1 Message Date
eidheim
26215025c8 Fixed deprecated calls 2025-04-03 10:58:13 +02:00
eidheim
88569844ea Improved SSL_R_SHORT_READ check 2022-08-16 10:58:59 +02:00
woe
adbdc6fcda Ignore SSL_R_SHORT_READ 2022-06-16 14:41:04 +02:00
eidheim
bab4b309ca Client: added parsing of host specified with IPv6 address 2021-04-09 14:33:43 +02:00
eidheim
1bb89e1e8e Fixes #317: Make use of ASIO_STANDALONE when using standalone asio in order to compile on older asio versions without boost 2021-03-26 10:11:39 +01:00
eidheim
cc0dc20947 Corrected documentation of Server<HTTPS> constructor 2021-02-17 08:59:25 +01:00
eidheim
14c0e3a3a3 Applied style format 2020-09-16 14:53:02 +02:00
eidheim
5d65a5d89b Fixes another compilation issue: make_steady_timer now returns std::unique_ptr 2020-08-26 11:43:28 +02:00
eidheim
4c57860d7e Fixed compilation issue with standalone Asio: https://gitlab.com/eidheim/Simple-WebSocket-Server/-/issues/151 2020-08-26 11:18:12 +02:00
eidheim
eff3b76aa5 Related to #298: fixed chunk transfer read when only end of chunk remains unread 2020-05-13 13:32:59 +02:00
eidheim
9cdfe80ce6 Corrected boost::asio::streambuf to asio::streambuf 2020-05-13 10:38:03 +02:00
eidheim
a20a729a40 Fixes #298: corrected removal of chunk end when receiving larger chunks 2020-05-13 10:28:27 +02:00
eidheim
d49072a4f1 Fixes #298: corrected chunked transfer read where first bytes in a chunk could be erroneously removed 2020-05-12 15:54:56 +02:00
eidheim
409054e812 Fixes #296: corrected client response parsing when response contained header field Connection: close 2020-04-18 13:07:44 +02:00
eidheim
61990c2aee Fixes #295: set default client port when unable to parse port string 2020-04-17 13:36:57 +02:00
eidheim
ebeafc989e Fixes #293: added workaround for MSVC max bug 2020-04-03 11:10:40 +02:00
eidheim
f4ebb57420 Fixed dangling reference in Client::sync_request mentioned in https://gitlab.com/eidheim/Simple-Web-Server/-/merge_requests/248#note_291088756 2020-02-19 18:04:08 +01:00
eidheim
2b5ae3d0d1 Client: removed duplicate code 2020-02-19 11:58:54 +01:00
eidheim
c6c7d0a6f2 Related to !248: completed synchronous request() fixes 2020-02-19 10:45:05 +01:00
Jens Moeller
49e2bb9261 Support asynchronous requests with internal I/O context 2020-02-18 22:00:02 +00:00
Jens Moeller
571fe8b0ad Use futures in synchronous request() methods 2020-02-18 13:05:43 -06:00
eidheim
1bc0b9a779 Minor fix of streambuf size check in chunked transfer 2020-02-04 11:06:20 +01:00
eidheim
84455ac966 Cleanup of timeout handling: timeouts are no longer reset on partial reads and sends 2020-02-04 10:01:49 +01:00
eidheim
d96ed6f02c Cleanup of content max_size checks 2020-02-04 09:09:12 +01:00
eidheim
02bcd02891 Fixes #289: Client now also attempts to reconnect if writing request to server fails 2020-02-03 11:18:54 +01:00
eidheim
3be67623fa Client: async request handlers are now called multiple times if response content is larger than Config::max_response_streambuf_size. Also improved streambuf to streambuf copy, and streambuf to string copy. Finally, string() functions no longer consume streambuf. 2020-02-01 17:11:09 +01:00
eidheim
5544612a19 Cleanup of chunked transfer: now writes directly to request/response streambuf 2020-01-14 12:44:26 +01:00
eidheim
f59906cc90 Removed pop_back that could lead to undefined behaviour 2020-01-14 09:46:12 +01:00
eidheim
ed46b43fa7 Improved comments on public functions and variables as suggested in https://github.com/openjournals/joss-reviews/issues/1592#issuecomment-514946444 2019-07-26 09:28:20 +02:00
eidheim
6185e89e25 Fixes #270 : compilation error when using gcc4.8 2019-07-10 18:02:40 +02:00
eidheim
66b6be499d Client now supports event streams with \r\n line endings in addition to regular \n 2019-07-10 15:08:24 +02:00
eidheim
7c44f73ec5 Fixes #269 : Replaced ssize_t with std::streamsize 2019-07-03 20:28:58 +02:00
eidheim
fc43fc362d Cleanup of include guards 2019-06-25 11:56:21 +02:00
eidheim
a743915d72 Made use of clang's Thread Safety Analysis 2019-06-25 11:29:36 +02:00
eidheim
39fb720aa9 Minor fix of HeaderEndMatch 2019-06-25 08:50:40 +02:00
eidheim
d9d554b1b5 Client: added support for non-standard line endings in response status and header 2019-06-24 19:48:11 +02:00
eidheim
31e6819b42 Added SimpleWeb::error, and simplified request size checks on server 2019-06-23 20:27:54 +02:00
eidheim
b1d9476ff1 Client: added support for server-sent events, and improved the chunked transfer code. Also some cleanup of especially the client code, and added a few additional tests. 2019-06-23 12:41:32 +02:00
eidheim
6097d86cb5 Another fix related to #246 : correctly removed connection from connections list when connection should be closed 2019-06-21 19:27:49 +02:00
eidheim
dbd2287418 Further fix of #246 : corrected use of response streambuf after reconnect (wrong response object was used in Session::callback). Also closes connection when appropriate, and simplified Session::callback. 2019-06-21 19:08:43 +02:00
eidheim
a316310815 Fixes #246 : client's response object is now reset when attempting to resend request on read error 2019-06-21 14:52:17 +02:00
eidheim
514a135e0c Improved set_timeout(): no longer keeps connection alive longer than necessary. 2019-05-27 21:13:28 +02:00
eidheim
1b5f062678 New asio: removed use of strand, and fixed steady_timer constructor call 2019-05-22 14:00:06 +02:00
eidheim
44c2f733dc New asio api: removed unnecessary SimpleWeb::timer_expires_after 2019-05-20 18:39:54 +02:00
eidheim
5087f5d3df Added support for new asio api 2019-04-10 11:07:33 +02:00
eidheim
c14705c62b Replaced unique_lock with lock_guard where possible 2019-03-08 12:54:56 +01:00
eidheim
b8de3ae504 Removed unnecessary check 2018-08-01 09:24:12 +02:00
eidheim
f39f21b56f Minor cleanups 2018-07-29 22:27:10 +02:00
eidheim
56b1df1ee5 Moved SimpleWeb::string_view to utility.hpp, and made use of string_view in Server::Response::write 2018-07-12 08:43:07 +02:00
eidheim
ebe170b4b3 Minor parameter rename, added underscore at end due to move 2018-07-10 17:42:48 +02:00