-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathREADME
More file actions
20 lines (15 loc) · 819 Bytes
/
Copy pathREADME
File metadata and controls
20 lines (15 loc) · 819 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
TCPSERV:
This Program is built to recieve TCP/IP connection and pass the outcome to a function like so:
# int func(std::pair<int, std::string>, std::string&)
This function shall return:
0: keep the connection alive
N: keep the connection alive and expect to receive N bytes from the same socket
-1: close the connection
-N: ignore the following N bytes from that socket (still to think it trough)
Every socket operation will be non-blocking.
The maximum number of simultaneous connections should be set accordingly to the RLIMIT_NOFILE limit
Other incominng coonnections will be accept()ed and closed.
SeedHTTP
This class is designed to receive an HTTP request and return an HTTP response
based on the kiwi.conf file. If the file is missing goes with the default:
https://www.rfc-editor.org/rfc/rfc9110.html