Wiki source code of ClamAV
Hide last authors
author | version | line-number | content |
---|---|---|---|
![]() |
12.3 | 1 | {{info}} |
2 | {{version major="7" minor="0" patch="13" showInfo="true"}} | ||
3 | This plugin can only be used with {{formcycle/}} version 7.0.13 or higher. | ||
4 | {{/version}} | ||
5 | {{/info}} | ||
6 | |||
![]() |
18.2 | 7 | [[**Plugin download**>>https://customer.formcycle.eu/index.php/apps/files/?dir=/FORMCYCLE%20-%20Plugins%20Customer/fc-plugin-malware-scanner/ClamAV&fileid=40404]] (Requires login) |
![]() |
7.2 | 8 | |
9 | {{content/}} | ||
10 | |||
![]() |
18.1 | 11 | Uploaded files can be checked for viruses via the plug-in. For this purpose, this plugin is required as an activated system plugin and a running ClamAV-daemon service that can be accessed via TCP. |
![]() |
7.2 | 12 | |
13 | After this plugin has been installed, it must be configured. The configuration consists of specifying which {{smallcaps}}host:port{{/smallcaps}} combination is to be used. Furthermore, the transfer can be done with a {{smallcaps}}InputStream{{/smallcaps}} or working straight on the path. | ||
14 | |||
15 | == Configuration == | ||
16 | |||
17 | {{figure image="en_error.png" width="400"}} | ||
18 | If no connection can be established to the specified host, this message is displayed. | ||
19 | {{/figure}} | ||
20 | |||
21 | The following configuration parameters exist: | ||
22 | |||
23 | ; host (Required) | ||
![]() |
12.2 | 24 | : Host name or IP address of the server running ClamAV-daemon. The standard port is {{smallcaps}}127.0.0.1{{/smallcaps}}, since ClamAV-daemon should be running on the same server as {{formcycle/}}. |
![]() |
12.1 | 25 | ; port (Required) |
![]() |
7.2 | 26 | : The default port of ClamAV-daemon is {{smallcaps}}3310{{/smallcaps}}. If the port is different, it must be specified here. |
27 | ; file-source | ||
28 | : By default, the element to be checked is transferred via Java's {{smallcaps}}InputStream{{/smallcaps}}. If the value {{smallcaps}}path{{/smallcaps}} is entered here, the path is used directly - whereby the ClamAV-daemon service must have root rights. | ||
29 | |||
30 | After saving, a ping test is automatically executed. If this fails, a corresponding message is displayed. In this case, all uploads in the backend or in the form are marked as faulty - the plugin should first be deactivated and a functioning connection established. | ||
31 | |||
32 | == ClamAV settings == | ||
33 | |||
![]() |
12.1 | 34 | The following section discusses important configuration steps of ClamAV-Daemon. Our recommended scenario is to install {{formcycle/}} and the ClamAV-Daemon service on the same server. |
![]() |
7.2 | 35 | |
36 | Since the actual virus scanning takes place separately from {{formcycle/}}, take care to keep the virus signature database up-to-date via {{smallcaps}}freshclam{{/smallcaps}}. | ||
37 | |||
![]() |
7.3 | 38 | This plugin transmits the elements to be examined via TCP, which is deactivated by default in ClamAV-daemon. To enable it, the configuration file: {{smallcaps}}/etc/clamav/clamd.conf{{/smallcaps}} has to be edited. |
![]() |
7.2 | 39 | |
![]() |
7.3 | 40 | The following parameters have to be added to the file: |
![]() |
7.2 | 41 | |
![]() |
7.3 | 42 | ; TCPAddr (Required) |
43 | : Shall be added and specified with the value {{smallcaps}}127.0.0.1{{/smallcaps}}. | ||
44 | ; TCPSocket (Required) | ||
45 | : Shall be added and specified with the value {{smallcaps}}3310{{/smallcaps}} or different, if the port is occupied. | ||
![]() |
7.2 | 46 | ; User |
![]() |
7.3 | 47 | : By default this is {{smallcaps}}clamav{{/smallcaps}} and has to be changed to {{smallcaps}}root{{/smallcaps}} to give root rights to the ClamAV-daemon service. |
![]() |
7.2 | 48 | |
49 | {{figure image="en_tcp_test.png"}} | ||
![]() |
7.4 | 50 | With the help of {{smallcaps}}netstat{{/smallcaps}} the TCP socket of the ClamAV-daemon service can be examined. |
![]() |
7.2 | 51 | {{/figure}} |
52 | |||
![]() |
7.4 | 53 | In order for this plugin to address the ClamAV-daemon service, the service has to be listening in the right place - in this case at {{smallcaps}}127.0.0.1:3310{{/smallcaps}}. This can be checked by the following command in the terminal: |
![]() |
7.2 | 54 | |
55 | {{code language="shell"}} | ||
56 | sudo netstat -anp | grep -E "(clam)" | ||
57 | {{/code}} | ||
58 | |||
59 |