]> git.ipfire.org Git - thirdparty/squid.git/commit - src/cf.data.pre
Fix tcp outgoing tos bugs
authorChristos Tsantilas <chtsanti@users.sourceforge.net>
Mon, 21 Jul 2014 14:55:27 +0000 (17:55 +0300)
committerChristos Tsantilas <chtsanti@users.sourceforge.net>
Mon, 21 Jul 2014 14:55:27 +0000 (17:55 +0300)
commitc6f168c13172952969554e27714dbd7d6d01e268
tree0cefd7a652700859e664b386c0657139b1abab53
parentd00790b208b31395d0aec1e684f7c214d20948f1
Fix tcp outgoing tos bugs

The tcp_outgoing_tos is buggy in trunk:
 - The ToS is never set for packets of the first request of a TCP connection.
 - The ToS is never set for HTTPS traffic no matter whether requests are bumped
   or not.
 - The ToS value is not set for ftp data connections

This patch solve the above problems:
 - It moves the codes which sets the TOS value for a new connection from the
   the comm_openex to a higher-level code, where the connection protocol
   (IPv4 or IPv6) is known.
 - Add code to set TOS value for ftp data connections.
 - Add a check on parsing code to warn users if the configured ToS value has the
   ECN bits set, and adjust the value to a correct one.

Notes
  Currently squid support only passive ftp data connections. If squid in the
future supports active ftp connections, then some work required to TcpAcceptor
class to allow setting ToS values for connections established on squid listening
sockets.

This is a Measurement Factory project
src/FwdState.cc
src/cache_cf.cc
src/cf.data.pre
src/comm.cc
src/comm.h
src/comm/ConnOpener.cc
src/comm/TcpAcceptor.cc
src/ftp.cc
src/ip/Qos.cci
src/ip/QosConfig.h