Skip to content

Security related fixes#3723

Merged
bobvandevijver merged 4 commits into
6.1from
chore/updates
May 16, 2026
Merged

Security related fixes#3723
bobvandevijver merged 4 commits into
6.1from
chore/updates

Conversation

@bobvandevijver
Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings May 16, 2026 19:03
@bobvandevijver bobvandevijver changed the base branch from 6.2 to 6.1 May 16, 2026 19:03
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces security hardening by enabling Symfony trusted host validation by default and replacing ad-hoc SVG JavaScript checks with a dedicated SVG sanitization library during uploads.

Changes:

  • Add framework.trusted_hosts configuration driven by SYMFONY_TRUSTED_HOSTS (including a YAML migration).
  • Replace the SVG upload validation callback with enshrined/svg-sanitize-based sanitization that rewrites the temporary upload.
  • Document and announce the security-related changes in .env and CHANGELOG.md.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 8 comments.

Show a summary per file
File Description
yaml-migrations/m_2026-05-14-framework.yaml Adds a migration to introduce trusted hosts config into config/packages/framework.yaml on upgrade.
src/Controller/Backend/Async/UploadController.php Switches SVG validation to library-based sanitization and writes sanitized SVG back to the temp file.
config/packages/framework.yaml Enables framework.trusted_hosts with an env-driven pattern.
composer.json Adds the enshrined/svg-sanitize dependency used by the upload controller.
CHANGELOG.md Adds a 6.1.3 security release entry describing the changes.
.env Adds guidance (commented) for setting SYMFONY_TRUSTED_HOSTS.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Controller/Backend/Async/UploadController.php Outdated
Comment thread src/Controller/Backend/Async/UploadController.php
Comment thread src/Controller/Backend/Async/UploadController.php
Comment thread config/packages/framework.yaml
Comment thread yaml-migrations/m_2026-05-14-framework.yaml
Comment thread CHANGELOG.md Outdated
Comment thread CHANGELOG.md
Comment thread .env Outdated
@bobvandevijver bobvandevijver merged commit ec33d5e into 6.1 May 16, 2026
35 checks passed
@bobvandevijver bobvandevijver deleted the chore/updates branch May 16, 2026 19:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants