Web Monitor enables your product to scan HTTP traffic encrypted using SSL protocol.
Depending on the version of SSL protocol, the following protection is provided.
KAV SDK allows you to scans traffic and detects malicious objects within the HTTPS/SSL v.3 traffic.
This version of SSL has been deprecated since 1996. If blocking of HTTPS/SSL v.2 traffic is enabled, Web Monitor immediately blocks connections established via SSL v.2 and no scanning of the traffic is made. Otherwise, the Web Monitor allows the traffic and does not scan it neither it detects objects in the HTTP encrypted with SSL v.2.
To scan HTTPS traffic KAV SDK uses a digital certificate. This certificate is issued by Kaspersky Lab. KAV SDK automatically places this certificate to the computer storage during initialization even if scanning HTTPS traffic is turned off.
Turning scanning of SSL v.3 traffic on or off
Manging the state of scanning encrypted traffic depends on the target browser or application that establishes SSL connections.
Microsoft Internet Explorer® and Google Chrome™ browsers support using computer storage, which is used system wide. Once certificate is added to the storage, these browsers keep using it until you remove the certificate from the storage.
Browsers Mozilla™ Firefox™ and Opera use their custom storage for storing certificates. KAV SDK automatically installs its digital certificate to these custom storages when you start Firefox or Opera. Make sure to close any running instance of these browsers before run KAV SDK for the first time. Otherwise, if you attempt to start KAV SDK when there is a running instance of Firefox or Opera browser, this instance needs to be restarted to use the installed certificate.
You may need to manually install Kaspersky certificate in the following cases:
To turn scanning of HTTPS traffic for Web Monitor on or off,
Invoke kaveEnableSSLDecode with bEnable parameter set to 1 to turn on scanning of HTTPS/SSL v.3 traffic and objects transferred via this protocol. Or, set bEnable to 0 to turn off scanning of HTTPS connections.
To verify if scanning of HTTPS traffic is turned on or off,
Invoke kaveIsEnabledSSLDecode.
To manually install digital certificate,
Invoke kaveReinstallSSLCertificate.
If an error occurs in the middle of a scanning operation, KAV SDK closes the established SSL connection.
Turning blocking of SSL v.2 connections on or off
By default, Web Monitor blocks connections established via HTTPS/SSL v.2 and does not scan objects within such traffic. This protocol has been deprecated and is globally considered insecure.
You may manage blocking of HTTPS/SSL v.2 traffic by changing its default ON state to OFF through the kaveEnableSSLv2Blocking API.
To turn blocking of HTTPS/SSL v.2 connections for Web Monitor on or off,
Invoke kaveEnableSSLv2Blocking with bEnable parameter set to 1 to turn on blocking of HTTPS/SSL v.2 connections. Or, set bEnable to 0 to turn off blocking of HTTPS connections established over SSL v.2.
To verify if blocking of HTTPS/SSL v.2 connections is turned on or off,
Invoke kaveIsEnabledSSLv2Blocking.
By default, blocking is turned on, and this function returns TRUE.
Handling SSL v3 connections to a host with expired or not-yet-valid certificate
To inform your application about issues with the certificate of the remote host, KAV SDK uses your main callback function built based on the prototype.
For example, if the application monitored by Web Monitor connects to a remote host with an expired or not-yet-valid certificate, KAV SDK invokes your callback handler with the EVENT_SSL_BAD_CERTIFICATE code in dwEvent. In this handler the SDK requests your application to response with one of the following return codes:
CLBK_USE_INVALID_CERTAccept the expired certificate. When you choose this option, Web Monitor allows the application that initiated the connection to connect to the remote host.
CLBK_CANCEL_OBJECT or CLBK_CANCEL_ALL (or any code other than CLBK_USE_INVALID_CERT)Reject the expired certificate. Web Monitor blocks the connection to the remote host.
Invoked callback contains the following data for its respective parameters:
pObjectNameInformation about the current TCP connection. An IPv4 or IPv6 address of a remote host or host name, and a TCP port for the remote host.
param1 and param2A reference to the KAV_CERTIFICATE_INFO data structure that stores certificate properties: signed certificate of the remote endpoint and the hash value of the certificate.