2017-08-08 17:51:36 +02:00
|
|
|
/* Copyright (c) 2001 Matej Pfajfar.
|
|
|
|
* Copyright (c) 2001-2004, Roger Dingledine.
|
|
|
|
* Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
|
2018-06-20 14:13:28 +02:00
|
|
|
* Copyright (c) 2007-2018, The Tor Project, Inc. */
|
2017-08-08 17:51:36 +02:00
|
|
|
/* See LICENSE for licensing information */
|
|
|
|
|
|
|
|
#ifndef TOR_PROTO_HTTP_H
|
|
|
|
#define TOR_PROTO_HTTP_H
|
|
|
|
|
|
|
|
struct buf_t;
|
|
|
|
|
|
|
|
int fetch_from_buf_http(struct buf_t *buf,
|
|
|
|
char **headers_out, size_t max_headerlen,
|
|
|
|
char **body_out, size_t *body_used, size_t max_bodylen,
|
|
|
|
int force_complete);
|
|
|
|
int peek_buf_has_http_command(const struct buf_t *buf);
|
|
|
|
|
|
|
|
#ifdef PROTO_HTTP_PRIVATE
|
|
|
|
STATIC int buf_http_find_content_length(const char *headers, size_t headerlen,
|
|
|
|
size_t *result_out);
|
|
|
|
#endif
|
|
|
|
|
2017-09-15 22:24:44 +02:00
|
|
|
#endif /* !defined(TOR_PROTO_HTTP_H) */
|
2017-08-08 17:51:36 +02:00
|
|
|
|