GNU libmicrohttpd  0.9.29
microhttpd.h
Go to the documentation of this file.
1 /*
2  This file is part of libmicrohttpd
3  Copyright (C) 2006-2017 Christian Grothoff (and other contributing authors)
4 
5  This library is free software; you can redistribute it and/or
6  modify it under the terms of the GNU Lesser General Public
7  License as published by the Free Software Foundation; either
8  version 2.1 of the License, or (at your option) any later version.
9 
10  This library is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser General Public
16  License along with this library; if not, write to the Free Software
17  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 */
19 
79 #ifndef MHD_MICROHTTPD_H
80 #define MHD_MICROHTTPD_H
81 
82 #ifdef __cplusplus
83 extern "C"
84 {
85 #if 0 /* keep Emacsens' auto-indent happy */
86 }
87 #endif
88 #endif
89 
90 /* While we generally would like users to use a configure-driven
91  build process which detects which headers are present and
92  hence works on any platform, we use "standard" includes here
93  to build out-of-the-box for beginning users on common systems.
94 
95  If generic headers don't work on your platform, include headers
96  which define 'va_list', 'size_t', 'ssize_t', 'intptr_t',
97  'uint16_t', 'uint32_t', 'uint64_t', 'off_t', 'struct sockaddr',
98  'socklen_t', 'fd_set' and "#define MHD_PLATFORM_H" before
99  including "microhttpd.h". Then the following "standard"
100  includes won't be used (which might be a good idea, especially
101  on platforms where they do not exist).
102  */
103 #ifndef MHD_PLATFORM_H
104 #include <stdarg.h>
105 #include <stdint.h>
106 #include <sys/types.h>
107 #if defined(_WIN32) && !defined(__CYGWIN__)
108 #include <ws2tcpip.h>
109 #if defined(_MSC_FULL_VER) && !defined (_SSIZE_T_DEFINED)
110 #define _SSIZE_T_DEFINED
111 typedef intptr_t ssize_t;
112 #endif /* !_SSIZE_T_DEFINED */
113 #else
114 #include <unistd.h>
115 #include <sys/time.h>
116 #include <sys/socket.h>
117 #endif
118 #endif
119 
120 #if defined(__CYGWIN__) && !defined(_SYS_TYPES_FD_SET)
121 /* Do not define __USE_W32_SOCKETS under Cygwin! */
122 #error Cygwin with winsock fd_set is not supported
123 #endif
124 
129 #define MHD_VERSION 0x00095500
130 
134 #define MHD_YES 1
135 
139 #define MHD_NO 0
140 
144 #define MHD_INVALID_NONCE -1
145 
150 #ifdef UINT64_MAX
151 #define MHD_SIZE_UNKNOWN UINT64_MAX
152 #else
153 #define MHD_SIZE_UNKNOWN ((uint64_t) -1LL)
154 #endif
155 
156 #ifdef SIZE_MAX
157 #define MHD_CONTENT_READER_END_OF_STREAM SIZE_MAX
158 #define MHD_CONTENT_READER_END_WITH_ERROR (SIZE_MAX - 1)
159 #else
160 #define MHD_CONTENT_READER_END_OF_STREAM ((size_t) -1LL)
161 #define MHD_CONTENT_READER_END_WITH_ERROR (((size_t) -1LL) - 1)
162 #endif
163 
164 #ifndef _MHD_EXTERN
165 #if defined(_WIN32) && defined(MHD_W32LIB)
166 #define _MHD_EXTERN extern
167 #elif defined (_WIN32) && defined(MHD_W32DLL)
168 /* Define MHD_W32DLL when using MHD as W32 .DLL to speed up linker a little */
169 #define _MHD_EXTERN __declspec(dllimport)
170 #else
171 #define _MHD_EXTERN extern
172 #endif
173 #endif
174 
175 #ifndef MHD_SOCKET_DEFINED
176 
179 #if !defined(_WIN32) || defined(_SYS_TYPES_FD_SET)
180 #define MHD_POSIX_SOCKETS 1
181 typedef int MHD_socket;
182 #define MHD_INVALID_SOCKET (-1)
183 #else /* !defined(_WIN32) || defined(_SYS_TYPES_FD_SET) */
184 #define MHD_WINSOCK_SOCKETS 1
185 #include <winsock2.h>
186 typedef SOCKET MHD_socket;
187 #define MHD_INVALID_SOCKET (INVALID_SOCKET)
188 #endif /* !defined(_WIN32) || defined(_SYS_TYPES_FD_SET) */
189 #define MHD_SOCKET_DEFINED 1
190 #endif /* MHD_SOCKET_DEFINED */
191 
195 #ifdef MHD_NO_DEPRECATION
196 #define _MHD_DEPR_MACRO(msg)
197 #define _MHD_NO_DEPR_IN_MACRO 1
198 #define _MHD_DEPR_IN_MACRO(msg)
199 #define _MHD_NO_DEPR_FUNC 1
200 #define _MHD_DEPR_FUNC(msg)
201 #endif /* MHD_NO_DEPRECATION */
202 
203 #ifndef _MHD_DEPR_MACRO
204 #if defined(_MSC_FULL_VER) && _MSC_VER+0 >= 1500
205 /* VS 2008 or later */
206 /* Stringify macros */
207 #define _MHD_INSTRMACRO(a) #a
208 #define _MHD_STRMACRO(a) _MHD_INSTRMACRO(a)
209 /* deprecation message */
210 #define _MHD_DEPR_MACRO(msg) __pragma(message(__FILE__ "(" _MHD_STRMACRO(__LINE__)"): warning: " msg))
211 #define _MHD_DEPR_IN_MACRO(msg) _MHD_DEPR_MACRO(msg)
212 #elif defined(__clang__) || defined (__GNUC_PATCHLEVEL__)
213 /* clang or GCC since 3.0 */
214 #define _MHD_GCC_PRAG(x) _Pragma (#x)
215 #if __clang_major__+0 >= 5 || \
216  (!defined(__apple_build_version__) && (__clang_major__+0 > 3 || (__clang_major__+0 == 3 && __clang_minor__ >= 3))) || \
217  __GNUC__+0 > 4 || (__GNUC__+0 == 4 && __GNUC_MINOR__+0 >= 8)
218 /* clang >= 3.3 (or XCode's clang >= 5.0) or
219  GCC >= 4.8 */
220 #define _MHD_DEPR_MACRO(msg) _MHD_GCC_PRAG(GCC warning msg)
221 #define _MHD_DEPR_IN_MACRO(msg) _MHD_DEPR_MACRO(msg)
222 #else /* older clang or GCC */
223 /* clang < 3.3, XCode's clang < 5.0, 3.0 <= GCC < 4.8 */
224 #define _MHD_DEPR_MACRO(msg) _MHD_GCC_PRAG(message msg)
225 #if (__clang_major__+0 > 2 || (__clang_major__+0 == 2 && __clang_minor__ >= 9)) /* FIXME: clang >= 2.9, earlier versions not tested */
226 /* clang handles inline pragmas better than GCC */
227 #define _MHD_DEPR_IN_MACRO(msg) _MHD_DEPR_MACRO(msg)
228 #endif /* clang >= 2.9 */
229 #endif /* older clang or GCC */
230 /* #elif defined(SOMEMACRO) */ /* add compiler-specific macros here if required */
231 #endif /* clang || GCC >= 3.0 */
232 #endif /* !_MHD_DEPR_MACRO */
233 
234 #ifndef _MHD_DEPR_MACRO
235 #define _MHD_DEPR_MACRO(msg)
236 #endif /* !_MHD_DEPR_MACRO */
237 
238 #ifndef _MHD_DEPR_IN_MACRO
239 #define _MHD_NO_DEPR_IN_MACRO 1
240 #define _MHD_DEPR_IN_MACRO(msg)
241 #endif /* !_MHD_DEPR_IN_MACRO */
242 
243 #ifndef _MHD_DEPR_FUNC
244 #if defined(_MSC_FULL_VER) && _MSC_VER+0 >= 1400
245 /* VS 2005 or later */
246 #define _MHD_DEPR_FUNC(msg) __declspec(deprecated(msg))
247 #elif defined(_MSC_FULL_VER) && _MSC_VER+0 >= 1310
248 /* VS .NET 2003 deprecation do not support custom messages */
249 #define _MHD_DEPR_FUNC(msg) __declspec(deprecated)
250 #elif (__GNUC__+0 >= 5) || (defined (__clang__) && \
251  (__clang_major__+0 > 2 || (__clang_major__+0 == 2 && __clang_minor__ >= 9))) /* FIXME: earlier versions not tested */
252 /* GCC >= 5.0 or clang >= 2.9 */
253 #define _MHD_DEPR_FUNC(msg) __attribute__((deprecated(msg)))
254 #elif defined (__clang__) || __GNUC__+0 > 3 || (__GNUC__+0 == 3 && __GNUC_MINOR__+0 >= 1)
255 /* 3.1 <= GCC < 5.0 or clang < 2.9 */
256 /* old GCC-style deprecation do not support custom messages */
257 #define _MHD_DEPR_FUNC(msg) __attribute__((__deprecated__))
258 /* #elif defined(SOMEMACRO) */ /* add compiler-specific macros here if required */
259 #endif /* clang < 2.9 || GCC >= 3.1 */
260 #endif /* !_MHD_DEPR_FUNC */
261 
262 #ifndef _MHD_DEPR_FUNC
263 #define _MHD_NO_DEPR_FUNC 1
264 #define _MHD_DEPR_FUNC(msg)
265 #endif /* !_MHD_DEPR_FUNC */
266 
272 #ifndef MHD_LONG_LONG
273 
276 #define MHD_LONG_LONG long long
277 #define MHD_UNSIGNED_LONG_LONG unsigned long long
278 #else /* MHD_LONG_LONG */
279 _MHD_DEPR_MACRO("Macro MHD_LONG_LONG is deprecated, use MHD_UNSIGNED_LONG_LONG")
280 #endif
281 
285 #ifndef MHD_LONG_LONG_PRINTF
286 
289 #define MHD_LONG_LONG_PRINTF "ll"
290 #define MHD_UNSIGNED_LONG_LONG_PRINTF "%llu"
291 #else /* MHD_LONG_LONG_PRINTF */
292 _MHD_DEPR_MACRO("Macro MHD_LONG_LONG_PRINTF is deprecated, use MHD_UNSIGNED_LONG_LONG_PRINTF")
293 #endif
294 
295 
301 /* See http://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml */
302 
303 #define MHD_HTTP_CONTINUE 100
304 #define MHD_HTTP_SWITCHING_PROTOCOLS 101
305 #define MHD_HTTP_PROCESSING 102
306 
307 #define MHD_HTTP_OK 200
308 #define MHD_HTTP_CREATED 201
309 #define MHD_HTTP_ACCEPTED 202
310 #define MHD_HTTP_NON_AUTHORITATIVE_INFORMATION 203
311 #define MHD_HTTP_NO_CONTENT 204
312 #define MHD_HTTP_RESET_CONTENT 205
313 #define MHD_HTTP_PARTIAL_CONTENT 206
314 #define MHD_HTTP_MULTI_STATUS 207
315 #define MHD_HTTP_ALREADY_REPORTED 208
316 
317 #define MHD_HTTP_IM_USED 226
318 
319 #define MHD_HTTP_MULTIPLE_CHOICES 300
320 #define MHD_HTTP_MOVED_PERMANENTLY 301
321 #define MHD_HTTP_FOUND 302
322 #define MHD_HTTP_SEE_OTHER 303
323 #define MHD_HTTP_NOT_MODIFIED 304
324 #define MHD_HTTP_USE_PROXY 305
325 #define MHD_HTTP_SWITCH_PROXY 306
326 #define MHD_HTTP_TEMPORARY_REDIRECT 307
327 #define MHD_HTTP_PERMANENT_REDIRECT 308
328 
329 #define MHD_HTTP_BAD_REQUEST 400
330 #define MHD_HTTP_UNAUTHORIZED 401
331 #define MHD_HTTP_PAYMENT_REQUIRED 402
332 #define MHD_HTTP_FORBIDDEN 403
333 #define MHD_HTTP_NOT_FOUND 404
334 #define MHD_HTTP_METHOD_NOT_ALLOWED 405
335 #define MHD_HTTP_NOT_ACCEPTABLE 406
336 
337 #define MHD_HTTP_METHOD_NOT_ACCEPTABLE \
338  _MHD_DEPR_IN_MACRO("Value MHD_HTTP_METHOD_NOT_ACCEPTABLE is deprecated, use MHD_HTTP_NOT_ACCEPTABLE") 406
339 #define MHD_HTTP_PROXY_AUTHENTICATION_REQUIRED 407
340 #define MHD_HTTP_REQUEST_TIMEOUT 408
341 #define MHD_HTTP_CONFLICT 409
342 #define MHD_HTTP_GONE 410
343 #define MHD_HTTP_LENGTH_REQUIRED 411
344 #define MHD_HTTP_PRECONDITION_FAILED 412
345 #define MHD_HTTP_PAYLOAD_TOO_LARGE 413
346 
347 #define MHD_HTTP_REQUEST_ENTITY_TOO_LARGE \
348  _MHD_DEPR_IN_MACRO("Value MHD_HTTP_REQUEST_ENTITY_TOO_LARGE is deprecated, use MHD_HTTP_PAYLOAD_TOO_LARGE") 413
349 #define MHD_HTTP_URI_TOO_LONG 414
350 
351 #define MHD_HTTP_REQUEST_URI_TOO_LONG \
352  _MHD_DEPR_IN_MACRO("Value MHD_HTTP_REQUEST_URI_TOO_LONG is deprecated, use MHD_HTTP_URI_TOO_LONG") 414
353 #define MHD_HTTP_UNSUPPORTED_MEDIA_TYPE 415
354 #define MHD_HTTP_RANGE_NOT_SATISFIABLE 416
355 
356 #define MHD_HTTP_REQUESTED_RANGE_NOT_SATISFIABLE \
357  _MHD_DEPR_IN_MACRO("Value MHD_HTTP_REQUESTED_RANGE_NOT_SATISFIABLE is deprecated, use MHD_HTTP_RANGE_NOT_SATISFIABLE") 416
358 #define MHD_HTTP_EXPECTATION_FAILED 417
359 
360 #define MHD_HTTP_MISDIRECTED_REQUEST 421
361 #define MHD_HTTP_UNPROCESSABLE_ENTITY 422
362 #define MHD_HTTP_LOCKED 423
363 #define MHD_HTTP_FAILED_DEPENDENCY 424
364 #define MHD_HTTP_UNORDERED_COLLECTION 425
365 #define MHD_HTTP_UPGRADE_REQUIRED 426
366 
367 #define MHD_HTTP_PRECONDITION_REQUIRED 428
368 #define MHD_HTTP_TOO_MANY_REQUESTS 429
369 #define MHD_HTTP_REQUEST_HEADER_FIELDS_TOO_LARGE 431
370 
371 #define MHD_HTTP_NO_RESPONSE 444
372 
373 #define MHD_HTTP_RETRY_WITH 449
374 #define MHD_HTTP_BLOCKED_BY_WINDOWS_PARENTAL_CONTROLS 450
375 #define MHD_HTTP_UNAVAILABLE_FOR_LEGAL_REASONS 451
376 
377 #define MHD_HTTP_INTERNAL_SERVER_ERROR 500
378 #define MHD_HTTP_NOT_IMPLEMENTED 501
379 #define MHD_HTTP_BAD_GATEWAY 502
380 #define MHD_HTTP_SERVICE_UNAVAILABLE 503
381 #define MHD_HTTP_GATEWAY_TIMEOUT 504
382 #define MHD_HTTP_HTTP_VERSION_NOT_SUPPORTED 505
383 #define MHD_HTTP_VARIANT_ALSO_NEGOTIATES 506
384 #define MHD_HTTP_INSUFFICIENT_STORAGE 507
385 #define MHD_HTTP_LOOP_DETECTED 508
386 #define MHD_HTTP_BANDWIDTH_LIMIT_EXCEEDED 509
387 #define MHD_HTTP_NOT_EXTENDED 510
388 #define MHD_HTTP_NETWORK_AUTHENTICATION_REQUIRED 511
389  /* end of group httpcode */
391 
398 _MHD_EXTERN const char *
399 MHD_get_reason_phrase_for (unsigned int code);
400 
401 
408 #define MHD_ICY_FLAG ((uint32_t)(((uint32_t)1) << 31))
409 
418 /* Main HTTP headers. */
419 /* Standard. RFC7231, Section 5.3.2 */
420 #define MHD_HTTP_HEADER_ACCEPT "Accept"
421 /* Standard. RFC7231, Section 5.3.3 */
422 #define MHD_HTTP_HEADER_ACCEPT_CHARSET "Accept-Charset"
423 /* Standard. RFC7231, Section 5.3.4; RFC7694, Section 3 */
424 #define MHD_HTTP_HEADER_ACCEPT_ENCODING "Accept-Encoding"
425 /* Standard. RFC7231, Section 5.3.5 */
426 #define MHD_HTTP_HEADER_ACCEPT_LANGUAGE "Accept-Language"
427 /* Standard. RFC7233, Section 2.3 */
428 #define MHD_HTTP_HEADER_ACCEPT_RANGES "Accept-Ranges"
429 /* Standard. RFC7234, Section 5.1 */
430 #define MHD_HTTP_HEADER_AGE "Age"
431 /* Standard. RFC7231, Section 7.4.1 */
432 #define MHD_HTTP_HEADER_ALLOW "Allow"
433 /* Standard. RFC7235, Section 4.2 */
434 #define MHD_HTTP_HEADER_AUTHORIZATION "Authorization"
435 /* Standard. RFC7234, Section 5.2 */
436 #define MHD_HTTP_HEADER_CACHE_CONTROL "Cache-Control"
437 /* Reserved. RFC7230, Section 8.1 */
438 #define MHD_HTTP_HEADER_CLOSE "Close"
439 /* Standard. RFC7230, Section 6.1 */
440 #define MHD_HTTP_HEADER_CONNECTION "Connection"
441 /* Standard. RFC7231, Section 3.1.2.2 */
442 #define MHD_HTTP_HEADER_CONTENT_ENCODING "Content-Encoding"
443 /* Standard. RFC7231, Section 3.1.3.2 */
444 #define MHD_HTTP_HEADER_CONTENT_LANGUAGE "Content-Language"
445 /* Standard. RFC7230, Section 3.3.2 */
446 #define MHD_HTTP_HEADER_CONTENT_LENGTH "Content-Length"
447 /* Standard. RFC7231, Section 3.1.4.2 */
448 #define MHD_HTTP_HEADER_CONTENT_LOCATION "Content-Location"
449 /* Standard. RFC7233, Section 4.2 */
450 #define MHD_HTTP_HEADER_CONTENT_RANGE "Content-Range"
451 /* Standard. RFC7231, Section 3.1.1.5 */
452 #define MHD_HTTP_HEADER_CONTENT_TYPE "Content-Type"
453 /* Standard. RFC7231, Section 7.1.1.2 */
454 #define MHD_HTTP_HEADER_DATE "Date"
455 /* Standard. RFC7232, Section 2.3 */
456 #define MHD_HTTP_HEADER_ETAG "ETag"
457 /* Standard. RFC7231, Section 5.1.1 */
458 #define MHD_HTTP_HEADER_EXPECT "Expect"
459 /* Standard. RFC7234, Section 5.3 */
460 #define MHD_HTTP_HEADER_EXPIRES "Expires"
461 /* Standard. RFC7231, Section 5.5.1 */
462 #define MHD_HTTP_HEADER_FROM "From"
463 /* Standard. RFC7230, Section 5.4 */
464 #define MHD_HTTP_HEADER_HOST "Host"
465 /* Standard. RFC7232, Section 3.1 */
466 #define MHD_HTTP_HEADER_IF_MATCH "If-Match"
467 /* Standard. RFC7232, Section 3.3 */
468 #define MHD_HTTP_HEADER_IF_MODIFIED_SINCE "If-Modified-Since"
469 /* Standard. RFC7232, Section 3.2 */
470 #define MHD_HTTP_HEADER_IF_NONE_MATCH "If-None-Match"
471 /* Standard. RFC7233, Section 3.2 */
472 #define MHD_HTTP_HEADER_IF_RANGE "If-Range"
473 /* Standard. RFC7232, Section 3.4 */
474 #define MHD_HTTP_HEADER_IF_UNMODIFIED_SINCE "If-Unmodified-Since"
475 /* Standard. RFC7232, Section 2.2 */
476 #define MHD_HTTP_HEADER_LAST_MODIFIED "Last-Modified"
477 /* Standard. RFC7231, Section 7.1.2 */
478 #define MHD_HTTP_HEADER_LOCATION "Location"
479 /* Standard. RFC7231, Section 5.1.2 */
480 #define MHD_HTTP_HEADER_MAX_FORWARDS "Max-Forwards"
481 /* Standard. RFC7231, Appendix A.1 */
482 #define MHD_HTTP_HEADER_MIME_VERSION "MIME-Version"
483 /* Standard. RFC7234, Section 5.4 */
484 #define MHD_HTTP_HEADER_PRAGMA "Pragma"
485 /* Standard. RFC7235, Section 4.3 */
486 #define MHD_HTTP_HEADER_PROXY_AUTHENTICATE "Proxy-Authenticate"
487 /* Standard. RFC7235, Section 4.4 */
488 #define MHD_HTTP_HEADER_PROXY_AUTHORIZATION "Proxy-Authorization"
489 /* Standard. RFC7233, Section 3.1 */
490 #define MHD_HTTP_HEADER_RANGE "Range"
491 /* Standard. RFC7231, Section 5.5.2 */
492 #define MHD_HTTP_HEADER_REFERER "Referer"
493 /* Standard. RFC7231, Section 7.1.3 */
494 #define MHD_HTTP_HEADER_RETRY_AFTER "Retry-After"
495 /* Standard. RFC7231, Section 7.4.2 */
496 #define MHD_HTTP_HEADER_SERVER "Server"
497 /* Standard. RFC7230, Section 4.3 */
498 #define MHD_HTTP_HEADER_TE "TE"
499 /* Standard. RFC7230, Section 4.4 */
500 #define MHD_HTTP_HEADER_TRAILER "Trailer"
501 /* Standard. RFC7230, Section 3.3.1 */
502 #define MHD_HTTP_HEADER_TRANSFER_ENCODING "Transfer-Encoding"
503 /* Standard. RFC7230, Section 6.7 */
504 #define MHD_HTTP_HEADER_UPGRADE "Upgrade"
505 /* Standard. RFC7231, Section 5.5.3 */
506 #define MHD_HTTP_HEADER_USER_AGENT "User-Agent"
507 /* Standard. RFC7231, Section 7.1.4 */
508 #define MHD_HTTP_HEADER_VARY "Vary"
509 /* Standard. RFC7230, Section 5.7.1 */
510 #define MHD_HTTP_HEADER_VIA "Via"
511 /* Standard. RFC7235, Section 4.1 */
512 #define MHD_HTTP_HEADER_WWW_AUTHENTICATE "WWW-Authenticate"
513 /* Standard. RFC7234, Section 5.5 */
514 #define MHD_HTTP_HEADER_WARNING "Warning"
515 
516 /* Additional HTTP headers. */
517 /* No category. RFC4229 */
518 #define MHD_HTTP_HEADER_A_IM "A-IM"
519 /* No category. RFC4229 */
520 #define MHD_HTTP_HEADER_ACCEPT_ADDITIONS "Accept-Additions"
521 /* Informational. RFC7089 */
522 #define MHD_HTTP_HEADER_ACCEPT_DATETIME "Accept-Datetime"
523 /* No category. RFC4229 */
524 #define MHD_HTTP_HEADER_ACCEPT_FEATURES "Accept-Features"
525 /* No category. RFC5789 */
526 #define MHD_HTTP_HEADER_ACCEPT_PATCH "Accept-Patch"
527 /* Standard. RFC7639, Section 2 */
528 #define MHD_HTTP_HEADER_ALPN "ALPN"
529 /* Standard. RFC7838 */
530 #define MHD_HTTP_HEADER_ALT_SVC "Alt-Svc"
531 /* Standard. RFC7838 */
532 #define MHD_HTTP_HEADER_ALT_USED "Alt-Used"
533 /* No category. RFC4229 */
534 #define MHD_HTTP_HEADER_ALTERNATES "Alternates"
535 /* No category. RFC4437 */
536 #define MHD_HTTP_HEADER_APPLY_TO_REDIRECT_REF "Apply-To-Redirect-Ref"
537 /* Experimental. RFC8053, Section 4 */
538 #define MHD_HTTP_HEADER_AUTHENTICATION_CONTROL "Authentication-Control"
539 /* Standard. RFC7615, Section 3 */
540 #define MHD_HTTP_HEADER_AUTHENTICATION_INFO "Authentication-Info"
541 /* No category. RFC4229 */
542 #define MHD_HTTP_HEADER_C_EXT "C-Ext"
543 /* No category. RFC4229 */
544 #define MHD_HTTP_HEADER_C_MAN "C-Man"
545 /* No category. RFC4229 */
546 #define MHD_HTTP_HEADER_C_OPT "C-Opt"
547 /* No category. RFC4229 */
548 #define MHD_HTTP_HEADER_C_PEP "C-PEP"
549 /* No category. RFC4229 */
550 #define MHD_HTTP_HEADER_C_PEP_INFO "C-PEP-Info"
551 /* Standard. RFC7809, Section 7.1 */
552 #define MHD_HTTP_HEADER_CALDAV_TIMEZONES "CalDAV-Timezones"
553 /* Obsoleted. RFC2068; RFC2616 */
554 #define MHD_HTTP_HEADER_CONTENT_BASE "Content-Base"
555 /* Standard. RFC6266 */
556 #define MHD_HTTP_HEADER_CONTENT_DISPOSITION "Content-Disposition"
557 /* No category. RFC4229 */
558 #define MHD_HTTP_HEADER_CONTENT_ID "Content-ID"
559 /* No category. RFC4229 */
560 #define MHD_HTTP_HEADER_CONTENT_MD5 "Content-MD5"
561 /* No category. RFC4229 */
562 #define MHD_HTTP_HEADER_CONTENT_SCRIPT_TYPE "Content-Script-Type"
563 /* No category. RFC4229 */
564 #define MHD_HTTP_HEADER_CONTENT_STYLE_TYPE "Content-Style-Type"
565 /* No category. RFC4229 */
566 #define MHD_HTTP_HEADER_CONTENT_VERSION "Content-Version"
567 /* Standard. RFC6265 */
568 #define MHD_HTTP_HEADER_COOKIE "Cookie"
569 /* Obsoleted. RFC2965; RFC6265 */
570 #define MHD_HTTP_HEADER_COOKIE2 "Cookie2"
571 /* Standard. RFC5323 */
572 #define MHD_HTTP_HEADER_DASL "DASL"
573 /* Standard. RFC4918 */
574 #define MHD_HTTP_HEADER_DAV "DAV"
575 /* No category. RFC4229 */
576 #define MHD_HTTP_HEADER_DEFAULT_STYLE "Default-Style"
577 /* No category. RFC4229 */
578 #define MHD_HTTP_HEADER_DELTA_BASE "Delta-Base"
579 /* Standard. RFC4918 */
580 #define MHD_HTTP_HEADER_DEPTH "Depth"
581 /* No category. RFC4229 */
582 #define MHD_HTTP_HEADER_DERIVED_FROM "Derived-From"
583 /* Standard. RFC4918 */
584 #define MHD_HTTP_HEADER_DESTINATION "Destination"
585 /* No category. RFC4229 */
586 #define MHD_HTTP_HEADER_DIFFERENTIAL_ID "Differential-ID"
587 /* No category. RFC4229 */
588 #define MHD_HTTP_HEADER_DIGEST "Digest"
589 /* No category. RFC4229 */
590 #define MHD_HTTP_HEADER_EXT "Ext"
591 /* Standard. RFC7239 */
592 #define MHD_HTTP_HEADER_FORWARDED "Forwarded"
593 /* No category. RFC4229 */
594 #define MHD_HTTP_HEADER_GETPROFILE "GetProfile"
595 /* Experimental. RFC7486, Section 6.1.1 */
596 #define MHD_HTTP_HEADER_HOBAREG "Hobareg"
597 /* Standard. RFC7540, Section 3.2.1 */
598 #define MHD_HTTP_HEADER_HTTP2_SETTINGS "HTTP2-Settings"
599 /* No category. RFC4229 */
600 #define MHD_HTTP_HEADER_IM "IM"
601 /* Standard. RFC4918 */
602 #define MHD_HTTP_HEADER_IF "If"
603 /* Standard. RFC6638 */
604 #define MHD_HTTP_HEADER_IF_SCHEDULE_TAG_MATCH "If-Schedule-Tag-Match"
605 /* No category. RFC4229 */
606 #define MHD_HTTP_HEADER_KEEP_ALIVE "Keep-Alive"
607 /* No category. RFC4229 */
608 #define MHD_HTTP_HEADER_LABEL "Label"
609 /* No category. RFC5988 */
610 #define MHD_HTTP_HEADER_LINK "Link"
611 /* Standard. RFC4918 */
612 #define MHD_HTTP_HEADER_LOCK_TOKEN "Lock-Token"
613 /* No category. RFC4229 */
614 #define MHD_HTTP_HEADER_MAN "Man"
615 /* Informational. RFC7089 */
616 #define MHD_HTTP_HEADER_MEMENTO_DATETIME "Memento-Datetime"
617 /* No category. RFC4229 */
618 #define MHD_HTTP_HEADER_METER "Meter"
619 /* No category. RFC4229 */
620 #define MHD_HTTP_HEADER_NEGOTIATE "Negotiate"
621 /* No category. RFC4229 */
622 #define MHD_HTTP_HEADER_OPT "Opt"
623 /* Experimental. RFC8053, Section 3 */
624 #define MHD_HTTP_HEADER_OPTIONAL_WWW_AUTHENTICATE "Optional-WWW-Authenticate"
625 /* Standard. RFC4229 */
626 #define MHD_HTTP_HEADER_ORDERING_TYPE "Ordering-Type"
627 /* Standard. RFC6454 */
628 #define MHD_HTTP_HEADER_ORIGIN "Origin"
629 /* Standard. RFC4918 */
630 #define MHD_HTTP_HEADER_OVERWRITE "Overwrite"
631 /* No category. RFC4229 */
632 #define MHD_HTTP_HEADER_P3P "P3P"
633 /* No category. RFC4229 */
634 #define MHD_HTTP_HEADER_PEP "PEP"
635 /* No category. RFC4229 */
636 #define MHD_HTTP_HEADER_PICS_LABEL "PICS-Label"
637 /* No category. RFC4229 */
638 #define MHD_HTTP_HEADER_PEP_INFO "Pep-Info"
639 /* Standard. RFC4229 */
640 #define MHD_HTTP_HEADER_POSITION "Position"
641 /* Standard. RFC7240 */
642 #define MHD_HTTP_HEADER_PREFER "Prefer"
643 /* Standard. RFC7240 */
644 #define MHD_HTTP_HEADER_PREFERENCE_APPLIED "Preference-Applied"
645 /* No category. RFC4229 */
646 #define MHD_HTTP_HEADER_PROFILEOBJECT "ProfileObject"
647 /* No category. RFC4229 */
648 #define MHD_HTTP_HEADER_PROTOCOL "Protocol"
649 /* No category. RFC4229 */
650 #define MHD_HTTP_HEADER_PROTOCOL_INFO "Protocol-Info"
651 /* No category. RFC4229 */
652 #define MHD_HTTP_HEADER_PROTOCOL_QUERY "Protocol-Query"
653 /* No category. RFC4229 */
654 #define MHD_HTTP_HEADER_PROTOCOL_REQUEST "Protocol-Request"
655 /* Standard. RFC7615, Section 4 */
656 #define MHD_HTTP_HEADER_PROXY_AUTHENTICATION_INFO "Proxy-Authentication-Info"
657 /* No category. RFC4229 */
658 #define MHD_HTTP_HEADER_PROXY_FEATURES "Proxy-Features"
659 /* No category. RFC4229 */
660 #define MHD_HTTP_HEADER_PROXY_INSTRUCTION "Proxy-Instruction"
661 /* No category. RFC4229 */
662 #define MHD_HTTP_HEADER_PUBLIC "Public"
663 /* Standard. RFC7469 */
664 #define MHD_HTTP_HEADER_PUBLIC_KEY_PINS "Public-Key-Pins"
665 /* Standard. RFC7469 */
666 #define MHD_HTTP_HEADER_PUBLIC_KEY_PINS_REPORT_ONLY "Public-Key-Pins-Report-Only"
667 /* No category. RFC4437 */
668 #define MHD_HTTP_HEADER_REDIRECT_REF "Redirect-Ref"
669 /* No category. RFC4229 */
670 #define MHD_HTTP_HEADER_SAFE "Safe"
671 /* Standard. RFC6638 */
672 #define MHD_HTTP_HEADER_SCHEDULE_REPLY "Schedule-Reply"
673 /* Standard. RFC6638 */
674 #define MHD_HTTP_HEADER_SCHEDULE_TAG "Schedule-Tag"
675 /* Standard. RFC6455 */
676 #define MHD_HTTP_HEADER_SEC_WEBSOCKET_ACCEPT "Sec-WebSocket-Accept"
677 /* Standard. RFC6455 */
678 #define MHD_HTTP_HEADER_SEC_WEBSOCKET_EXTENSIONS "Sec-WebSocket-Extensions"
679 /* Standard. RFC6455 */
680 #define MHD_HTTP_HEADER_SEC_WEBSOCKET_KEY "Sec-WebSocket-Key"
681 /* Standard. RFC6455 */
682 #define MHD_HTTP_HEADER_SEC_WEBSOCKET_PROTOCOL "Sec-WebSocket-Protocol"
683 /* Standard. RFC6455 */
684 #define MHD_HTTP_HEADER_SEC_WEBSOCKET_VERSION "Sec-WebSocket-Version"
685 /* No category. RFC4229 */
686 #define MHD_HTTP_HEADER_SECURITY_SCHEME "Security-Scheme"
687 /* Standard. RFC6265 */
688 #define MHD_HTTP_HEADER_SET_COOKIE "Set-Cookie"
689 /* Obsoleted. RFC2965; RFC6265 */
690 #define MHD_HTTP_HEADER_SET_COOKIE2 "Set-Cookie2"
691 /* No category. RFC4229 */
692 #define MHD_HTTP_HEADER_SETPROFILE "SetProfile"
693 /* Standard. RFC5023 */
694 #define MHD_HTTP_HEADER_SLUG "SLUG"
695 /* No category. RFC4229 */
696 #define MHD_HTTP_HEADER_SOAPACTION "SoapAction"
697 /* No category. RFC4229 */
698 #define MHD_HTTP_HEADER_STATUS_URI "Status-URI"
699 /* Standard. RFC6797 */
700 #define MHD_HTTP_HEADER_STRICT_TRANSPORT_SECURITY "Strict-Transport-Security"
701 /* No category. RFC4229 */
702 #define MHD_HTTP_HEADER_SURROGATE_CAPABILITY "Surrogate-Capability"
703 /* No category. RFC4229 */
704 #define MHD_HTTP_HEADER_SURROGATE_CONTROL "Surrogate-Control"
705 /* No category. RFC4229 */
706 #define MHD_HTTP_HEADER_TCN "TCN"
707 /* Standard. RFC4918 */
708 #define MHD_HTTP_HEADER_TIMEOUT "Timeout"
709 /* Standard. RFC8030, Section 5.4 */
710 #define MHD_HTTP_HEADER_TOPIC "Topic"
711 /* Standard. RFC8030, Section 5.2 */
712 #define MHD_HTTP_HEADER_TTL "TTL"
713 /* Standard. RFC8030, Section 5.3 */
714 #define MHD_HTTP_HEADER_URGENCY "Urgency"
715 /* No category. RFC4229 */
716 #define MHD_HTTP_HEADER_URI "URI"
717 /* No category. RFC4229 */
718 #define MHD_HTTP_HEADER_VARIANT_VARY "Variant-Vary"
719 /* No category. RFC4229 */
720 #define MHD_HTTP_HEADER_WANT_DIGEST "Want-Digest"
721 /* Informational. RFC7034 */
722 #define MHD_HTTP_HEADER_X_FRAME_OPTIONS "X-Frame-Options"
723 
724 /* Some provisional headers. */
725 #define MHD_HTTP_HEADER_ACCESS_CONTROL_ALLOW_ORIGIN "Access-Control-Allow-Origin"
726  /* end of group headers */
727 
734 #define MHD_HTTP_VERSION_1_0 "HTTP/1.0"
735 #define MHD_HTTP_VERSION_1_1 "HTTP/1.1"
736  /* end of group versions */
738 
746 /* Main HTTP methods. */
747 /* Not safe. Not idempotent. RFC7231, Section 4.3.6. */
748 #define MHD_HTTP_METHOD_CONNECT "CONNECT"
749 /* Not safe. Idempotent. RFC7231, Section 4.3.5. */
750 #define MHD_HTTP_METHOD_DELETE "DELETE"
751 /* Safe. Idempotent. RFC7231, Section 4.3.1. */
752 #define MHD_HTTP_METHOD_GET "GET"
753 /* Safe. Idempotent. RFC7231, Section 4.3.2. */
754 #define MHD_HTTP_METHOD_HEAD "HEAD"
755 /* Safe. Idempotent. RFC7231, Section 4.3.7. */
756 #define MHD_HTTP_METHOD_OPTIONS "OPTIONS"
757 /* Not safe. Not idempotent. RFC7231, Section 4.3.3. */
758 #define MHD_HTTP_METHOD_POST "POST"
759 /* Not safe. Idempotent. RFC7231, Section 4.3.4. */
760 #define MHD_HTTP_METHOD_PUT "PUT"
761 /* Safe. Idempotent. RFC7231, Section 4.3.8. */
762 #define MHD_HTTP_METHOD_TRACE "TRACE"
763 
764 /* Additional HTTP methods. */
765 /* Not safe. Idempotent. RFC3744, Section 8.1. */
766 #define MHD_HTTP_METHOD_ACL "ACL"
767 /* Not safe. Idempotent. RFC3253, Section 12.6. */
768 #define MHD_HTTP_METHOD_BASELINE_CONTROL "BASELINE-CONTROL"
769 /* Not safe. Idempotent. RFC5842, Section 4. */
770 #define MHD_HTTP_METHOD_BIND "BIND"
771 /* Not safe. Idempotent. RFC3253, Section 4.4, Section 9.4. */
772 #define MHD_HTTP_METHOD_CHECKIN "CHECKIN"
773 /* Not safe. Idempotent. RFC3253, Section 4.3, Section 8.8. */
774 #define MHD_HTTP_METHOD_CHECKOUT "CHECKOUT"
775 /* Not safe. Idempotent. RFC4918, Section 9.8. */
776 #define MHD_HTTP_METHOD_COPY "COPY"
777 /* Not safe. Idempotent. RFC3253, Section 8.2. */
778 #define MHD_HTTP_METHOD_LABEL "LABEL"
779 /* Not safe. Idempotent. RFC2068, Section 19.6.1.2. */
780 #define MHD_HTTP_METHOD_LINK "LINK"
781 /* Not safe. Not idempotent. RFC4918, Section 9.10. */
782 #define MHD_HTTP_METHOD_LOCK "LOCK"
783 /* Not safe. Idempotent. RFC3253, Section 11.2. */
784 #define MHD_HTTP_METHOD_MERGE "MERGE"
785 /* Not safe. Idempotent. RFC3253, Section 13.5. */
786 #define MHD_HTTP_METHOD_MKACTIVITY "MKACTIVITY"
787 /* Not safe. Idempotent. RFC4791, Section 5.3.1. */
788 #define MHD_HTTP_METHOD_MKCALENDAR "MKCALENDAR"
789 /* Not safe. Idempotent. RFC4918, Section 9.3. */
790 #define MHD_HTTP_METHOD_MKCOL "MKCOL"
791 /* Not safe. Idempotent. RFC4437, Section 6. */
792 #define MHD_HTTP_METHOD_MKREDIRECTREF "MKREDIRECTREF"
793 /* Not safe. Idempotent. RFC3253, Section 6.3. */
794 #define MHD_HTTP_METHOD_MKWORKSPACE "MKWORKSPACE"
795 /* Not safe. Idempotent. RFC4918, Section 9.9. */
796 #define MHD_HTTP_METHOD_MOVE "MOVE"
797 /* Not safe. Idempotent. RFC3648, Section 7. */
798 #define MHD_HTTP_METHOD_ORDERPATCH "ORDERPATCH"
799 /* Not safe. Not idempotent. RFC5789, Section 2. */
800 #define MHD_HTTP_METHOD_PATCH "PATCH"
801 /* Safe. Idempotent. RFC7540, Section 3.5. */
802 #define MHD_HTTP_METHOD_PRI "PRI"
803 /* Safe. Idempotent. RFC4918, Section 9.1. */
804 #define MHD_HTTP_METHOD_PROPFIND "PROPFIND"
805 /* Not safe. Idempotent. RFC4918, Section 9.2. */
806 #define MHD_HTTP_METHOD_PROPPATCH "PROPPATCH"
807 /* Not safe. Idempotent. RFC5842, Section 6. */
808 #define MHD_HTTP_METHOD_REBIND "REBIND"
809 /* Safe. Idempotent. RFC3253, Section 3.6. */
810 #define MHD_HTTP_METHOD_REPORT "REPORT"
811 /* Safe. Idempotent. RFC5323, Section 2. */
812 #define MHD_HTTP_METHOD_SEARCH "SEARCH"
813 /* Not safe. Idempotent. RFC5842, Section 5. */
814 #define MHD_HTTP_METHOD_UNBIND "UNBIND"
815 /* Not safe. Idempotent. RFC3253, Section 4.5. */
816 #define MHD_HTTP_METHOD_UNCHECKOUT "UNCHECKOUT"
817 /* Not safe. Idempotent. RFC2068, Section 19.6.1.3. */
818 #define MHD_HTTP_METHOD_UNLINK "UNLINK"
819 /* Not safe. Idempotent. RFC4918, Section 9.11. */
820 #define MHD_HTTP_METHOD_UNLOCK "UNLOCK"
821 /* Not safe. Idempotent. RFC3253, Section 7.1. */
822 #define MHD_HTTP_METHOD_UPDATE "UPDATE"
823 /* Not safe. Idempotent. RFC4437, Section 7. */
824 #define MHD_HTTP_METHOD_UPDATEREDIRECTREF "UPDATEREDIRECTREF"
825 /* Not safe. Idempotent. RFC3253, Section 3.5. */
826 #define MHD_HTTP_METHOD_VERSION_CONTROL "VERSION-CONTROL"
827  /* end of group methods */
829 
835 #define MHD_HTTP_POST_ENCODING_FORM_URLENCODED "application/x-www-form-urlencoded"
836 #define MHD_HTTP_POST_ENCODING_MULTIPART_FORMDATA "multipart/form-data"
837  /* end of group postenc */
839 
840 
845 struct MHD_Daemon;
846 
855 struct MHD_Connection;
856 
861 struct MHD_Response;
862 
867 struct MHD_PostProcessor;
868 
869 
883 {
888 
895 
901 
906 
909 #if 0
910  /* let's do this later once versions that define MHD_USE_TLS a more widely deployed. */
911 #define MHD_USE_SSL \
912  _MHD_DEPR_IN_MACRO("Value MHD_USE_SSL is deprecated, use MHD_USE_TLS") \
913  MHD_USE_TLS
914 #endif
915 
921 
932 
935 #if 0 /* Will be marked for real deprecation later. */
936 #define MHD_USE_SELECT_INTERNALLY \
937  _MHD_DEPR_IN_MACRO("Value MHD_USE_SELECT_INTERNALLY is deprecated, use MHD_USE_INTERNAL_POLLING_THREAD instead") \
938  MHD_USE_INTERNAL_POLLING_THREAD
939 #endif /* 0 */
940 
949 
960 #if 0 /* Will be marked for real deprecation later. */
961 #define MHD_USE_PEDANTIC_CHECKS \
962  _MHD_DEPR_IN_MACRO("Flag MHD_USE_PEDANTIC_CHECKS is deprecated, use option MHD_OPTION_STRICT_FOR_CLIENT instead") \
963  32
964 #endif /* 0 */
965 
975 
981 
984 #if 0 /* Will be marked for real deprecation later. */
985 #define MHD_USE_POLL_INTERNALLY \
986  _MHD_DEPR_IN_MACRO("Value MHD_USE_POLL_INTERNALLY is deprecated, use MHD_USE_POLL_INTERNAL_THREAD instead") \
987  MHD_USE_POLL_INTERNAL_THREAD
988 #endif /* 0 */
989 
997 
1000 #if 0 /* Will be marked for real deprecation later. */
1001 #define MHD_SUPPRESS_DATE_NO_CLOCK \
1002  _MHD_DEPR_IN_MACRO("Value MHD_SUPPRESS_DATE_NO_CLOCK is deprecated, use MHD_USE_SUPPRESS_DATE_NO_CLOCK instead") \
1003  MHD_USE_SUPPRESS_DATE_NO_CLOCK
1004 #endif /* 0 */
1005 
1014 
1023 
1026 #if 0 /* Will be marked for real deprecation later. */
1027 #define MHD_USE_EPOLL_LINUX_ONLY \
1028  _MHD_DEPR_IN_MACRO("Value MHD_USE_EPOLL_LINUX_ONLY is deprecated, use MHD_USE_EPOLL") \
1029  MHD_USE_EPOLL
1030 #endif /* 0 */
1031 
1039 
1044 #if 0 /* Will be marked for real deprecation later. */
1045 #define MHD_USE_EPOLL_INTERNALLY \
1046  _MHD_DEPR_IN_MACRO("Value MHD_USE_EPOLL_INTERNALLY is deprecated, use MHD_USE_EPOLL_INTERNAL_THREAD") \
1047  MHD_USE_EPOLL_INTERNAL_THREAD
1048 
1049 #define MHD_USE_EPOLL_INTERNALLY_LINUX_ONLY \
1050  _MHD_DEPR_IN_MACRO("Value MHD_USE_EPOLL_INTERNALLY_LINUX_ONLY is deprecated, use MHD_USE_EPOLL_INTERNAL_THREAD") \
1051  MHD_USE_EPOLL_INTERNAL_THREAD
1052 #endif /* 0 */
1053 
1066  MHD_USE_ITC = 1024,
1067 
1070 #if 0 /* Will be marked for real deprecation later. */
1071 #define MHD_USE_PIPE_FOR_SHUTDOWN \
1072  _MHD_DEPR_IN_MACRO("Value MHD_USE_PIPE_FOR_SHUTDOWN is deprecated, use MHD_USE_ITC") \
1073  MHD_USE_ITC
1074 #endif /* 0 */
1075 
1080 
1088 
1091 #if 0 /* Will be marked for real deprecation later. */
1092 #define MHD_USE_EPOLL_TURBO \
1093  _MHD_DEPR_IN_MACRO("Value MHD_USE_EPOLL_TURBO is deprecated, use MHD_USE_TURBO") \
1094  MHD_USE_TURBO
1095 #endif /* 0 */
1096 
1102 
1105 #if 0 /* Will be marked for real deprecation later. */
1106 #define MHD_USE_SUSPEND_RESUME \
1107  _MHD_DEPR_IN_MACRO("Value MHD_USE_SUSPEND_RESUME is deprecated, use MHD_ALLOW_SUSPEND_RESUME instead") \
1108  MHD_ALLOW_SUSPEND_RESUME
1109 #endif /* 0 */
1110 
1117 
1124 
1136  MHD_USE_AUTO = 65536,
1137 
1145 
1146 };
1147 
1148 
1157 typedef void
1158 (*MHD_LogCallback)(void *cls,
1159  const char *fm,
1160  va_list ap);
1161 
1162 
1169 {
1170 
1176 
1185 
1191 
1198 
1212 
1224 
1232 
1264 
1272 
1280 
1287 
1293 
1301 
1314 
1324 
1345 
1365 
1376 
1383 
1389 
1396 
1402 
1418 
1427 
1434 
1443 
1452 
1463 
1471 
1490 };
1491 
1492 
1497 {
1503 
1509  intptr_t value;
1510 
1515  void *ptr_value;
1516 
1517 };
1518 
1519 
1525 {
1526 
1532 #define MHD_RESPONSE_HEADER_KIND \
1533  _MHD_DEPR_IN_MACRO("Value MHD_RESPONSE_HEADER_KIND is deprecated and not used") \
1534  MHD_RESPONSE_HEADER_KIND
1535 
1540 
1546 
1556 
1561 
1566 };
1567 
1568 
1575 {
1576 
1582 
1590 
1598 
1605 
1615 
1623 
1624 };
1625 
1626 
1633 {
1634 
1640 
1646 
1647 };
1648 
1649 
1654 {
1655 
1659  int /* enum gnutls_cipher_algorithm */ cipher_algorithm;
1660 
1664  int /* enum gnutls_protocol */ protocol;
1665 
1669  int /* MHD_YES or MHD_NO */ suspended;
1670 
1676  unsigned int connection_timeout;
1677 
1682 
1686  size_t header_size;
1687 
1691  void * /* gnutls_session_t */ tls_session;
1692 
1696  void * /* gnutls_x509_crt_t */ client_cert;
1697 
1701  struct sockaddr *client_addr;
1702 
1708 
1714 };
1715 
1716 
1723 {
1730 
1737 
1746 
1752 
1760 
1766 
1773 
1783 
1789 
1795 
1801 };
1802 
1803 
1809 {
1814 
1819 
1825 
1832 
1841 
1849 };
1850 
1851 
1862 typedef void
1863 (*MHD_PanicCallback) (void *cls,
1864  const char *file,
1865  unsigned int line,
1866  const char *reason);
1867 
1876 typedef int
1878  const struct sockaddr *addr,
1879  socklen_t addrlen);
1880 
1881 
1921 typedef int
1923  struct MHD_Connection *connection,
1924  const char *url,
1925  const char *method,
1926  const char *version,
1927  const char *upload_data,
1928  size_t *upload_data_size,
1929  void **con_cls);
1930 
1931 
1944 typedef void
1946  struct MHD_Connection *connection,
1947  void **con_cls,
1948  enum MHD_RequestTerminationCode toe);
1949 
1969 typedef void
1971  struct MHD_Connection *connection,
1972  void **socket_context,
1974 
1975 
1991 typedef int
1992 (*MHD_KeyValueIterator) (void *cls,
1993  enum MHD_ValueKind kind,
1994  const char *key,
1995  const char *value);
1996 
1997 
2042 typedef ssize_t
2044  uint64_t pos,
2045  char *buf,
2046  size_t max);
2047 
2048 
2058 typedef void
2060 
2061 
2081 typedef int
2082 (*MHD_PostDataIterator) (void *cls,
2083  enum MHD_ValueKind kind,
2084  const char *key,
2085  const char *filename,
2086  const char *content_type,
2087  const char *transfer_encoding,
2088  const char *data,
2089  uint64_t off,
2090  size_t size);
2091 
2092 /* **************** Daemon handling functions ***************** */
2093 
2111 _MHD_EXTERN struct MHD_Daemon *
2112 MHD_start_daemon_va (unsigned int flags,
2113  uint16_t port,
2115  MHD_AccessHandlerCallback dh, void *dh_cls,
2116  va_list ap);
2117 
2118 
2135 _MHD_EXTERN struct MHD_Daemon *
2136 MHD_start_daemon (unsigned int flags,
2137  uint16_t port,
2139  MHD_AccessHandlerCallback dh, void *dh_cls,
2140  ...);
2141 
2142 
2163 MHD_quiesce_daemon (struct MHD_Daemon *daemon);
2164 
2165 
2172 _MHD_EXTERN void
2173 MHD_stop_daemon (struct MHD_Daemon *daemon);
2174 
2175 
2205 _MHD_EXTERN int
2206 MHD_add_connection (struct MHD_Daemon *daemon,
2207  MHD_socket client_socket,
2208  const struct sockaddr *addr,
2209  socklen_t addrlen);
2210 
2211 
2239 _MHD_EXTERN int
2240 MHD_get_fdset (struct MHD_Daemon *daemon,
2241  fd_set *read_fd_set,
2242  fd_set *write_fd_set,
2243  fd_set *except_fd_set,
2244  MHD_socket *max_fd);
2245 
2246 
2277 _MHD_EXTERN int
2278 MHD_get_fdset2 (struct MHD_Daemon *daemon,
2279  fd_set *read_fd_set,
2280  fd_set *write_fd_set,
2281  fd_set *except_fd_set,
2282  MHD_socket *max_fd,
2283  unsigned int fd_setsize);
2284 
2285 
2308 #define MHD_get_fdset(daemon,read_fd_set,write_fd_set,except_fd_set,max_fd) \
2309  MHD_get_fdset2((daemon),(read_fd_set),(write_fd_set),(except_fd_set),(max_fd),FD_SETSIZE)
2310 
2311 
2326 _MHD_EXTERN int
2327 MHD_get_timeout (struct MHD_Daemon *daemon,
2328  MHD_UNSIGNED_LONG_LONG *timeout);
2329 
2330 
2350 _MHD_EXTERN int
2351 MHD_run (struct MHD_Daemon *daemon);
2352 
2353 
2376 _MHD_EXTERN int
2377 MHD_run_from_select (struct MHD_Daemon *daemon,
2378  const fd_set *read_fd_set,
2379  const fd_set *write_fd_set,
2380  const fd_set *except_fd_set);
2381 
2382 
2383 
2384 
2385 /* **************** Connection handling functions ***************** */
2386 
2398 _MHD_EXTERN int
2399 MHD_get_connection_values (struct MHD_Connection *connection,
2400  enum MHD_ValueKind kind,
2401  MHD_KeyValueIterator iterator,
2402  void *iterator_cls);
2403 
2404 
2431 _MHD_EXTERN int
2432 MHD_set_connection_value (struct MHD_Connection *connection,
2433  enum MHD_ValueKind kind,
2434  const char *key,
2435  const char *value);
2436 
2437 
2454 _MHD_EXTERN void
2455 MHD_set_panic_func (MHD_PanicCallback cb, void *cls);
2456 
2457 
2467 _MHD_EXTERN size_t
2468 MHD_http_unescape (char *val);
2469 
2470 
2481 _MHD_EXTERN const char *
2482 MHD_lookup_connection_value (struct MHD_Connection *connection,
2483  enum MHD_ValueKind kind,
2484  const char *key);
2485 
2486 
2498 _MHD_EXTERN int
2499 MHD_queue_response (struct MHD_Connection *connection,
2500  unsigned int status_code,
2501  struct MHD_Response *response);
2502 
2503 
2529 _MHD_EXTERN void
2530 MHD_suspend_connection (struct MHD_Connection *connection);
2531 
2532 
2547 _MHD_EXTERN void
2548 MHD_resume_connection (struct MHD_Connection *connection);
2549 
2550 
2551 /* **************** Response manipulation functions ***************** */
2552 
2553 
2557 enum MHD_ResponseFlags
2558 {
2562  MHD_RF_NONE = 0,
2563 
2569  MHD_RF_HTTP_VERSION_1_0_ONLY = 1
2570 
2571 };
2572 
2573 
2577 enum MHD_ResponseOptions
2578 {
2582  MHD_RO_END = 0
2583 };
2584 
2585 
2594 _MHD_EXTERN int
2595 MHD_set_response_options (struct MHD_Response *response,
2596  enum MHD_ResponseFlags flags,
2597  ...);
2598 
2599 
2616 _MHD_EXTERN struct MHD_Response *
2617 MHD_create_response_from_callback (uint64_t size,
2618  size_t block_size,
2621 
2622 
2637 _MHD_DEPR_FUNC("MHD_create_response_from_data() is deprecated, use MHD_create_response_from_buffer()") \
2638 _MHD_EXTERN struct MHD_Response *
2639 MHD_create_response_from_data (size_t size,
2640  void *data,
2641  int must_free,
2642  int must_copy);
2643 
2644 
2650 enum MHD_ResponseMemoryMode
2651 {
2652 
2659  MHD_RESPMEM_PERSISTENT,
2660 
2667  MHD_RESPMEM_MUST_FREE,
2668 
2676  MHD_RESPMEM_MUST_COPY
2677 
2678 };
2679 
2680 
2691 _MHD_EXTERN struct MHD_Response *
2692 MHD_create_response_from_buffer (size_t size,
2693  void *buffer,
2694  enum MHD_ResponseMemoryMode mode);
2695 
2696 
2708 _MHD_EXTERN struct MHD_Response *
2709 MHD_create_response_from_fd (size_t size,
2710  int fd);
2711 
2712 
2726 _MHD_EXTERN struct MHD_Response *
2727 MHD_create_response_from_fd64 (uint64_t size,
2728  int fd);
2729 
2730 
2747 _MHD_DEPR_FUNC("Function MHD_create_response_from_fd_at_offset() is deprecated, use MHD_create_response_from_fd_at_offset64()") \
2748 _MHD_EXTERN struct MHD_Response *
2750  int fd,
2751  off_t offset);
2752 
2753 #if !defined(_MHD_NO_DEPR_IN_MACRO) || defined(_MHD_NO_DEPR_FUNC)
2754 /* Substitute MHD_create_response_from_fd_at_offset64() instead of MHD_create_response_from_fd_at_offset()
2755  to minimize potential problems with different off_t sizes */
2756 #define MHD_create_response_from_fd_at_offset(size,fd,offset) \
2757  _MHD_DEPR_IN_MACRO("Usage of MHD_create_response_from_fd_at_offset() is deprecated, use MHD_create_response_from_fd_at_offset64()") \
2758  MHD_create_response_from_fd_at_offset64((size),(fd),(offset))
2759 #endif /* !_MHD_NO_DEPR_IN_MACRO || _MHD_NO_DEPR_FUNC */
2760 
2761 
2778 _MHD_EXTERN struct MHD_Response *
2780  int fd,
2781  uint64_t offset);
2782 
2783 
2790 enum MHD_UpgradeAction
2791 {
2792 
2798  MHD_UPGRADE_ACTION_CLOSE = 0
2799 
2800 };
2801 
2802 
2808 struct MHD_UpgradeResponseHandle;
2809 
2810 
2823 _MHD_EXTERN int
2824 MHD_upgrade_action (struct MHD_UpgradeResponseHandle *urh,
2825  enum MHD_UpgradeAction action,
2826  ...);
2827 
2828 
2876 typedef void
2877 (*MHD_UpgradeHandler)(void *cls,
2878  struct MHD_Connection *connection,
2879  void *con_cls,
2880  const char *extra_in,
2881  size_t extra_in_size,
2882  MHD_socket sock,
2883  struct MHD_UpgradeResponseHandle *urh);
2884 
2885 
2915 _MHD_EXTERN struct MHD_Response *
2916 MHD_create_response_for_upgrade (MHD_UpgradeHandler upgrade_handler,
2917  void *upgrade_handler_cls);
2918 
2919 
2929 _MHD_EXTERN void
2930 MHD_destroy_response (struct MHD_Response *response);
2931 
2932 
2943 _MHD_EXTERN int
2944 MHD_add_response_header (struct MHD_Response *response,
2945  const char *header,
2946  const char *content);
2947 
2948 
2958 _MHD_EXTERN int
2959 MHD_add_response_footer (struct MHD_Response *response,
2960  const char *footer,
2961  const char *content);
2962 
2963 
2973 _MHD_EXTERN int
2974 MHD_del_response_header (struct MHD_Response *response,
2975  const char *header,
2976  const char *content);
2977 
2978 
2989 _MHD_EXTERN int
2990 MHD_get_response_headers (struct MHD_Response *response,
2991  MHD_KeyValueIterator iterator, void *iterator_cls);
2992 
2993 
3002 _MHD_EXTERN const char *
3003 MHD_get_response_header (struct MHD_Response *response,
3004  const char *key);
3005 
3006 
3007 /* ********************** PostProcessor functions ********************** */
3008 
3034 _MHD_EXTERN struct MHD_PostProcessor *
3035 MHD_create_post_processor (struct MHD_Connection *connection,
3036  size_t buffer_size,
3037  MHD_PostDataIterator iter, void *iter_cls);
3038 
3039 
3053 _MHD_EXTERN int
3054 MHD_post_process (struct MHD_PostProcessor *pp,
3055  const char *post_data, size_t post_data_len);
3056 
3057 
3068 _MHD_EXTERN int
3069 MHD_destroy_post_processor (struct MHD_PostProcessor *pp);
3070 
3071 
3072 /* ********************* Digest Authentication functions *************** */
3073 
3074 
3080 #define MHD_INVALID_NONCE -1
3081 
3082 
3091 _MHD_EXTERN char *
3092 MHD_digest_auth_get_username (struct MHD_Connection *connection);
3093 
3094 
3108 _MHD_EXTERN int
3109 MHD_digest_auth_check (struct MHD_Connection *connection,
3110  const char *realm,
3111  const char *username,
3112  const char *password,
3113  unsigned int nonce_timeout);
3114 
3115 
3130 _MHD_EXTERN int
3131 MHD_queue_auth_fail_response (struct MHD_Connection *connection,
3132  const char *realm,
3133  const char *opaque,
3134  struct MHD_Response *response,
3135  int signal_stale);
3136 
3137 
3147 _MHD_EXTERN char *
3149  char** password);
3150 
3151 
3164 _MHD_EXTERN int
3166  const char *realm,
3167  struct MHD_Response *response);
3168 
3169 /* ********************** generic query functions ********************** */
3170 
3171 
3182 _MHD_EXTERN const union MHD_ConnectionInfo *
3183 MHD_get_connection_info (struct MHD_Connection *connection,
3184  enum MHD_ConnectionInfoType info_type,
3185  ...);
3186 
3187 
3192 enum MHD_CONNECTION_OPTION
3193 {
3194 
3202  MHD_CONNECTION_OPTION_TIMEOUT
3203 
3204 };
3205 
3206 
3216 _MHD_EXTERN int
3217 MHD_set_connection_option (struct MHD_Connection *connection,
3218  enum MHD_CONNECTION_OPTION option,
3219  ...);
3220 
3221 
3225 union MHD_DaemonInfo
3226 {
3231  size_t key_size;
3232 
3237  size_t mac_key_size;
3238 
3242  MHD_socket listen_fd;
3243 
3247  int epoll_fd;
3248 
3252  unsigned int num_connections;
3253 
3260  enum MHD_FLAG flags;
3261 };
3262 
3263 
3275 _MHD_EXTERN const union MHD_DaemonInfo *
3276 MHD_get_daemon_info (struct MHD_Daemon *daemon,
3277  enum MHD_DaemonInfoType info_type,
3278  ...);
3279 
3280 
3287 _MHD_EXTERN const char*
3288 MHD_get_version (void);
3289 
3290 
3295 enum MHD_FEATURE
3296 {
3301  MHD_FEATURE_MESSAGES = 1,
3302 
3310  MHD_FEATURE_TLS = 2,
3311  MHD_FEATURE_SSL = 2,
3312 
3317  MHD_FEATURE_HTTPS_CERT_CALLBACK = 3,
3318 
3323  MHD_FEATURE_IPv6 = 4,
3324 
3331  MHD_FEATURE_IPv6_ONLY = 5,
3332 
3337  MHD_FEATURE_POLL = 6,
3338 
3344  MHD_FEATURE_EPOLL = 7,
3345 
3351  MHD_FEATURE_SHUTDOWN_LISTEN_SOCKET = 8,
3352 
3357  MHD_FEATURE_SOCKETPAIR = 9,
3358 
3364  MHD_FEATURE_TCP_FASTOPEN = 10,
3365 
3371  MHD_FEATURE_BASIC_AUTH = 11,
3372 
3379  MHD_FEATURE_DIGEST_AUTH = 12,
3380 
3387  MHD_FEATURE_POSTPROCESSOR = 13,
3388 
3394  MHD_FEATURE_HTTPS_KEY_PASSWORD = 14,
3395 
3404  MHD_FEATURE_LARGE_FILE = 15,
3405 
3409  MHD_FEATURE_THREAD_NAMES = 16,
3410  MHD_THREAD_NAMES = 16,
3411 
3417  MHD_FEATURE_UPGRADE = 17,
3418 
3430  MHD_FEATURE_RESPONSES_SHARED_FD = 18
3431 };
3432 
3433 
3445 _MHD_EXTERN int
3446 MHD_is_feature_supported (enum MHD_FEATURE feature);
3447 
3448 
3449 #if 0 /* keep Emacsens' auto-indent happy */
3450 {
3451 #endif
3452 #ifdef __cplusplus
3453 }
3454 #endif
3455 
3456 #endif
#define _MHD_DEPR_FUNC(msg)
Definition: microhttpd.h:264
int(* MHD_KeyValueIterator)(void *cls, enum MHD_ValueKind kind, const char *key, const char *value)
Definition: microhttpd.h:1992
int MHD_set_response_options(struct MHD_Response *response, enum MHD_ResponseFlags flags,...)
Definition: response.c:341
_MHD_EXTERN struct MHD_Daemon * MHD_start_daemon_va(unsigned int flags, uint16_t port, MHD_AcceptPolicyCallback apc, void *apc_cls, MHD_AccessHandlerCallback dh, void *dh_cls, va_list ap)
Definition: daemon.c:5360
void * socket_context
Definition: internal.h:683
int MHD_add_response_header(struct MHD_Response *response, const char *header, const char *content)
Definition: response.c:118
_MHD_EXTERN struct MHD_Response * MHD_create_response_from_fd64(uint64_t size, int fd)
Definition: response.c:580
MHD_ContentReaderFreeCallback crfc
Definition: internal.h:318
int MHD_get_timeout(struct MHD_Daemon *daemon, MHD_UNSIGNED_LONG_LONG *timeout)
Definition: daemon.c:3270
void(* MHD_ContentReaderFreeCallback)(void *cls)
Definition: microhttpd.h:2059
char * version
Definition: internal.h:700
_MHD_EXTERN int MHD_add_connection(struct MHD_Daemon *daemon, MHD_socket client_socket, const struct sockaddr *addr, socklen_t addrlen)
Definition: daemon.c:2996
int(* MHD_PostDataIterator)(void *cls, enum MHD_ValueKind kind, const char *key, const char *filename, const char *content_type, const char *transfer_encoding, const char *data, uint64_t off, size_t size)
Definition: microhttpd.h:2082
const char * MHD_get_response_header(struct MHD_Response *response, const char *key)
Definition: response.c:236
int MHD_queue_basic_auth_fail_response(struct MHD_Connection *connection, const char *realm, struct MHD_Response *response)
Definition: basicauth.c:120
MHD_RequestTerminationCode
Definition: microhttpd.h:1574
int MHD_destroy_post_processor(struct MHD_PostProcessor *pp)
MHD_socket connect_fd
Definition: microhttpd.h:1681
int MHD_digest_auth_check(struct MHD_Connection *connection, const char *realm, const char *username, const char *password, unsigned int nonce_timeout)
Definition: digestauth.c:672
int MHD_socket
Definition: microhttpd.h:181
void MHD_suspend_connection(struct MHD_Connection *connection)
Definition: daemon.c:2800
_MHD_EXTERN struct MHD_Daemon * MHD_start_daemon(unsigned int flags, uint16_t port, MHD_AcceptPolicyCallback apc, void *apc_cls, MHD_AccessHandlerCallback dh, void *dh_cls,...)
Definition: daemon.c:4622
intptr_t value
Definition: microhttpd.h:1509
MHD_ConnectionNotificationCode
Definition: microhttpd.h:1632
void MHD_set_panic_func(MHD_PanicCallback cb, void *cls)
Definition: daemon.c:6521
#define MHD_UNSIGNED_LONG_LONG
Definition: microhttpd.h:277
void(* MHD_PanicCallback)(void *cls, const char *file, unsigned int line, const char *reason)
Definition: microhttpd.h:1863
void(* MHD_LogCallback)(void *cls, const char *fm, va_list ap)
Definition: microhttpd.h:1158
char * MHD_basic_auth_get_username_password(struct MHD_Connection *connection, char **password)
Definition: basicauth.c:47
struct MHD_Response * MHD_create_response_from_callback(uint64_t size, size_t block_size, MHD_ContentReaderCallback crc, void *crc_cls, MHD_ContentReaderFreeCallback crfc)
Definition: response.c:303
struct MHD_Response * MHD_create_response_from_buffer(size_t size, void *buffer, enum MHD_ResponseMemoryMode mode)
Definition: response.c:658
_MHD_EXTERN void MHD_stop_daemon(struct MHD_Daemon *daemon)
Definition: daemon.c:6315
const char * url
Definition: internal.h:694
int MHD_queue_auth_fail_response(struct MHD_Connection *connection, const char *realm, const char *opaque, struct MHD_Response *response, int signal_stale)
Definition: digestauth.c:946
int MHD_add_response_footer(struct MHD_Response *response, const char *footer, const char *content)
Definition: response.c:139
char * method
Definition: internal.h:688
#define _MHD_EXTERN
Definition: microhttpd.h:171
struct MHD_PostProcessor * MHD_create_post_processor(struct MHD_Connection *connection, size_t buffer_size, MHD_PostDataIterator iter, void *iter_cls)
int MHD_run_from_select(struct MHD_Daemon *daemon, const fd_set *read_fd_set, const fd_set *write_fd_set, const fd_set *except_fd_set)
Definition: daemon.c:3463
ssize_t(* MHD_ContentReaderCallback)(void *cls, uint64_t pos, char *buf, size_t max)
Definition: microhttpd.h:2043
void MHD_destroy_response(struct MHD_Response *response)
Definition: response.c:1056
int MHD_set_connection_option(struct MHD_Connection *connection, enum MHD_CONNECTION_OPTION option,...)
Definition: connection.c:3516
const char * MHD_lookup_connection_value(struct MHD_Connection *connection, enum MHD_ValueKind kind, const char *key)
Definition: connection.c:450
uint16_t port
Definition: internal.h:1583
struct MHD_Response * MHD_create_response_from_data(size_t size, void *data, int must_free, int must_copy)
Definition: response.c:604
MHD_ValueKind
Definition: microhttpd.h:1524
const union MHD_ConnectionInfo * MHD_get_connection_info(struct MHD_Connection *connection, enum MHD_ConnectionInfoType info_type,...)
Definition: connection.c:3458
struct MHD_Daemon * daemon
Definition: microhttpd.h:1707
int MHD_post_process(struct MHD_PostProcessor *pp, const char *post_data, size_t post_data_len)
MHD_ConnectionInfoType
Definition: microhttpd.h:1722
int MHD_queue_response(struct MHD_Connection *connection, unsigned int status_code, struct MHD_Response *response)
Definition: connection.c:3579
unsigned int connection_timeout
Definition: microhttpd.h:1676
_MHD_EXTERN struct MHD_Response * MHD_create_response_from_fd_at_offset64(uint64_t size, int fd, uint64_t offset)
Definition: response.c:515
MHD_AcceptPolicyCallback apc
Definition: internal.h:1350
int(* MHD_AccessHandlerCallback)(void *cls, struct MHD_Connection *connection, const char *url, const char *method, const char *version, const char *upload_data, size_t *upload_data_size, void **con_cls)
Definition: microhttpd.h:1922
char * MHD_digest_auth_get_username(struct MHD_Connection *connection)
Definition: digestauth.c:467
const union MHD_DaemonInfo * MHD_get_daemon_info(struct MHD_Daemon *daemon, enum MHD_DaemonInfoType info_type,...)
Definition: daemon.c:6459
int MHD_get_fdset(struct MHD_Daemon *daemon, fd_set *read_fd_set, fd_set *write_fd_set, fd_set *except_fd_set, MHD_socket *max_fd)
Definition: daemon.c:678
void * ptr_value
Definition: microhttpd.h:1515
void(* MHD_RequestCompletedCallback)(void *cls, struct MHD_Connection *connection, void **con_cls, enum MHD_RequestTerminationCode toe)
Definition: microhttpd.h:1945
int MHD_get_connection_values(struct MHD_Connection *connection, enum MHD_ValueKind kind, MHD_KeyValueIterator iterator, void *iterator_cls)
Definition: connection.c:356
int MHD_run(struct MHD_Daemon *daemon)
Definition: daemon.c:4481
MHD_OPTION
MHD options.
Definition: microhttpd.h:1168
void * apc_cls
Definition: internal.h:1355
MHD_ContentReaderCallback crc
Definition: internal.h:312
void * crc_cls
Definition: internal.h:306
MHD_DaemonInfoType
Definition: microhttpd.h:1808
void MHD_resume_connection(struct MHD_Connection *connection)
Definition: daemon.c:2829
const char * MHD_get_version(void)
Definition: daemon.c:6536
_MHD_EXTERN int MHD_is_feature_supported(enum MHD_FEATURE feature)
Definition: daemon.c:6570
struct sockaddr * client_addr
Definition: microhttpd.h:1701
int MHD_del_response_header(struct MHD_Response *response, const char *header, const char *content)
Definition: response.c:160
#define _MHD_DEPR_MACRO(msg)
Definition: microhttpd.h:235
int MHD_get_fdset2(struct MHD_Daemon *daemon, fd_set *read_fd_set, fd_set *write_fd_set, fd_set *except_fd_set, MHD_socket *max_fd, unsigned int fd_setsize)
Definition: daemon.c:1068
struct MHD_Response * MHD_create_response_from_fd(size_t size, int fd)
Definition: response.c:557
_MHD_EXTERN MHD_socket MHD_quiesce_daemon(struct MHD_Daemon *daemon)
Definition: daemon.c:4667
int(* MHD_AcceptPolicyCallback)(void *cls, const struct sockaddr *addr, socklen_t addrlen)
Definition: microhttpd.h:1877
void(* MHD_NotifyConnectionCallback)(void *cls, struct MHD_Connection *connection, void **socket_context, enum MHD_ConnectionNotificationCode toe)
Definition: microhttpd.h:1970
_MHD_EXTERN const char * MHD_get_reason_phrase_for(unsigned int code)
enum MHD_OPTION option
Definition: microhttpd.h:1502
struct MHD_Response * MHD_create_response_from_fd_at_offset(size_t size, int fd, off_t offset)
Definition: response.c:488
size_t MHD_http_unescape(char *val)
Definition: internal.c:138
int MHD_set_connection_value(struct MHD_Connection *connection, enum MHD_ValueKind kind, const char *key, const char *value)
Definition: connection.c:408
MHD_FLAG
Flags for the struct MHD_Daemon.
Definition: microhttpd.h:882
#define MHD_RESPONSE_HEADER_KIND
Definition: microhttpd.h:1532
int MHD_get_response_headers(struct MHD_Response *response, MHD_KeyValueIterator iterator, void *iterator_cls)
Definition: response.c:206