ILIAS  release_7 Revision v7.30-3-g800a261c036
ilVirusScannerFactory Class Reference

Class ilVirusScannerFactory. More...

+ Collaboration diagram for ilVirusScannerFactory:

Static Public Member Functions

static _getInstance ()
 

Detailed Description

Class ilVirusScannerFactory.

Definition at line 7 of file class.ilVirusScannerFactory.php.

Member Function Documentation

◆ _getInstance()

static ilVirusScannerFactory::_getInstance ( )
static
Returns
ilVirusScannerAntiVir|ilVirusScannerClamAV|ilVirusScannerICapClient|ilVirusScannerICapRemoteAvClient|ilVirusScannerSophos|null

Definition at line 12 of file class.ilVirusScannerFactory.php.

13 {
14 $vs = null;
15
16 if (IL_VIRUS_SCANNER == "icap") {
17 if (strlen(IL_ICAP_CLIENT) > 0) {
18 $vs = new ilVirusScannerICapClient('', '');
19 } else {
20 $vs = new ilVirusScannerICapRemoteAvClient('', '');
21 }
22 } else {
23 switch (IL_VIRUS_SCANNER) {
24 case "Sophos":
25 $vs = new ilVirusScannerSophos(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
26 break;
27 case "AntiVir":
28 global $DIC;
29 $DIC->logger()->error('AntiVir is deprecated, please install and use a different virus scanner.');
30 $vs = new ilVirusScannerAntiVir(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
31 break;
32 case "ClamAV":
33 $vs = new ilVirusScannerClamAV(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
34 break;
35 }
36 }
37 return $vs;
38 }
Interface to the AntiVir virus protector.
Interface to the ClamAV virus protector.
Interface to the ClamAV virus protector.
Interface to the sophos virus protector.
global $DIC
Definition: goto.php:24

References $DIC.

Referenced by ilLTIConsumerAdministrationGUI\checkIconFileVirus(), ilInitialisation\initFileUploadService(), ilQTIParser\virusDetected(), and ilUtil\virusHandling().

+ Here is the caller graph for this function:

The documentation for this class was generated from the following file: