HTP
0.5
Main Page
Data Structures
Files
File List
Globals
htp
htp_connection_parser_private.h
Go to the documentation of this file.
1
/***************************************************************************
2
* Copyright (c) 2009-2010 Open Information Security Foundation
3
* Copyright (c) 2010-2013 Qualys, Inc.
4
* All rights reserved.
5
*
6
* Redistribution and use in source and binary forms, with or without
7
* modification, are permitted provided that the following conditions are
8
* met:
9
*
10
* - Redistributions of source code must retain the above copyright
11
* notice, this list of conditions and the following disclaimer.
12
13
* - Redistributions in binary form must reproduce the above copyright
14
* notice, this list of conditions and the following disclaimer in the
15
* documentation and/or other materials provided with the distribution.
16
17
* - Neither the name of the Qualys, Inc. nor the names of its
18
* contributors may be used to endorse or promote products derived from
19
* this software without specific prior written permission.
20
*
21
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
24
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
25
* HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
26
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
27
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32
***************************************************************************/
33
39
#ifndef HTP_CONNECTION_PARSER_PRIVATE_H
40
#define HTP_CONNECTION_PARSER_PRIVATE_H
41
42
#ifdef __cplusplus
43
extern
"C"
{
44
#endif
45
46
#include "
htp_core.h
"
47
51
struct
htp_connp_t
{
52
53
// General fields
54
56
htp_cfg_t
*
cfg
;
57
59
htp_conn_t
*
conn
;
60
62
const
void
*
user_data
;
63
69
htp_log_t
*
last_error
;
70
71
72
// Request parser fields
73
75
enum
htp_stream_state_t
in_status
;
76
78
enum
htp_stream_state_t
out_status
;
79
85
unsigned
int
out_data_other_at_tx_end
;
86
91
htp_time_t
in_timestamp
;
92
94
unsigned
char
*
in_current_data
;
95
97
int64_t
in_current_len
;
98
100
int64_t
in_current_read_offset
;
101
106
int64_t
in_current_consume_offset
;
107
113
int64_t
in_current_receiver_offset
;
114
116
size_t
in_chunk_count
;
117
119
size_t
in_chunk_request_index
;
120
122
int64_t
in_stream_offset
;
123
128
int
in_next_byte
;
129
131
unsigned
char
*
in_buf
;
132
134
size_t
in_buf_size
;
135
140
bstr
*
in_header
;
141
143
htp_tx_t
*
in_tx
;
144
150
int64_t
in_content_length
;
151
157
int64_t
in_body_data_left
;
158
163
int64_t
in_chunked_length
;
164
166
int (*
in_state
)(
htp_connp_t
*);
167
169
int (*
in_state_previous
)(
htp_connp_t
*);
170
172
htp_hook_t
*
in_data_receiver_hook
;
173
174
// Response parser fields
175
181
size_t
out_next_tx_index
;
182
184
htp_time_t
out_timestamp
;
185
187
unsigned
char
*
out_current_data
;
188
190
int64_t
out_current_len
;
191
193
int64_t
out_current_read_offset
;
194
199
int64_t
out_current_consume_offset
;
200
206
int64_t
out_current_receiver_offset
;
207
209
int64_t
out_stream_offset
;
210
212
int
out_next_byte
;
213
215
unsigned
char
*
out_buf
;
216
218
size_t
out_buf_size
;
219
224
bstr
*
out_header
;
225
227
htp_tx_t
*
out_tx
;
228
233
int64_t
out_content_length
;
234
236
int64_t
out_body_data_left
;
237
242
int64_t
out_chunked_length
;
243
245
int (*
out_state
)(
htp_connp_t
*);
246
248
int (*
out_state_previous
)(
htp_connp_t
*);
249
251
htp_hook_t
*
out_data_receiver_hook
;
252
254
htp_decompressor_t
*
out_decompressor
;
255
257
htp_file_t
*
put_file
;
258
};
259
265
void
htp_connp_in_reset
(
htp_connp_t
*connp);
266
267
#ifdef __cplusplus
268
}
269
#endif
270
271
#endif
/* HTP_CONNECTION_PARSER_PRIVATE_H */
272
Generated by
1.8.4