ILIAS  release_8 Revision v8.24
ilVirusScannerFactory Class Reference
+ Collaboration diagram for ilVirusScannerFactory:

Static Public Member Functions

static _getInstance ()
 

Detailed Description

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

Member Function Documentation

◆ _getInstance()

static ilVirusScannerFactory::_getInstance ( )
static

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

24 {
25 $vs = null;
26
27 if (IL_VIRUS_SCANNER === "icap") {
28 if (strlen(IL_ICAP_CLIENT) > 0) {
29 $vs = new ilVirusScannerICapClient('', '');
30 } else {
31 $vs = new ilVirusScannerICapRemoteAvClient('', '');
32 }
33 } else {
34 switch (IL_VIRUS_SCANNER) {
35 case "Sophos":
36 $vs = new ilVirusScannerSophos(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
37 break;
38 case "AntiVir":
39 global $DIC;
40 $DIC->logger()->root()->error('AntiVir is deprecated, please install and use a different virus scanner.');
41 $vs = new ilVirusScannerAntiVir(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
42 break;
43 case "ClamAV":
44 $vs = new ilVirusScannerClamAV(IL_VIRUS_SCAN_COMMAND, IL_VIRUS_CLEAN_COMMAND);
45 break;
46 }
47 }
48 return $vs;
49 }
global $DIC
Definition: feed.php:28

References $DIC.

Referenced by ilLTIConsumerAdministrationGUI\checkIconFileVirus(), ilInitialisation\initFileUploadService(), VirusScannerFactoryTest\testAntiVirScanStrategyCanBeRetrievedAccordingToGlobalSetting(), VirusScannerFactoryTest\testClamAvScanStrategyCanBeRetrievedAccordingToGlobalSetting(), VirusScannerFactoryTest\testIcapClientScanStrategyCanBeRetrievedAccordingToGlobalSetting(), VirusScannerFactoryTest\testSophosScanStrategyCanBeRetrievedAccordingToGlobalSetting(), ilQTIParser\virusDetected(), and ilVirusScanner\virusHandling().

+ Here is the caller graph for this function:

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