From 07e1a29d4ef5c189f5fb686d78d8d0f64f5c8a68 Mon Sep 17 00:00:00 2001 From: Ralf Haferkamp Date: Thu, 16 Jan 2025 12:51:21 +0100 Subject: [PATCH] rebrand antivirus --- services/antivirus/README.md | 4 ++-- services/antivirus/pkg/command/root.go | 2 +- services/antivirus/pkg/scanners/icap.go | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/services/antivirus/README.md b/services/antivirus/README.md index af21cd4571..8a181fdc62 100644 --- a/services/antivirus/README.md +++ b/services/antivirus/README.md @@ -40,7 +40,7 @@ The number of concurrent scans can be increased by setting `ANTIVIRUS_WORKERS`. The antivirus service allows three different ways of handling infected files. Those can be set via the `ANTIVIRUS_INFECTED_FILE_HANDLING` environment variable: - `delete`: (default): Infected files will be deleted immediately, further postprocessing is cancelled. - - `abort`: (advanced option): Infected files will be kept, further postprocessing is cancelled. Files can be manually retrieved and inspected by an admin. To identify the file for further investigation, the antivirus service logs the abort/infected state including the file ID. The file is located in the `storage/users/uploads` folder of the ocis data directory and persists until it is manually deleted by the admin via the [Manage Unfinished Uploads](https://doc.owncloud.com/ocis/next/deployment/services/s-list/storage-users.html#manage-unfinished-uploads) command. + - `abort`: (advanced option): Infected files will be kept, further postprocessing is cancelled. Files can be manually retrieved and inspected by an admin. To identify the file for further investigation, the antivirus service logs the abort/infected state including the file ID. The file is located in the `storage/users/uploads` folder of the OpenCloud data directory and persists until it is manually deleted by the admin via the [Manage Unfinished Uploads](https://github.com/opencloud-eu/opencloud/tree/main/services/storage-users#manage-unfinished-uploads) command. - `continue`: (obviously not recommended): Infected files will be marked via metadata as infected but postprocessing continues normally. Note: Infected Files are moved to their final destination and therefore not prevented from download which includes the risk of spreading viruses. In all cases, a log entry is added declaring the infection and handling method and a notification via the `userlog` service sent. @@ -55,7 +55,7 @@ The antivirus service can scan files during `postprocessing`. `on demand` scanni ### Postprocessing -The antivirus service will scan files during postprocessing. It listens for a postprocessing step called `virusscan`. This step can be added in the environment variable `POSTPROCESSING_STEPS`. Read the documentation of the [postprocessing service](https://github.com/owncloud/ocis/tree/master/services/postprocessing) for more details. +The antivirus service will scan files during postprocessing. It listens for a postprocessing step called `virusscan`. This step can be added in the environment variable `POSTPROCESSING_STEPS`. Read the documentation of the [postprocessing service](https://github.com/opencloud-eu/opencloud/tree/master/services/postprocessing) for more details. The number of concurrent scans can be increased by setting `ANTIVIRUS_WORKERS`, but be aware that this will also increase the memory usage. diff --git a/services/antivirus/pkg/command/root.go b/services/antivirus/pkg/command/root.go index 450cb9a4b9..12a11bc36b 100644 --- a/services/antivirus/pkg/command/root.go +++ b/services/antivirus/pkg/command/root.go @@ -21,7 +21,7 @@ func GetCommands(cfg *config.Config) cli.Commands { func Execute(cfg *config.Config) error { app := clihelper.DefaultApp(&cli.App{ Name: "antivirus", - Usage: "Serve ownCloud antivirus for oCIS", + Usage: "Antivirus service for OpenCloud", Commands: GetCommands(cfg), }) diff --git a/services/antivirus/pkg/scanners/icap.go b/services/antivirus/pkg/scanners/icap.go index 1f3b206996..4af638b256 100644 --- a/services/antivirus/pkg/scanners/icap.go +++ b/services/antivirus/pkg/scanners/icap.go @@ -88,7 +88,7 @@ func (s ICAP) Scan(in Input) (Result, error) { } result.ScanTime = time.Now() - // TODO: make header configurable. See oc10 documentation: https://doc.owncloud.com/server/10.12/admin_manual/configuration/server/virus-scanner-support.html + // TODO: make header configurable if data, infected := res.Header["X-Infection-Found"]; infected { result.Infected = infected