-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathLibrary.hpp
56 lines (52 loc) · 1.56 KB
/
Library.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#ifndef LIBRARY_HPP
# define LIBRARY_HPP
# include <sys/socket.h>
# include <sys/wait.h>
# include <unistd.h>
# include <stdlib.h>
# include <netinet/in.h>
# include <iostream>
# include <stdio.h>
# include <string.h>
# include <sys/types.h>
# include <netdb.h>
# include <fcntl.h>
# include <poll.h>
# include <vector>
# include <list>
# include <string>
# include <sstream>
# include <fstream>
# include <map>
# include <cstdio>
# include <cstring>
# include <arpa/inet.h>
# include <algorithm>
# include <csignal>
# include <ctime>
# include <iomanip>
# include "Location.hpp"
# include "ServerPairs.hpp"
# include "ConfigTokens.hpp"
# include "CGI.hpp"
# include "Parser.hpp"
# include "Response.hpp"
# include "Request.hpp"
# include "Http.hpp"
# include "Server.hpp"
# include "Core.hpp"
# define BUFSIZE 1024
# define PORT 8080
# define ADDRESS INADDR_ANY
# define DEFAULT_CONFIG "configs/default.conf"
# define EXTENSION ".conf"
# define PATH_PY "/usr/local/bin/python3"
# define PATH_SH "/bin/bash"
# define REQUEST_METHOD "" //The method used to make the request. The most common methods are GET and POST.
# define QUERY_STRING "" // The URL-encoded information that is sent with GET method request.
# define CONTENT_TYPE "" // The data type of the content. Used when the client is sending attached content to the server. For example, file upload.
# define CONTENT_LENGTH "" // The length of the query information. It is available only for POST requests.
# define HTTP_COOKIE "" // Returns the set cookies in the form of key & value pair.
# define COUNT_CMD 3
# define COUNT_ENV 7
#endif