#include <Intercept.h>
Definition at line 29 of file Intercept.h.
◆ Intercept()
| Ip::Intercept::Intercept |
( |
| ) |
|
|
inline |
◆ ~Intercept()
| Ip::Intercept::~Intercept |
( |
| ) |
|
|
inline |
◆ InterceptActive()
| int Ip::Intercept::InterceptActive |
( |
| ) |
|
|
inline |
- Return values
-
| 0 | IP Interception is disabled. |
| 1 | IP Interception is enabled and active. |
Definition at line 77 of file Intercept.h.
References interceptActive_.
◆ IpfInterception()
◆ IpfwInterception()
perform Lookups on IPFW interception.
- Parameters
-
| newConn | Details known, to be updated where relevant. |
- Returns
- Whether successfully located the new address.
Definition at line 183 of file Intercept.cc.
◆ LookupNat()
◆ NetfilterInterception()
perform Lookups on Netfilter interception targets (REDIRECT, DNAT).
- Parameters
-
| newConn | Details known, to be updated where relevant. |
- Returns
- Whether successfully located the new address.
- Try NAT lookup for REDIRECT or DNAT targets.
Definition at line 125 of file Intercept.cc.
References DBG_IMPORTANT, debugs, Comm::Connection::fd, Ip::Address::getSockAddr(), IP6T_SO_ORIGINAL_DST, Ip::Address::isIPv6(), Comm::Connection::local, xgetsockopt(), and xstrerr().
◆ PfInterception()
perform Lookups on PF interception target (REDIRECT).
- Parameters
-
| newConn | Details known, to be updated where relevant. |
- Returns
- Whether successfully located the new address.
Definition at line 326 of file Intercept.cc.
References DBG_IMPORTANT, debugs, Ip::Address::getInAddr(), Ip::Address::isIPv6(), Comm::Connection::local, Ip::Address::port(), Comm::Connection::remote, xclose(), xopen(), and xstrerr().
◆ ProbeForTproxy()
| bool Ip::Intercept::ProbeForTproxy |
( |
Ip::Address & |
test | ) |
|
Test system networking calls for TPROXY support. Detects IPv6 and IPv4 level of support matches the address being listened on and if the compiled v2/v4 is usable as far down as a bind()ing.
- Parameters
-
| test | Address set on the squid.conf *_port being checked. |
- Return values
-
| true | TPROXY is available. |
| false | TPROXY is not available. |
Definition at line 402 of file Intercept.cc.
References DBG_CRITICAL, debugs, enter_suid(), Ip::Address::isIPv4(), Ip::Address::isIPv6(), leave_suid(), Ip::Address::port(), Ip::Address::setIPv4(), xbind(), xclose(), xsetsockopt(), and xsocket().
◆ StartInterception()
| void Ip::Intercept::StartInterception |
( |
| ) |
|
- Turn on IP-Interception-Proxy activities. This function should be called during parsing of the squid.conf When any option requiring interception / NAT handling is encountered.
Definition at line 169 of file Intercept.cc.
References Here.
◆ StartTransparency()
| void Ip::Intercept::StartTransparency |
( |
| ) |
|
- Turn on fully Transparent-Proxy activities. This function should be called during parsing of the squid.conf When any option requiring full-transparency is encountered.
Definition at line 154 of file Intercept.cc.
References Here.
◆ StopTransparency()
| void Ip::Intercept::StopTransparency |
( |
const char * |
str | ) |
|
- Turn off fully Transparent-Proxy activities on all new connections. Existing transactions and connections are unaffected and will run to their natural completion.
- Parameters
-
| str | Reason for stopping. Will be logged to cache.log |
Definition at line 116 of file Intercept.cc.
References DBG_IMPORTANT, debugs, and transparentActive_.
◆ TransparentActive()
| int Ip::Intercept::TransparentActive |
( |
| ) |
|
|
inline |
- Return values
-
| 0 | Full transparency is disabled. |
| 1 | Full transparency is enabled and active. |
Definition at line 56 of file Intercept.h.
References transparentActive_.
◆ UseInterceptionAddressesLookedUpEarlier()
| bool Ip::Intercept::UseInterceptionAddressesLookedUpEarlier |
( |
const char * |
caller, |
|
|
const Comm::ConnectionPointer & |
newConn |
|
) |
| |
|
private |
Assume that getsockname() has been called already and provided the necessary TCP packet details. There is no way to identify whether they came from NAT. Trust the user configured properly.
Definition at line 197 of file Intercept.cc.
References debugs.
◆ interceptActive_
| int Ip::Intercept::interceptActive_ |
|
private |
◆ transparentActive_
| int Ip::Intercept::transparentActive_ |
|
private |
The documentation for this class was generated from the following files: