haproxy/src
Willy Tarreau 1c59bd5abc BUG/MAJOR: http: don't requeue an idle connection that is already queued
Cyril Bonté reported a reproduceable sequence which can lead to a crash
when using backend connection reuse. The problem comes from the fact that
we systematically add the server connection to an idle pool at the end of
the HTTP transaction regardless of the fact that it might already be there.

This is possible for example when processing a request which doesn't use
a server connection (typically a redirect) after a request which used a
connection. Then after the first request, the connection was already in
the idle queue and we're putting it a second time at the end of the second
request, causing a corruption of the idle pool.

Interestingly, the memory debugger in 1.7 immediately detected a suspicious
double free on the connection, leading to a very early detection of the
cause instead of its consequences.

Thanks to Cyril for quickly providing a working reproducer.

This fix must be backported to 1.6 since connection reuse was introduced
there.
2015-11-02 22:28:25 +01:00
..
51d.c MINOR: 51d: Improved string handling for LRU cache 2015-09-21 12:55:24 +02:00
acl.c BUG/MEDIUM: acl: always accept match "found" 2015-09-24 16:38:48 +02:00
applet.c MINOR: stream-int: rename si_applet_done() to si_applet_wake_cb() 2015-09-25 21:16:02 +02:00
arg.c BUG/MINOR: args: add name for ARGT_VAR 2015-09-21 20:57:12 +02:00
auth.c MINOR: samples: rename union from "data" to "u" 2015-08-20 17:13:46 +02:00
backend.c MAJOR: tproxy: remove support for cttproxy 2015-08-20 19:35:14 +02:00
base64.c [MINOR] add encode/decode function for 30-bit integers from/to base64 2010-10-30 19:04:33 +02:00
buffer.c BUG/MAJOR: buffers: make the buffer_slow_realign() function respect output data 2015-07-02 15:27:24 +02:00
cfgparse.c BUG: config: external-check command validation is checking for incorrect arguments. 2015-10-02 23:11:49 +02:00
channel.c MEDIUM: channel: don't always set CF_WAKE_WRITE on bi_put* 2015-03-13 14:00:47 +01:00
checks.c MEDIUM: dns: Don't use the ANY query type 2015-10-20 22:31:01 +02:00
chunk.c MINOR: chunk: New function free_trash_buffers() 2015-09-28 14:00:00 +02:00
compression.c MINOR: samples: rename union from "data" to "u" 2015-08-20 17:13:46 +02:00
connection.c BUG/MAJOR: connection: fix TLV offset calculation for proxy protocol v2 parsing 2015-07-03 17:05:20 +02:00
da.c MAJOR: da: Update of the DeviceAtlas API module 2015-09-28 14:01:27 +02:00
dns.c BUG/MINOR: dns: unable to parse CNAMEs response 2015-10-30 12:39:08 +01:00
dumpstats.c MEDIUM: memory: add accounting for failed allocations 2015-10-28 16:24:21 +01:00
ev_epoll.c CLEANUP: poll: move the conditions for waiting out of the poll functions 2015-04-13 20:47:51 +02:00
ev_kqueue.c CLEANUP: poll: move the conditions for waiting out of the poll functions 2015-04-13 20:47:51 +02:00
ev_poll.c CLEANUP: poll: move the conditions for waiting out of the poll functions 2015-04-13 20:47:51 +02:00
ev_select.c CLEANUP: poll: move the conditions for waiting out of the poll functions 2015-04-13 20:47:51 +02:00
fd.c MAJOR: polling: centralize calls to I/O callbacks 2014-11-21 20:37:32 +01:00
freq_ctr.c BUG/MINOR: time: frequency counters are not totally accurate 2012-12-29 21:50:07 +01:00
frontend.c MINOR: samples: rename union from "data" to "u" 2015-08-20 17:13:46 +02:00
haproxy-systemd-wrapper.c BUILD/CLEANUP: systemd: avoid a warning due to mixed code and declaration 2015-03-04 10:11:57 +01:00
haproxy.c BUG/MEDIUM: config: count memory limits on 64 bits, not 32 2015-10-29 10:42:55 +01:00
hash.c MINOR: hash: add new function hash_crc32 2015-01-20 19:48:05 +01:00
hdr_idx.c OPTIM/MINOR: move the hdr_idx pools out of the proxy struct 2011-10-24 18:15:04 +02:00
hlua.c BUG/MEDIUM: lua: direction test failed 2015-10-13 15:49:31 +02:00
i386-linux-vsys.c MEDIUM: listener: add support for linux's accept4() syscall 2012-10-08 20:11:03 +02:00
lb_chash.c REORG/MEDIUM: server: split server state and flags in two different variables 2014-05-22 11:27:00 +02:00
lb_fas.c REORG/MEDIUM: server: split server state and flags in two different variables 2014-05-22 11:27:00 +02:00
lb_fwlc.c REORG/MEDIUM: server: split server state and flags in two different variables 2014-05-22 11:27:00 +02:00
lb_fwrr.c REORG/MEDIUM: server: split server state and flags in two different variables 2014-05-22 11:27:00 +02:00
lb_map.c MINOR: server: make use of srv_is_usable() instead of checking eweight 2014-05-23 14:29:11 +02:00
listener.c MINOR: samples: rename union from "data" to "u" 2015-08-20 17:13:46 +02:00
log.c BUG/MEDIUM: logs: fix time zone offset format in RFC5424 2015-10-10 00:07:03 +02:00
lru.c MINOR: lru: do not allocate useless memory in lru64_lookup 2015-10-09 10:13:18 +02:00
mailers.c MEDIUM: Add parsing of mailers section 2015-02-03 00:24:16 +01:00
map.c MINOR: map: The map can return IPv4 and IPv6 2015-08-20 17:13:46 +02:00
memory.c MEDIUM: memory: add accounting for failed allocations 2015-10-28 16:24:21 +01:00
namespace.c BUG/MEDIUM: namespaces: don't fail if no namespace is used 2015-10-20 15:29:00 +02:00
pattern.c BUG/MEDIUM: pattern: fixup use_after_free in the pat_ref_delete_by_id 2015-10-13 18:31:49 +02:00
payload.c MINOR: payload: add support for tls session ticket ext 2015-09-29 14:07:32 +02:00
peers.c BUG/MINOR: fct peer_prepare_ackmsg should not use trash. 2015-09-22 16:07:34 +02:00
pipe.c BUILD/MINOR: silent a build warning in src/pipe.c (fcntl) 2011-10-24 17:09:22 +02:00
proto_http.c BUG/MAJOR: http: don't requeue an idle connection that is already queued 2015-11-02 22:28:25 +01:00
proto_tcp.c MEDIUM: server: implement TCP_USER_TIMEOUT on the server 2015-10-13 16:18:27 +02:00
proto_udp.c MEDIUM: protocol: add minimalist UDP protocol client 2015-06-13 22:07:35 +02:00
proto_uxst.c REORG/MEDIUM: stream: rename stream flags from SN_* to SF_* 2015-04-06 11:23:57 +02:00
protocol.c MEDIUM: protocol: use a family array to index the protocol handlers 2015-02-28 23:12:31 +01:00
proxy.c BUG/MEDIUM: proxy: do not wake stopped proxies' tasks during soft_stop() 2015-09-28 16:35:04 +02:00
queue.c REORG/MEDIUM: stream: rename stream flags from SN_* to SF_* 2015-04-06 11:23:57 +02:00
raw_sock.c BUG/MINOR: raw_sock: also consider ENOTCONN in addition to EAGAIN for recv() 2014-03-04 07:27:18 +01:00
rbtree.c [MINOR] imported the rbtree function from Linux kernel 2007-01-07 02:12:57 +01:00
regex.c MEDIUM: regex: add support for passing regex flags to regex_exec_match() 2015-01-22 14:24:53 +01:00
sample.c MEDIUM: logs: add a new RFC5424 log-format for the structured-data 2015-09-28 14:01:27 +02:00
server.c BUG/MAJOR: dns: first DNS response packet not matching queried hostname may lead to a loop 2015-10-30 12:38:14 +01:00
session.c MEDIUM: vars: move the session variables to the session, not the stream 2015-06-19 11:59:02 +02:00
shctx.c MINOR: stats: add counters for SSL cache lookups and misses 2014-05-28 16:53:04 +02:00
signal.c BUG/MEDIUM: signal: signal handler does not properly check for signal bounds 2013-01-24 16:19:19 +01:00
ssl_sock.c BUILD: ssl: fix build error introduced in commit 7969a3 with OpenSSL < 1.0.0 2015-10-22 13:32:34 +02:00
standard.c MINOR: config: allow IPv6 bracketed literals 2015-11-01 21:30:41 +01:00
stick_table.c MEDIUM: actions: pass a new "flags" argument to custom actions 2015-09-27 11:04:06 +02:00
stream.c MINOR: stream/applet: add use-service action 2015-09-28 01:03:48 +02:00
stream_interface.c BUG/MEDIUM: stream-int: avoid double-call to applet->release 2015-09-25 21:16:03 +02:00
task.c REORG/MAJOR: session: rename the "session" entity to "stream" 2015-04-06 11:23:56 +02:00
time.c BUG/MINOR: time: frequency counters are not totally accurate 2012-12-29 21:50:07 +01:00
trace.c MINOR: add a new function call tracer for debugging purposes 2012-05-26 00:12:37 +02:00
uri_auth.c BUG/MEDIUM: uri_auth: missing NULL check and memory leak on memory shortage 2013-01-24 16:19:19 +01:00
vars.c MEDIUM: actions: pass a new "flags" argument to custom actions 2015-09-27 11:04:06 +02:00
xxhash.c IMPORT: hash: import xxhash-r39 2015-04-29 19:15:21 +02:00