Logging traffic of bad requests
Logging raw TCP traffic can be used to identify issues with bad requests. It provides debug level details for requests that were refused by ICAP Server's request parser due to syntax errors.
Important notes
Logging raw TCP traffic is not designed to be constantly enabled. It should only be used for investigating issues for short periods of time. Keeping it enabled permanently may impact performance. If running for too long, the log database can become huge and significantly reduce the available disk space.
Raw TCP traffic logs may contain sensitive or private information in a clear-text format.
Step-by-step guide
For configuration details see 3.1.2 MetaDefender ICAP Server configuration file.
Windows
Enable logging raw TCP traffic
Perform the following steps to enable traffic logging:
- Make sure MetaDefender ICAP Server is stopped
Open the Windows Registry with regedit. Go to the HKEY_LOCAL_MACHINE\SOFTWARE\OPSWAT\ICAP Server\logger entry
Add following entry with value:
- Name: capture_traffic
- Type: String (REG_SZ)
- Value: 1
Close the registry editor
Start MetaDefender ICAP server
Disable logging raw TCP traffic
Perform the following steps to disable traffic logging:
- Make sure MetaDefender ICAP Server is stopped
Open the Windows Registry with regedit. Go to the HKEY_LOCAL_MACHINE\SOFTWARE\OPSWAT\ICAP Server\logger entry
Delete or modify the following entries with the following values:
- Name: capture_traffic
- Type: String (REG_SZ)
- Value: 0
Close the registry editor
Start MetaDefender ICAP server
Linux (CentOS syntax)
Enable logging raw TCP traffic
Perform the following steps to enable traffic logging:
- Make sure MetaDefender ICAP Server is stopped
Edit /etc/mdicapsrv/mdicapsrv.conf
Add or modify the following entry under the [logger] section with the following value:
- capture_traffic=1
Save and close the configuration file
Start MetaDefender ICAP server
Disable logging raw TCP traffic
Perform the following steps to enable traffic logging:
- Make sure MetaDefender ICAP Server is stopped
Edit /etc/mdicapsrv/mdicapsrv.conf
Delete or modify the following entry under the [logger] section with the following value:
- capture_traffic=0
Save and close the configuration file
Start MetaDefender ICAP server