diff options
Diffstat (limited to 'src/server.h')
-rw-r--r-- | src/server.h | 86 |
1 files changed, 0 insertions, 86 deletions
diff --git a/src/server.h b/src/server.h deleted file mode 100644 index be1abf8d..00000000 --- a/src/server.h +++ /dev/null | |||
@@ -1,86 +0,0 @@ | |||
1 | /* Copyrights 2002 Luis Figueiredo (stdio@netc.pt) All rights reserved. | ||
2 | * | ||
3 | * See the LICENSE file | ||
4 | * | ||
5 | * The origin of this software must not be misrepresented, either by | ||
6 | * explicit claim or by omission. Since few users ever read sources, | ||
7 | * credits must appear in the documentation. | ||
8 | * | ||
9 | * date: Sat Mar 30 14:44:42 GMT 2002 | ||
10 | * | ||
11 | * | ||
12 | * -- | ||
13 | * | ||
14 | */ | ||
15 | |||
16 | #ifndef _SERVER_H_ | ||
17 | #define _SERVER_H_ | ||
18 | |||
19 | #ifdef HAVE_CONFIG_H | ||
20 | #include "config.h" | ||
21 | #endif | ||
22 | |||
23 | #include <stdio.h> | ||
24 | #include <signal.h> | ||
25 | #include <time.h> | ||
26 | |||
27 | |||
28 | #include "memory.h" | ||
29 | #include "client.h" | ||
30 | #include "gethandler.h" | ||
31 | #include "socket.h" | ||
32 | #include "error.h" | ||
33 | |||
34 | #include "debug.h" | ||
35 | |||
36 | #ifdef WIN32 | ||
37 | |||
38 | #define SHUT_RDWR SD_BOTH | ||
39 | #endif | ||
40 | |||
41 | |||
42 | |||
43 | |||
44 | extern char *_libwebserver_version; | ||
45 | extern struct web_server *current_web_server; | ||
46 | struct web_server { | ||
47 | int socket; | ||
48 | unsigned int port; | ||
49 | char *logfile; | ||
50 | char *conffile; | ||
51 | time_t conffiletime; // tested only on win | ||
52 | char *mimefile; | ||
53 | char *dataconf; | ||
54 | FILE *weblog; | ||
55 | int flags; | ||
56 | struct gethandler *gethandler; | ||
57 | struct web_client *client; | ||
58 | int usessl; | ||
59 | #ifdef HAVE_OPENSSL | ||
60 | char *cert_file; | ||
61 | SSL_CTX *ctx; | ||
62 | #else | ||
63 | void *pad[2]; | ||
64 | #endif | ||
65 | |||
66 | }; | ||
67 | #define WS_LOCAL 1 // Can be only accessed by localhost | ||
68 | #define WS_USESSL 2 // Use ssl conections (openssl lib required) | ||
69 | #define WS_USEEXTCONF 4 // Use external config file (new 0.5.0) | ||
70 | |||
71 | |||
72 | void web_server_useSSLcert(struct web_server *,const char *); // Mandatory if WS_USESSL set | ||
73 | void web_server_useMIMEfile(struct web_server*,const char *); // new on 0.5.2 | ||
74 | int web_server_init(struct web_server *,int,const char *,int); | ||
75 | void web_server_shutdown(struct web_server *); | ||
76 | int web_server_addhandler(struct web_server *,const char *,void (*)(),int); | ||
77 | int web_server_aliasdir(struct web_server *, const char *, char *,int ); | ||
78 | int web_server_run(struct web_server *); | ||
79 | int web_server_setup(struct web_server *server,const char *conffile); // (new on 0.5.0) | ||
80 | char *web_server_getconf(struct web_server *, const char *,const char *); // (new on 0.5.0) | ||
81 | |||
82 | |||
83 | #include "weblog.h" | ||
84 | |||
85 | #endif | ||
86 | |||