Skip to content

fix(clamav): write full-scan log to a root-owned directory - #2907

Open
szaimen wants to merge 1 commit into
mainfrom
fix/clamav-fullscan-log-dir
Open

szaimen wants to merge 1 commit into
mainfrom
fix/clamav-fullscan-log-dir

Conversation

@szaimen

@szaimen szaimen commented Nov 26, 2026

Copy link
Copy Markdown
Collaborator

The weekly full-scan cron runs as root but wrote its log into $VMLOGS, which is owned by www-data. www-data could replace the log with a symlink and have root overwrite or chown arbitrary files. Keep the log in /var/log/clamav-fullscan, which only root can write to.

🤖 AI (if applicable)

  • The content of this PR was partly or fully generated using AI (N/A)

The weekly full-scan cron runs as root but wrote its log into $VMLOGS,
which is owned by www-data. www-data could replace the log with a
symlink and have root overwrite or chown arbitrary files. Keep the log
in /var/log/clamav-fullscan, which only root can write to.

Assisted-by: Claude Code:claude-opus-5-5
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Simon L. <szaimen@e.mail.de>
@enoch85

enoch85 commented Nov 26, 2026

Copy link
Copy Markdown
Member

No, VMLOGS is where we want it to make it easy to find and visable.

Please also remove commit attribution. PR attribution is enough. Also ask your AI to read rules and save to memory when working on this repo.

@szaimen

szaimen commented Nov 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Please also remove commit attribution. PR attribution is enough. Also ask your AI to read rules and save to memory when working on this repo.

This is going against what Agents.md says from where these settings are read from. See https://github.com/nextcloud/vm/blob/main/AGENTS.md#what-this-agent-must-always-do

@szaimen

szaimen commented Nov 26, 2026

Copy link
Copy Markdown
Collaborator Author

No, VMLOGS is where we want it to make it easy to find and visable.

Unfortunately as VMLOGS is www-data owned, this leaves the attack vector open as described in the summary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants