mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-01-03 02:32:03 +00:00
REORG: include: move sample.h to haproxy/sample{,-t}.h
This one is particularly tricky to move because everyone uses it and it depends on a lot of other types. For example it cannot include arg-t.h and must absolutely only rely on forward declarations to avoid dependency loops between vars -> sample_data -> arg. In order to address this one, it would be nice to split the sample_data part out of sample.h.
This commit is contained in:
parent
469509b39e
commit
e6ce10be85
@ -12,7 +12,7 @@
|
|||||||
#ifndef __DEFENDER_H__
|
#ifndef __DEFENDER_H__
|
||||||
#define __DEFENDER_H__
|
#define __DEFENDER_H__
|
||||||
|
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
struct defender_request {
|
struct defender_request {
|
||||||
struct sample clientip;
|
struct sample clientip;
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
#include <haproxy/compression.h>
|
#include <haproxy/compression.h>
|
||||||
#include <haproxy/pipe.h>
|
#include <haproxy/pipe.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/ssl_sock.h>
|
#include <proto/ssl_sock.h>
|
||||||
#include <proto/stats.h>
|
#include <proto/stats.h>
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
#include <haproxy/auth-t.h>
|
#include <haproxy/auth-t.h>
|
||||||
#include <haproxy/api.h>
|
#include <haproxy/api.h>
|
||||||
#include <haproxy/pattern-t.h>
|
#include <haproxy/pattern-t.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
extern struct userlist *userlist;
|
extern struct userlist *userlist;
|
||||||
|
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
#define _HAPROXY_MAP_T_H
|
#define _HAPROXY_MAP_T_H
|
||||||
|
|
||||||
#include <haproxy/pattern-t.h>
|
#include <haproxy/pattern-t.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
struct map_descriptor {
|
struct map_descriptor {
|
||||||
struct sample_conv *conv; /* original converter descriptor */
|
struct sample_conv *conv; /* original converter descriptor */
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
#define _HAPROXY_MAP_H
|
#define _HAPROXY_MAP_H
|
||||||
|
|
||||||
#include <haproxy/map-t.h>
|
#include <haproxy/map-t.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
/* maps output sample parser */
|
/* maps output sample parser */
|
||||||
int map_parse_ip(const char *text, struct sample_data *data);
|
int map_parse_ip(const char *text, struct sample_data *data);
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
#include <haproxy/thread-t.h>
|
#include <haproxy/thread-t.h>
|
||||||
#include <haproxy/api-t.h>
|
#include <haproxy/api-t.h>
|
||||||
|
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
|
|
||||||
/* Pattern matching function result.
|
/* Pattern matching function result.
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
#define _HAPROXY_PAYLOAD_H
|
#define _HAPROXY_PAYLOAD_H
|
||||||
|
|
||||||
#include <haproxy/api.h>
|
#include <haproxy/api.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
#include <types/stream.h>
|
#include <types/stream.h>
|
||||||
|
|
||||||
int fetch_rdp_cookie_name(struct stream *s, struct sample *smp, const char *cname, int clen);
|
int fetch_rdp_cookie_name(struct stream *s, struct sample *smp, const char *cname, int clen);
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* include/types/sample.h
|
* include/haproxy/sample-t.h
|
||||||
* Macros, variables and structures for sample management.
|
* Macros, variables and structures for sample management.
|
||||||
*
|
*
|
||||||
* Copyright (C) 2009-2010 EXCELIANCE, Emeric Brun <ebrun@exceliance.fr>
|
* Copyright (C) 2009-2010 EXCELIANCE, Emeric Brun <ebrun@exceliance.fr>
|
||||||
@ -20,18 +20,17 @@
|
|||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _TYPES_SAMPLE_H
|
#ifndef _HAPROXY_SAMPLE_T_H
|
||||||
#define _TYPES_SAMPLE_H
|
#define _HAPROXY_SAMPLE_T_H
|
||||||
|
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
#include <netinet/in.h>
|
#include <netinet/in.h>
|
||||||
|
|
||||||
|
#include <haproxy/api-t.h>
|
||||||
#include <haproxy/buf-t.h>
|
#include <haproxy/buf-t.h>
|
||||||
#include <haproxy/http-t.h>
|
#include <haproxy/http-t.h>
|
||||||
#include <haproxy/list-t.h>
|
#include <haproxy/list-t.h>
|
||||||
|
|
||||||
struct arg;
|
|
||||||
|
|
||||||
/* input and output sample types */
|
/* input and output sample types */
|
||||||
enum {
|
enum {
|
||||||
SMP_T_ANY = 0, /* any type */
|
SMP_T_ANY = 0, /* any type */
|
||||||
@ -179,8 +178,6 @@ enum {
|
|||||||
SMP_VAL_BE_CHK_RUL,
|
SMP_VAL_BE_CHK_RUL,
|
||||||
};
|
};
|
||||||
|
|
||||||
extern const unsigned int fetch_cap[SMP_SRC_ENTRIES];
|
|
||||||
|
|
||||||
/* Sample fetch options are passed to sample fetch functions to add precision
|
/* Sample fetch options are passed to sample fetch functions to add precision
|
||||||
* about what is desired :
|
* about what is desired :
|
||||||
* - fetch direction (req/resp)
|
* - fetch direction (req/resp)
|
||||||
@ -213,6 +210,7 @@ enum {
|
|||||||
/* needed below */
|
/* needed below */
|
||||||
struct session;
|
struct session;
|
||||||
struct stream;
|
struct stream;
|
||||||
|
struct arg;
|
||||||
|
|
||||||
/* a sample context might be used by any sample fetch function in order to
|
/* a sample context might be used by any sample fetch function in order to
|
||||||
* store information needed across multiple calls (eg: restart point for a
|
* store information needed across multiple calls (eg: restart point for a
|
||||||
@ -326,6 +324,5 @@ struct sample_conv_kw_list {
|
|||||||
};
|
};
|
||||||
|
|
||||||
typedef int (*sample_cast_fct)(struct sample *smp);
|
typedef int (*sample_cast_fct)(struct sample *smp);
|
||||||
extern sample_cast_fct sample_casts[SMP_TYPES][SMP_TYPES];
|
|
||||||
|
|
||||||
#endif /* _TYPES_SAMPLE_H */
|
#endif /* _HAPROXY_SAMPLE_T_H */
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* include/proto/sample.h
|
* include/haproxy/sample.h
|
||||||
* Functions for samples management.
|
* Functions for samples management.
|
||||||
*
|
*
|
||||||
* Copyright (C) 2009-2010 EXCELIANCE, Emeric Brun <ebrun@exceliance.fr>
|
* Copyright (C) 2009-2010 EXCELIANCE, Emeric Brun <ebrun@exceliance.fr>
|
||||||
@ -20,12 +20,16 @@
|
|||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _PROTO_SAMPLE_H
|
#ifndef _HAPROXY_SAMPLE_H
|
||||||
#define _PROTO_SAMPLE_H
|
#define _HAPROXY_SAMPLE_H
|
||||||
|
|
||||||
#include <types/sample.h>
|
#include <haproxy/arg-t.h>
|
||||||
|
#include <haproxy/api.h>
|
||||||
|
#include <haproxy/sample-t.h>
|
||||||
#include <types/stick_table.h>
|
#include <types/stick_table.h>
|
||||||
|
|
||||||
|
extern sample_cast_fct sample_casts[SMP_TYPES][SMP_TYPES];
|
||||||
|
extern const unsigned int fetch_cap[SMP_SRC_ENTRIES];
|
||||||
extern const char *smp_to_type[SMP_TYPES];
|
extern const char *smp_to_type[SMP_TYPES];
|
||||||
|
|
||||||
struct sample_expr *sample_parse_expr(char **str, int *idx, const char *file, int line, char **err, struct arg_list *al, char **endptr);
|
struct sample_expr *sample_parse_expr(char **str, int *idx, const char *file, int line, char **err, struct arg_list *al, char **endptr);
|
||||||
@ -170,4 +174,4 @@ int smp_make_rw(struct sample *smp)
|
|||||||
return smp && (smp_is_rw(smp) || smp_dup(smp));
|
return smp && (smp_is_rw(smp) || smp_dup(smp));
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* _PROTO_SAMPLE_H */
|
#endif /* _HAPROXY_SAMPLE_H */
|
@ -24,7 +24,6 @@
|
|||||||
|
|
||||||
#include <haproxy/api.h>
|
#include <haproxy/api.h>
|
||||||
#include <types/acl.h>
|
#include <types/acl.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* FIXME: we need destructor functions too !
|
* FIXME: we need destructor functions too !
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
#include <haproxy/arg-t.h>
|
#include <haproxy/arg-t.h>
|
||||||
#include <types/channel.h>
|
#include <types/channel.h>
|
||||||
#include <types/checks.h>
|
#include <types/checks.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
struct htx *smp_prefetch_htx(struct sample *smp, struct channel *chn, struct check *check, int vol);
|
struct htx *smp_prefetch_htx(struct sample *smp, struct channel *chn, struct check *check, int vol);
|
||||||
int val_hdr(struct arg *arg, char **err_msg);
|
int val_hdr(struct arg *arg, char **err_msg);
|
||||||
|
@ -24,8 +24,8 @@
|
|||||||
|
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
#include <haproxy/arg-t.h>
|
#include <haproxy/arg-t.h>
|
||||||
|
#include <haproxy/sample-t.h>
|
||||||
#include <types/protocol_buffers.h>
|
#include <types/protocol_buffers.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
|
|
||||||
#define PBUF_VARINT_DONT_STOP_BIT 7
|
#define PBUF_VARINT_DONT_STOP_BIT 7
|
||||||
#define PBUF_VARINT_DONT_STOP_BITMASK (1 << PBUF_VARINT_DONT_STOP_BIT)
|
#define PBUF_VARINT_DONT_STOP_BITMASK (1 << PBUF_VARINT_DONT_STOP_BIT)
|
||||||
|
@ -23,11 +23,10 @@
|
|||||||
#define _PROTO_SPOE_H
|
#define _PROTO_SPOE_H
|
||||||
|
|
||||||
#include <haproxy/intops.h>
|
#include <haproxy/intops.h>
|
||||||
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
#include <types/spoe.h>
|
#include <types/spoe.h>
|
||||||
|
|
||||||
#include <proto/sample.h>
|
|
||||||
|
|
||||||
|
|
||||||
/* Encode a buffer. Its length <len> is encoded as a varint, followed by a copy
|
/* Encode a buffer. Its length <len> is encoded as a varint, followed by a copy
|
||||||
* of <str>. It must have enough space in <*buf> to encode the buffer, else an
|
* of <str>. It must have enough space in <*buf> to encode the buffer, else an
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
|
|
||||||
#include <types/connection.h>
|
#include <types/connection.h>
|
||||||
#include <types/proxy.h>
|
#include <types/proxy.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
#include <types/server.h>
|
#include <types/server.h>
|
||||||
#include <types/session.h>
|
#include <types/session.h>
|
||||||
#include <types/task.h>
|
#include <types/task.h>
|
||||||
|
@ -68,6 +68,7 @@ struct pbuf_fid {
|
|||||||
size_t sz;
|
size_t sz;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
struct sample;
|
||||||
struct protobuf_parser_def {
|
struct protobuf_parser_def {
|
||||||
int (*skip)(unsigned char **pos, size_t *left, size_t vlen);
|
int (*skip)(unsigned char **pos, size_t *left, size_t vlen);
|
||||||
int (*smp_store)(struct sample *, int type,
|
int (*smp_store)(struct sample *, int type,
|
||||||
|
@ -44,7 +44,7 @@
|
|||||||
#include <types/filters.h>
|
#include <types/filters.h>
|
||||||
#include <haproxy/freq_ctr-t.h>
|
#include <haproxy/freq_ctr-t.h>
|
||||||
#include <types/log.h>
|
#include <types/log.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
#include <types/server.h>
|
#include <types/server.h>
|
||||||
#include <types/stick_table.h>
|
#include <types/stick_table.h>
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@
|
|||||||
#include <haproxy/freq_ctr-t.h>
|
#include <haproxy/freq_ctr-t.h>
|
||||||
#include <types/log.h>
|
#include <types/log.h>
|
||||||
#include <types/proxy.h>
|
#include <types/proxy.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
#include <types/stream.h>
|
#include <types/stream.h>
|
||||||
#include <types/task.h>
|
#include <types/task.h>
|
||||||
|
|
||||||
|
@ -33,7 +33,7 @@
|
|||||||
#include <haproxy/pool-t.h>
|
#include <haproxy/pool-t.h>
|
||||||
#include <haproxy/freq_ctr-t.h>
|
#include <haproxy/freq_ctr-t.h>
|
||||||
#include <types/peers.h>
|
#include <types/peers.h>
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
/* The types of extra data we can store in a stick table */
|
/* The types of extra data we can store in a stick table */
|
||||||
enum {
|
enum {
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
#include <haproxy/list-t.h>
|
#include <haproxy/list-t.h>
|
||||||
#include <haproxy/thread.h>
|
#include <haproxy/thread.h>
|
||||||
|
|
||||||
#include <types/sample.h>
|
#include <haproxy/sample-t.h>
|
||||||
|
|
||||||
enum vars_scope {
|
enum vars_scope {
|
||||||
SCOPE_SESS = 0,
|
SCOPE_SESS = 0,
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
#include <proto/http_fetch.h>
|
#include <proto/http_fetch.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <import/xxhash.h>
|
#include <import/xxhash.h>
|
||||||
#include <import/lru.h>
|
#include <import/lru.h>
|
||||||
#include <51Degrees.h>
|
#include <51Degrees.h>
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
#include <proto/channel.h>
|
#include <proto/channel.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <proto/stick_table.h>
|
#include <proto/stick_table.h>
|
||||||
|
|
||||||
#include <import/ebsttree.h>
|
#include <import/ebsttree.h>
|
||||||
|
@ -49,7 +49,7 @@
|
|||||||
#include <proto/proto_tcp.h>
|
#include <proto/proto_tcp.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/queue.h>
|
#include <proto/queue.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/session.h>
|
#include <proto/session.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
#include <haproxy/http_htx.h>
|
#include <haproxy/http_htx.h>
|
||||||
#include <haproxy/http_rules.h>
|
#include <haproxy/http_rules.h>
|
||||||
#include <haproxy/listener.h>
|
#include <haproxy/listener.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <types/stats.h>
|
#include <types/stats.h>
|
||||||
|
|
||||||
#include <proto/acl.h>
|
#include <proto/acl.h>
|
||||||
|
@ -74,7 +74,7 @@
|
|||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/peers.h>
|
#include <proto/peers.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <proto/session.h>
|
#include <proto/session.h>
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
|
@ -68,7 +68,7 @@
|
|||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <haproxy/proto_udp.h>
|
#include <haproxy/proto_udp.h>
|
||||||
#include <proto/ssl_sock.h>
|
#include <proto/ssl_sock.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
|
|
||||||
static int tcpcheck_get_step_id(struct check *, struct tcpcheck_rule *);
|
static int tcpcheck_get_step_id(struct check *, struct tcpcheck_rule *);
|
||||||
|
|
||||||
|
@ -34,6 +34,7 @@
|
|||||||
#include <haproxy/listener.h>
|
#include <haproxy/listener.h>
|
||||||
#include <haproxy/mworker-t.h>
|
#include <haproxy/mworker-t.h>
|
||||||
#include <haproxy/pattern-t.h>
|
#include <haproxy/pattern-t.h>
|
||||||
|
#include <haproxy/sample-t.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <haproxy/ticks.h>
|
#include <haproxy/ticks.h>
|
||||||
#include <haproxy/time.h>
|
#include <haproxy/time.h>
|
||||||
@ -58,7 +59,6 @@
|
|||||||
#include <haproxy/pipe.h>
|
#include <haproxy/pipe.h>
|
||||||
#include <haproxy/protocol.h>
|
#include <haproxy/protocol.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/session.h>
|
#include <proto/session.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
#include <haproxy/fd.h>
|
#include <haproxy/fd.h>
|
||||||
#include <proto/proto_tcp.h>
|
#include <proto/proto_tcp.h>
|
||||||
#include <proto/stream_interface.h>
|
#include <proto/stream_interface.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <proto/ssl_sock.h>
|
#include <proto/ssl_sock.h>
|
||||||
|
|
||||||
|
|
||||||
|
2
src/da.c
2
src/da.c
@ -10,7 +10,7 @@
|
|||||||
#include <proto/http_fetch.h>
|
#include <proto/http_fetch.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <dac.h>
|
#include <dac.h>
|
||||||
|
|
||||||
static struct {
|
static struct {
|
||||||
|
@ -25,6 +25,7 @@
|
|||||||
#include <haproxy/dns.h>
|
#include <haproxy/dns.h>
|
||||||
#include <haproxy/errors.h>
|
#include <haproxy/errors.h>
|
||||||
#include <haproxy/http_rules.h>
|
#include <haproxy/http_rules.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/time.h>
|
#include <haproxy/time.h>
|
||||||
#include <haproxy/ticks.h>
|
#include <haproxy/ticks.h>
|
||||||
#include <haproxy/net_helper.h>
|
#include <haproxy/net_helper.h>
|
||||||
@ -40,7 +41,6 @@
|
|||||||
#include <haproxy/fd.h>
|
#include <haproxy/fd.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/task.h>
|
#include <proto/task.h>
|
||||||
#include <haproxy/proto_udp.h>
|
#include <haproxy/proto_udp.h>
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
#include <haproxy/errors.h>
|
#include <haproxy/errors.h>
|
||||||
#include <haproxy/http_htx.h>
|
#include <haproxy/http_htx.h>
|
||||||
#include <haproxy/regex.h>
|
#include <haproxy/regex.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
|
|
||||||
#include <types/global.h>
|
#include <types/global.h>
|
||||||
@ -26,7 +27,6 @@
|
|||||||
#include <proto/http_fetch.h>
|
#include <proto/http_fetch.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/session.h>
|
#include <proto/session.h>
|
||||||
|
|
||||||
|
@ -18,15 +18,14 @@
|
|||||||
#include <common/cfgparse.h>
|
#include <common/cfgparse.h>
|
||||||
#include <haproxy/htx.h>
|
#include <haproxy/htx.h>
|
||||||
#include <haproxy/list.h>
|
#include <haproxy/list.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
|
|
||||||
#include <types/filters.h>
|
#include <types/filters.h>
|
||||||
#include <types/proxy.h>
|
#include <types/proxy.h>
|
||||||
#include <types/sample.h>
|
|
||||||
|
|
||||||
#include <proto/filters.h>
|
#include <proto/filters.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
|
|
||||||
const char *http_comp_flt_id = "compression filter";
|
const char *http_comp_flt_id = "compression filter";
|
||||||
|
@ -17,6 +17,7 @@
|
|||||||
#include <common/cfgparse.h>
|
#include <common/cfgparse.h>
|
||||||
#include <haproxy/frontend.h>
|
#include <haproxy/frontend.h>
|
||||||
#include <haproxy/http_rules.h>
|
#include <haproxy/http_rules.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/thread.h>
|
#include <haproxy/thread.h>
|
||||||
#include <haproxy/pool.h>
|
#include <haproxy/pool.h>
|
||||||
#include <haproxy/time.h>
|
#include <haproxy/time.h>
|
||||||
@ -33,7 +34,6 @@
|
|||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/session.h>
|
#include <proto/session.h>
|
||||||
#include <proto/signal.h>
|
#include <proto/signal.h>
|
||||||
#include <proto/spoe.h>
|
#include <proto/spoe.h>
|
||||||
|
@ -25,6 +25,7 @@
|
|||||||
#include <haproxy/api.h>
|
#include <haproxy/api.h>
|
||||||
#include <haproxy/chunk.h>
|
#include <haproxy/chunk.h>
|
||||||
#include <haproxy/frontend.h>
|
#include <haproxy/frontend.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <haproxy/time.h>
|
#include <haproxy/time.h>
|
||||||
|
|
||||||
@ -38,7 +39,6 @@
|
|||||||
#include <proto/proto_tcp.h>
|
#include <proto/proto_tcp.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
#include <proto/stream_interface.h>
|
#include <proto/stream_interface.h>
|
||||||
#include <proto/task.h>
|
#include <proto/task.h>
|
||||||
|
@ -98,6 +98,7 @@
|
|||||||
#include <haproxy/net_helper.h>
|
#include <haproxy/net_helper.h>
|
||||||
#include <haproxy/openssl-compat.h>
|
#include <haproxy/openssl-compat.h>
|
||||||
#include <haproxy/pattern.h>
|
#include <haproxy/pattern.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/regex.h>
|
#include <haproxy/regex.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <haproxy/time.h>
|
#include <haproxy/time.h>
|
||||||
|
@ -37,6 +37,7 @@
|
|||||||
#include <haproxy/obj_type.h>
|
#include <haproxy/obj_type.h>
|
||||||
#include <haproxy/pattern.h>
|
#include <haproxy/pattern.h>
|
||||||
#include <haproxy/payload.h>
|
#include <haproxy/payload.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
|
|
||||||
#include <types/cli.h>
|
#include <types/cli.h>
|
||||||
@ -52,7 +53,6 @@
|
|||||||
#include <proto/http_fetch.h>
|
#include <proto/http_fetch.h>
|
||||||
#include <proto/queue.h>
|
#include <proto/queue.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/session.h>
|
#include <proto/session.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
|
@ -26,6 +26,7 @@
|
|||||||
#include <haproxy/pattern.h>
|
#include <haproxy/pattern.h>
|
||||||
#include <haproxy/pool.h>
|
#include <haproxy/pool.h>
|
||||||
#include <haproxy/regex.h>
|
#include <haproxy/regex.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <common/uri_auth.h>
|
#include <common/uri_auth.h>
|
||||||
#include <haproxy/version.h>
|
#include <haproxy/version.h>
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
#include <haproxy/chunk.h>
|
#include <haproxy/chunk.h>
|
||||||
#include <haproxy/http.h>
|
#include <haproxy/http.h>
|
||||||
#include <haproxy/pool.h>
|
#include <haproxy/pool.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <haproxy/version.h>
|
#include <haproxy/version.h>
|
||||||
|
|
||||||
@ -27,7 +28,6 @@
|
|||||||
#include <types/global.h>
|
#include <types/global.h>
|
||||||
|
|
||||||
#include <haproxy/arg.h>
|
#include <haproxy/arg.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
|
|
||||||
static int smp_check_http_date_unit(struct arg *args, struct sample_conv *conv,
|
static int smp_check_http_date_unit(struct arg *args, struct sample_conv *conv,
|
||||||
|
@ -27,6 +27,7 @@
|
|||||||
#include <haproxy/htx.h>
|
#include <haproxy/htx.h>
|
||||||
#include <haproxy/obj_type.h>
|
#include <haproxy/obj_type.h>
|
||||||
#include <haproxy/pool.h>
|
#include <haproxy/pool.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <haproxy/version.h>
|
#include <haproxy/version.h>
|
||||||
|
|
||||||
@ -38,7 +39,6 @@
|
|||||||
#include <proto/http_fetch.h>
|
#include <proto/http_fetch.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
|
|
||||||
|
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
|
|
||||||
#include <haproxy/api.h>
|
#include <haproxy/api.h>
|
||||||
#include <haproxy/regex.h>
|
#include <haproxy/regex.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <types/global.h>
|
#include <types/global.h>
|
||||||
|
|
||||||
#include <common/cfgparse.h>
|
#include <common/cfgparse.h>
|
||||||
@ -26,7 +27,6 @@
|
|||||||
|
|
||||||
#include <haproxy/arg.h>
|
#include <haproxy/arg.h>
|
||||||
#include <proto/http_fetch.h>
|
#include <proto/http_fetch.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
|
|
||||||
struct buffer http_err_chunks[HTTP_ERR_SIZE];
|
struct buffer http_err_chunks[HTTP_ERR_SIZE];
|
||||||
struct http_reply http_err_replies[HTTP_ERR_SIZE];
|
struct http_reply http_err_replies[HTTP_ERR_SIZE];
|
||||||
|
@ -32,7 +32,7 @@
|
|||||||
#include <proto/acl.h>
|
#include <proto/acl.h>
|
||||||
#include <haproxy/arg.h>
|
#include <haproxy/arg.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
|
|
||||||
|
|
||||||
/* List head of all known action keywords for "http-request" */
|
/* List head of all known action keywords for "http-request" */
|
||||||
|
@ -36,7 +36,7 @@
|
|||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <haproxy/protocol.h>
|
#include <haproxy/protocol.h>
|
||||||
#include <haproxy/proto_sockpair.h>
|
#include <haproxy/proto_sockpair.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
#include <proto/task.h>
|
#include <proto/task.h>
|
||||||
|
|
||||||
|
@ -40,7 +40,7 @@
|
|||||||
#include <haproxy/fd.h>
|
#include <haproxy/fd.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <haproxy/ring.h>
|
#include <haproxy/ring.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/sink.h>
|
#include <haproxy/sink.h>
|
||||||
#include <proto/ssl_sock.h>
|
#include <proto/ssl_sock.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
#include <proto/cli.h>
|
#include <proto/cli.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/stream_interface.h>
|
#include <proto/stream_interface.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
|
|
||||||
/* Parse an IPv4 or IPv6 address and store it into the sample.
|
/* Parse an IPv4 or IPv6 address and store it into the sample.
|
||||||
* The output type is IPv4 or IPv6.
|
* The output type is IPv4 or IPv6.
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
#include <types/global.h>
|
#include <types/global.h>
|
||||||
|
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
|
|
||||||
#include <import/ebsttree.h>
|
#include <import/ebsttree.h>
|
||||||
#include <import/lru.h>
|
#include <import/lru.h>
|
||||||
|
@ -22,7 +22,7 @@
|
|||||||
#include <haproxy/arg.h>
|
#include <haproxy/arg.h>
|
||||||
#include <proto/channel.h>
|
#include <proto/channel.h>
|
||||||
#include <proto/connection.h>
|
#include <proto/connection.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
|
|
||||||
|
|
||||||
|
@ -36,6 +36,7 @@
|
|||||||
#include <haproxy/http_rules.h>
|
#include <haproxy/http_rules.h>
|
||||||
#include <haproxy/list.h>
|
#include <haproxy/list.h>
|
||||||
#include <haproxy/listener.h>
|
#include <haproxy/listener.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <haproxy/namespace.h>
|
#include <haproxy/namespace.h>
|
||||||
|
|
||||||
@ -53,7 +54,6 @@
|
|||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/proto_tcp.h>
|
#include <proto/proto_tcp.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/task.h>
|
#include <proto/task.h>
|
||||||
#include <proto/tcp_rules.h>
|
#include <proto/tcp_rules.h>
|
||||||
|
@ -72,13 +72,13 @@
|
|||||||
#include <haproxy/api.h>
|
#include <haproxy/api.h>
|
||||||
#include <haproxy/http_rules.h>
|
#include <haproxy/http_rules.h>
|
||||||
#include <haproxy/pool.h>
|
#include <haproxy/pool.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/time.h>
|
#include <haproxy/time.h>
|
||||||
#include <haproxy/thread.h>
|
#include <haproxy/thread.h>
|
||||||
#include <import/eb32tree.h>
|
#include <import/eb32tree.h>
|
||||||
|
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/queue.h>
|
#include <proto/queue.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
#include <proto/stream_interface.h>
|
#include <proto/stream_interface.h>
|
||||||
|
@ -26,6 +26,7 @@
|
|||||||
#include <haproxy/http.h>
|
#include <haproxy/http.h>
|
||||||
#include <haproxy/net_helper.h>
|
#include <haproxy/net_helper.h>
|
||||||
#include <haproxy/regex.h>
|
#include <haproxy/regex.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <common/uri_auth.h>
|
#include <common/uri_auth.h>
|
||||||
#include <haproxy/base64.h>
|
#include <haproxy/base64.h>
|
||||||
@ -34,7 +35,6 @@
|
|||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/protocol_buffers.h>
|
#include <proto/protocol_buffers.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <haproxy/sink.h>
|
#include <haproxy/sink.h>
|
||||||
#include <proto/stick_table.h>
|
#include <proto/stick_table.h>
|
||||||
#include <proto/vars.h>
|
#include <proto/vars.h>
|
||||||
|
@ -22,6 +22,7 @@
|
|||||||
#include <haproxy/dns.h>
|
#include <haproxy/dns.h>
|
||||||
#include <haproxy/errors.h>
|
#include <haproxy/errors.h>
|
||||||
#include <haproxy/namespace.h>
|
#include <haproxy/namespace.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/time.h>
|
#include <haproxy/time.h>
|
||||||
|
|
||||||
#include <types/applet.h>
|
#include <types/applet.h>
|
||||||
@ -37,7 +38,6 @@
|
|||||||
#include <haproxy/port_range.h>
|
#include <haproxy/port_range.h>
|
||||||
#include <haproxy/protocol.h>
|
#include <haproxy/protocol.h>
|
||||||
#include <proto/queue.h>
|
#include <proto/queue.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
#include <proto/stream_interface.h>
|
#include <proto/stream_interface.h>
|
||||||
|
@ -24,16 +24,15 @@
|
|||||||
#include <haproxy/buf-t.h>
|
#include <haproxy/buf-t.h>
|
||||||
#include <haproxy/obj_type.h>
|
#include <haproxy/obj_type.h>
|
||||||
#include <haproxy/openssl-compat.h>
|
#include <haproxy/openssl-compat.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/ssl_utils.h>
|
#include <haproxy/ssl_utils.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
|
|
||||||
#include <types/sample.h>
|
|
||||||
#include <types/ssl_sock.h>
|
#include <types/ssl_sock.h>
|
||||||
|
|
||||||
#include <proto/acl.h>
|
#include <proto/acl.h>
|
||||||
#include <haproxy/arg.h>
|
#include <haproxy/arg.h>
|
||||||
#include <proto/ssl_sock.h>
|
#include <proto/ssl_sock.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
|
|
||||||
|
|
||||||
/***** Below are some sample fetching functions for ACL/patterns *****/
|
/***** Below are some sample fetching functions for ACL/patterns *****/
|
||||||
|
@ -60,7 +60,6 @@
|
|||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <haproxy/pipe.h>
|
#include <haproxy/pipe.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/session.h>
|
#include <proto/session.h>
|
||||||
#include <proto/ssl_sock.h>
|
#include <proto/ssl_sock.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
|
@ -36,7 +36,7 @@
|
|||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/proto_tcp.h>
|
#include <proto/proto_tcp.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
#include <proto/stream_interface.h>
|
#include <proto/stream_interface.h>
|
||||||
#include <proto/stick_table.h>
|
#include <proto/stick_table.h>
|
||||||
|
@ -55,7 +55,6 @@
|
|||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/queue.h>
|
#include <proto/queue.h>
|
||||||
#include <proto/server.h>
|
#include <proto/server.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/stick_table.h>
|
#include <proto/stick_table.h>
|
||||||
#include <proto/stream_interface.h>
|
#include <proto/stream_interface.h>
|
||||||
#include <proto/task.h>
|
#include <proto/task.h>
|
||||||
|
@ -14,6 +14,7 @@
|
|||||||
#include <haproxy/capture-t.h>
|
#include <haproxy/capture-t.h>
|
||||||
#include <common/cfgparse.h>
|
#include <common/cfgparse.h>
|
||||||
#include <haproxy/list.h>
|
#include <haproxy/list.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
#include <haproxy/tools.h>
|
#include <haproxy/tools.h>
|
||||||
#include <haproxy/ticks.h>
|
#include <haproxy/ticks.h>
|
||||||
#include <haproxy/time.h>
|
#include <haproxy/time.h>
|
||||||
@ -27,7 +28,6 @@
|
|||||||
#include <proto/connection.h>
|
#include <proto/connection.h>
|
||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/proxy.h>
|
#include <proto/proxy.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/stick_table.h>
|
#include <proto/stick_table.h>
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
#include <proto/stream_interface.h>
|
#include <proto/stream_interface.h>
|
||||||
|
@ -5,12 +5,12 @@
|
|||||||
#include <haproxy/http.h>
|
#include <haproxy/http.h>
|
||||||
#include <haproxy/http_rules.h>
|
#include <haproxy/http_rules.h>
|
||||||
#include <haproxy/list.h>
|
#include <haproxy/list.h>
|
||||||
|
#include <haproxy/sample.h>
|
||||||
|
|
||||||
#include <types/vars.h>
|
#include <types/vars.h>
|
||||||
|
|
||||||
#include <haproxy/arg.h>
|
#include <haproxy/arg.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/sample.h>
|
|
||||||
#include <proto/stream.h>
|
#include <proto/stream.h>
|
||||||
#include <proto/tcp_rules.h>
|
#include <proto/tcp_rules.h>
|
||||||
#include <proto/vars.h>
|
#include <proto/vars.h>
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
#include <proto/log.h>
|
#include <proto/log.h>
|
||||||
#include <proto/http_ana.h>
|
#include <proto/http_ana.h>
|
||||||
#include <proto/http_fetch.h>
|
#include <proto/http_fetch.h>
|
||||||
#include <proto/sample.h>
|
#include <haproxy/sample.h>
|
||||||
#include <import/ebsttree.h>
|
#include <import/ebsttree.h>
|
||||||
#include <import/ebmbtree.h>
|
#include <import/ebmbtree.h>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user