Commit Graph
43 Commits
Author SHA1 Message Date
cozis 1ef6187b2d Add simplified client API (http_get, http_put, http_post, http_delete) 2025-11-27 09:50:41 +01:00
cozis 6a9ba6bbf4 Add HTTPS server examples 2025-11-27 09:24:46 +01:00
cozis 73086ca164 Add numbering prefix to examples 2025-11-27 09:09:13 +01:00
cozis 93c989b56f Add virtual hosts example 2025-11-27 09:00:27 +01:00
cozis b87a78a023 Add proxy example (draft) 2025-11-27 00:32:12 +01:00
cozis c4c41653f4 Add error codes 2025-11-26 22:38:37 +01:00
cozis a58dc241ef Rename http_request_builder_set_trace_bytes to *_trace 2025-11-26 21:13:56 +01:00
cozis 0c50cbff33 Separate http_request_builder_url into http_request_builder_method/_target 2025-11-26 21:11:39 +01:00
cozis 5706f12298 If a socket manager finds winsock uninitialized, it will initialize it and remember to deinitialize it at cleanup 2025-11-26 16:30:59 +01:00
cozis bb753ad8ee Add support for HTTPS, Windows, and Linux builds to Makefile 2025-11-26 16:10:52 +01:00
cozis 9f0560fb9e Add http_client_wait_response for client who don't care about calling poll() directly 2025-11-23 23:39:48 +01:00
cozis f6b2c805c6 Fix HTTP request creation and simple client example 2025-11-23 23:27:08 +01:00
cozis 3c0aecb5f0 Bug fixes & cleanups 2025-11-23 23:07:08 +01:00
Claude 737d81f270 Fix compilation errors in cookie_jar branch
This commit fixes multiple compilation errors introduced by the refactoring:

1. Added missing http_client_conn_free() helper function
2. Fixed cookie_jar reference (cookie_jar->count to client->cookie_jar.count)
3. Restored missing HTTP_ClientConn fields: handle, client, and url
4. Fixed undefined 'conn' variable in http_client_get_builder (changed to 'i')
5. Fixed incorrect field reference (entry.domain.len to domain.len)
6. Added missing closing parenthesis in should_send_cookie
7. Removed duplicate 'path' variable declaration
8. Fixed cookie jar access to use builder.client instead of conn->client
9. Fixed byte_queue_write calls to use .ptr and .len instead of HTTP_String structs
10. Fixed missing -> operators in url_to_connect_target
11. Fixed undefined 'url' variable by using conn->url
12. Fixed headers[i].value to set_cookie.value in save_one_cookie
13. Fixed typo: antry to entry
14. Fixed save_one_cookie parameter type (headers[i] instead of headers[i].value)
15. Fixed print_bytes calls to create HTTP_String structs
16. Added logic to store socket handle when connection is established
17. Updated http_client_get_builder signature to return HTTP_RequestBuilder
18. Updated simple_client.c example to match new API
2025-11-23 21:18:09 +00:00
cozis 4ca5b67d8e Add a client example program and move examples to the examples/ folder 2025-11-22 00:13:43 +01:00
cozis 879dc74e34 First version of the refactor 2025-11-21 12:53:03 +01:00
cozis 7be22fed4b Add comment to 060_virtual_hosts_over_https.c about adding entries to /etc/hosts for testing 2025-10-17 12:21:26 +02:00
cozis 17ad7ad383 Add http_match_host and update 060_virtual_hosts_over_https.c 2025-10-17 12:10:35 +02:00
cozis a63e68f969 Add support for Transfer-Encoding 2025-07-28 16:32:31 +02:00
cozis b99c4e9ccb Add beta-quality disclaimer 2025-07-22 12:25:47 +02:00
cozis 25f52444dd Add disclaimer 2025-07-22 12:19:20 +02:00
cozis c134de645b Rename HTTP_ResponseHandle to HTTP_ResponseBuilder 2025-07-21 23:30:32 +02:00
cozis 43627f81ab Initialize global state in the server examples 2025-07-21 22:56:12 +02:00
cozis 73263da2c9 Fix the HTTPS build 2025-07-21 22:42:43 +02:00
cozis 58f8ace725 Add global state initialization functions 2025-07-21 21:37:02 +02:00
cozis a2912b5191 Refactoring for an improved event loop 2025-07-21 20:29:35 +02:00
cozis 5cb3977c3c Fix windows compilation errors 2025-07-21 12:06:23 +02:00
cozis c3bfb86707 Fix compiler errors 2025-07-20 23:53:23 +02:00
cozis 3b196546da Simplify print statements by using HTTP_UNPACK 2025-07-20 21:29:41 +02:00
cozis 1c6c0a75cf Remove compilation artifacts 2025-07-20 21:25:06 +02:00
cozis 3201eac013 Fix compiler errors 2025-07-20 21:19:58 +02:00
cozis f7892beb90 Add http_get, http_post, and the first client example 2025-07-20 19:56:52 +02:00
cozis 51cae898f8 Rewrite 2025-07-20 16:46:08 +02:00
cozis 939b20abf0 Draft of HTTP_Proxy and HTTP_ProxyEngine 2025-05-22 22:26:08 +02:00
cozis af4127bfb7 Add example using the HTTP engine with I/O completion ports 2025-05-13 00:59:24 +02:00
cozis 3def70928f Add blocking server example with engine 2025-05-13 00:04:53 +02:00
cozis 9b0248fb72 Add simple server example 2025-05-12 22:58:43 +02:00
cozis 24736bc780 Full rewrite 2025-05-07 23:57:07 +02:00
cozis 82ef7ee170 Improve testing program 2025-04-24 22:00:30 +02:00
cozis 6f634b8c8c Basic chunk encoding test, draft of an example using the stream API with blocking sockets 2025-04-20 21:16:56 +02:00
cozis 1573d831db First version of chunk encoding 2025-04-20 19:07:16 +02:00
cozis e1dca84a44 Basic test infrastructure 2025-04-20 14:11:52 +02:00
cozis a4aafb1ee8 Improved documentation and fixed bugs 2025-04-19 16:32:45 +02:00