1 /* 2 * http_cgi - Common Gateway Interface (CGI) interfaces (RFC 3875) 3 * 4 * Copyright(c) 2016-2017 Glenn Strauss gstrauss()gluelogic.com All rights reserved 5 * License: BSD 3-clause (same as lighttpd) 6 */ 7 #ifndef INCLUDED_HTTP_CGI_H 8 #define INCLUDED_HTTP_CGI_H 9 #include "first.h" 10 11 #include "base_decls.h" 12 #include "buffer.h" 13 14 typedef struct http_cgi_opts_t { 15 int authorizer; 16 int break_scriptfilename_for_php; 17 const buffer *docroot; 18 const buffer *strip_request_uri; 19 } http_cgi_opts; 20 21 typedef int (*http_cgi_header_append_cb)(void *vdata, const char *k, size_t klen, const char *v, size_t vlen); 22 23 int http_cgi_headers (request_st *r, http_cgi_opts *opts, http_cgi_header_append_cb cb, void *vdata); 24 25 handler_t http_cgi_local_redir (request_st *r); 26 27 #endif 28