The first connection attempt to a website that is added in Common Name (CN) Exclusion of Client DPI
03/26/2020 339 11200
DESCRIPTION: The first connection attempt to a website that is added in Common Name (CN) Exclusion of Client DPI-SSL is dropped
With Client DPI-SSL enabled, when a website is added under Common Name (CN) Exclusion of Client DPI-SSL, the first connection attempt to the site over HTTPS is dropped. After a couple of refresh, the page is displayed properly; the certificate is shown as signed by a 3rd party CA and not by DPI-SSL indicating that the website has been excluded from Client DPI-SSL inspection as intended.
Why is the connection dropped the first time and requires a refresh?
To have a better perspective of this question, let us examine how Client DPI-SSL does other forms of exclusions - IP address based, Service based (port number) and User Name/Group based. In these three forms of exclusions, SonicWall needs only examine the first packet from the client (TCP SYN) to know that the connection needs to be excluded from DPI-SSL Client Inspection.
However, when a website is excluded by its Certificate Common Name (CN), SonicWall needs to "wait" for the Certificate message in the SSL Handshake before it decides to exclude the traffic from DPI-SSL Client Inspection. It requires to do this for every connection attempt to that website.
Therefore, when a client attempts a connection to a CN excluded website the first time, SonicWall performs the server side SSL Handshake; discovers from the Certificate message that the site is in the CN exclusion list; drops the connection because the Handshake is done with SonicWall as the client; caches the IP address mapped to the Certificate Common Name.
By the time a second attempt to connect to the website by way of automatic or manual refresh is made, SonicWall "knows" from the first packet itself (TCP SYN) that the connection needs to be exempted from DPI-SSL Client Inspection. This saves appliance resources by not having to do the server side SSL handshake all over again.
The IP address mapped to the CN is cached for 24 hours. The cache can have 1024 entries; it is not saved during reboots; it is not synced in an HA pair.
NOTE: Since the cache has IP address mapped to a CN, if a connection attempt is made to a different IP address of the same server (if the server is hosted on multiple IP address), the connection is again dropped the first time and the process starts over.