]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: peers: fix buffer overflow control in intdecode.
authorEmeric Brun <ebrun@haproxy.com>
Wed, 29 Mar 2017 14:32:53 +0000 (16:32 +0200)
committerWilly Tarreau <w@1wt.eu>
Thu, 30 Mar 2017 10:12:46 +0000 (12:12 +0200)
commit18928af3a3e3692cc2f086f8f271538436fcbe2e
tree3f80d883eec0be2d8136ca6a646b0203909a17ec
parentacd4827ecabebccc9e57fe091de23a1ea5ec95b7
BUG/MEDIUM: peers: fix buffer overflow control in intdecode.

A buffer overflow could happen if an integer is badly encoded in
the data part of a msg received from a peer. It should not happen
with authenticated peers (the handshake do not use this function).

This patch makes the code of the 'intdecode' function more robust.

It also adds some comments about the intencode function.

This bug affects versions >= 1.6.
src/peers.c