BUG/MEDIUM: tcp: don't require privileges to bind to device
authorWilly Tarreau <w@1wt.eu>
Mon, 27 Mar 2017 14:22:59 +0000 (16:22 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 27 Mar 2017 14:22:59 +0000 (16:22 +0200)
commit19060a302033b70fbe29eb825617b03ea5e9e71d
tree992e01013e5159d339f4fd80f40fcb39694c0f4c
parent98a3e3f998e2803c368a9431a39cf957781f4657
BUG/MEDIUM: tcp: don't require privileges to bind to device

Ankit Malp reported a bug that we've had since binding to devices was
implemented. Haproxy wrongly checks that the process stays privileged
after startup when a binding to a device is specified via the bind
keyword "interface". This is wrong, because after startup we're not
binding any socket anymore, and during startup if there's a permission
issue it will be immediately reported ("permission denied"). More
importantly there's no way around it as the process exits on startup
when facing such an option.

This fix should be backported to 1.7, 1.6 and 1.5.
src/proto_tcp.c