Error reading from socket using IKARUS scan.server (default configuration in amavisd.conf)
Amavis version 2.13.0
IKARUS scan.server version 6.1.7l64
Configuration used in amavisd.conf considered obsolete by IKARUS according to the document from here, section Legacy XML endpoints (kept for backwards compatibility)
['IKARUS scan.server',
\&ask_daemon,
["GET /virusscan?filename={}/../email.txt HTTP/1.1\r\n\r\n", '127.0.0.1:81'],
qr/<status>clean<\/status>/,
qr/<status>infected<\/status>/,
qr/<name>(.+)<\/name>/ ],
Logs in IKARUS scan.server:
cat /opt/scanserver/log/scan/scanserver.log
[08.03.2023 11:56:25][6E9F] {"crc64":3126915349464349093,"filetype":1817,"status":"infected","infected_item":"/mnt/tmpfs/amavis-20230308T115625-29706-S1PZRLpN/parts/../email.txt==>eicar_com.zip==>eicar.com","sigid":462103,"signame":"EICAR-Test-File","num_items":3,"time":0,"input":"/mnt/tmpfs/amavis-20230308T115625-29706-S1PZRLpN/parts/../email.txt","client":"127.0.0.1"}
[08.03.2023 11:56:56][6E9A] {"crc64":3126915349464349093,"filetype":1817,"status":"infected","infected_item":"/mnt/tmpfs/amavis-20230308T115625-29706-S1PZRLpN/parts/../email.txt==>eicar_com.zip==>eicar.com","sigid":462103,"signame":"EICAR-Test-File","num_items":3,"time":0,"input":"/mnt/tmpfs/amavis-20230308T115625-29706-S1PZRLpN/parts/../email.txt","client":"127.0.0.1"}
[08.03.2023 11:57:32][6E9C] {"crc64":3126915349464349093,"filetype":1817,"status":"infected","infected_item":"/mnt/tmpfs/amavis-20230308T115625-29706-S1PZRLpN/parts/../email.txt==>eicar_com.zip==>eicar.com","sigid":462103,"signame":"EICAR-Test-File","num_items":3,"time":0,"input":"/mnt/tmpfs/amavis-20230308T115625-29706-S1PZRLpN/parts/../email.txt","client":"127.0.0.1"}
Logs in maillog:
cat /var/log/maillog | grep "IKARUS scan.server"
Mar 8 11:55:04 xxx amavis[29700]: Using primary internal av scanner code for IKARUS scan.server
Mar 8 11:56:55 xxx amavis[29706]: (29706-01) IKARUS scan.server: Error reading from socket: Connection reset by peer at /usr/local/src/amavis-v2.13.0/lib/Amavis/IO/RW.pm line 307., retrying (1)
Mar 8 11:57:26 xxx amavis[29706]: (29706-01) (!)IKARUS scan.server: Error reading from socket: Connection reset by peer at /usr/local/src/amavis-v2.13.0/lib/Amavis/IO/RW.pm line 307., retrying (2)
Mar 8 11:58:02 xxx amavis[29706]: (29706-01) (!)IKARUS scan.server av-scanner FAILED: run_av error: Too many retries to talk to 127.0.0.1:81 (Error reading from socket: Connection reset by peer at /usr/local/src/amavis-v2.13.0/lib/Amavis/IO/RW.pm line 307.) at /usr/local/src/amavis-v2.13.0/lib/Amavis/AV.pm line 663.\n
The problem was reported previously and here
Any hints for the possibility of using one of the methods recommended in IKARUS_scan.server_Quickstart_Guide.txt from here the section
Scanning files - JSON HTTP endpoint: