Repository navigation
docs(hosting): document security best practices and incident response #2639
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Jonas Elfering (keulinho)
merged 11 commits into
main
from
codex/security-best-practices
Oct 22, 2026
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
44487cf
docs(hosting): add security best practices
keulinho d5ac606
docs(security): recommend PHP 8.4 PDO parser hardening
keulinho 2ad613c
docs(security): add cyber attack response guidance
keulinho c3c34f6
docs(security): remove incident response specialist references
keulinho f9a1ef5
docs(security): remove general password change requirement
keulinho c3025ee
docs(security): mention AI assistance for incident log analysis
keulinho 1fdf801
docs(security): clarify SaaS and PaaS Native responsibilities
keulinho 4d46c34
docs(security): clarify incident support for Community Edition
keulinho 3b40424
docs(security): prioritize hosting provider and agency incident support
keulinho bc19c48
docs(security): link incident support to ticket creation
keulinho b3657dc
docs(security): spell cyberattack as one word
keulinho File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
77 changes: 77 additions & 0 deletions
77
guides/hosting/installation-updates/security-best-practices/incident-response.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,77 @@ | ||
| --- | ||
| nav: | ||
| title: Responding to a Cyberattack | ||
| position: 20 | ||
|
|
||
| --- | ||
|
|
||
| # Responding to a Cyberattack | ||
|
|
||
| As soon as you suspect an attack is in progress, stop public traffic to the affected shop and isolate the affected systems. | ||
| Work with your hosting provider to block access at the firewall or load balancer, including access to the Administration and APIs. | ||
| Do not rely on the storefront maintenance page alone to contain an attack. | ||
|
|
||
| ## Get help and preserve evidence | ||
|
|
||
| If you suspect an attack, contact your hosting provider and agency first for help with containment, investigation, and recovery. | ||
| Shopware offers dedicated support options for security incidents, including for Community Edition users without a support subscription. | ||
| Contact [Shopware Support](https://support.shopware.com/create-ticket) to discuss the assistance available for your situation. | ||
| You do not need to wait until your investigation is complete. | ||
|
|
||
| Preserve logs and forensic snapshots before deleting files, restarting services, or restoring backups. | ||
| Record when you first noticed the attack and the actions you take. | ||
| Do not delay containment while collecting evidence. | ||
|
|
||
| ## Investigate the entry point and impact | ||
|
|
||
| Establish what happened, including: | ||
|
|
||
| - How and when the attacker first entered the system, for example through a vulnerability or stolen credentials. | ||
| - What level of access they gained, including Administration access, database access, or the ability to execute code on the server. | ||
| - What they did with that access, including changes to files, configuration, accounts, orders, or payment flows, and access to or theft of customer data. | ||
| - Whether other systems or connected services were affected. | ||
|
|
||
| Look for anything that could give the attacker persistent access, such as backdoors, modified plugins, scheduled tasks, additional administrator accounts, or newly created integration credentials. | ||
| The absence of obvious changes or log entries does not establish that the system is clean. | ||
|
|
||
| AI agents can be particularly helpful for analysing large volumes of logs, identifying suspicious patterns, and reconstructing the attack timeline. | ||
| Validate their findings against the original evidence and redact secrets and customer data before sending logs to an external service. | ||
|
|
||
| ## Remove attacker access and recover | ||
|
|
||
| Once you understand the entry point, the access gained, and the attacker's actions, remove unauthorized access and reverse the malicious changes. | ||
| Fix the weakness or compromised account that allowed the attack; removing a backdoor without closing the entry point leaves the shop exposed. | ||
|
|
||
| ::: warning | ||
| If you suspect remote code execution, assume the entire affected system is compromised. | ||
| Deleting visible backdoors or installing a security update is not enough to restore trust. | ||
| The safe recovery path is to rebuild affected systems from trusted images and restore a verified backup from before the earliest suspected compromise. | ||
| Check that the backup is clean: the attack may have started before you first noticed it. | ||
| ::: | ||
|
|
||
| Apply the required security fixes to Shopware, extensions, dependencies, and infrastructure before making the recovered shop publicly accessible. | ||
|
|
||
| ## Rotate secrets before reopening | ||
|
|
||
| From a trusted device and in the recovered environment, rotate credentials and secrets the attacker may have accessed. | ||
| These can include Shopware administrator and integration credentials, database passwords, app secrets, hosting credentials, and keys for external services. | ||
| Invalidate existing sessions and tokens. | ||
| Make sure restoring a backup does not reintroduce compromised credentials or unauthorized accounts. | ||
|
|
||
| Restore public traffic only after the entry point is closed, persistent access has been removed, recovery and credential changes are complete, and the shop has been tested. | ||
| Monitor for signs of renewed attacker activity after reopening. | ||
|
|
||
| ## Check legal obligations promptly | ||
|
|
||
| Especially if customer data may have been affected, consult a legal advisor promptly about your obligations, including possible notifications to affected customers, data protection authorities, or other relevant authorities. | ||
| Reporting deadlines may apply before the investigation is complete; do not wait until recovery is finished to seek advice. | ||
| For personal data breaches under the GDPR, see the [European Data Protection Board's guidance](https://www.edpb.europa.eu/sme/assess-the-risks/data-breaches_en). | ||
|
|
||
| ## Share your findings with Shopware | ||
|
|
||
| Reach out to [Shopware Support](https://support.shopware.com/create-ticket) after the incident as well, even if you did not contact us during the active attack. | ||
| Share the affected versions, timeline, entry point, access gained, attacker actions, and recovery measures as far as you have established them. | ||
| This information helps us improve protections and keep the whole Shopware ecosystem safe. | ||
|
|
||
| If you discover a previously unknown vulnerability, report it through our [security reporting page](https://www.shopware.com/en/contact/security-reporting/). | ||
| Use private support or security-reporting channels for incident details, and avoid sending unnecessary customer data or secrets. | ||
70 changes: 70 additions & 0 deletions
70
guides/hosting/installation-updates/security-best-practices/index.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,70 @@ | ||
| --- | ||
| nav: | ||
| title: Security Best Practices | ||
| position: 25 | ||
|
|
||
| --- | ||
|
|
||
| # Security Best Practices | ||
|
|
||
| This guide describes recommended security practices and how responsibilities differ by hosting model. | ||
| For a more detailed list of Shopware's security mechanisms and how to configure them, see the [security reference](../../../../resources/references/security.md). | ||
| If you suspect an attack, follow the [incident response guide](incident-response.md) immediately. | ||
|
|
||
| ## Understand your responsibilities | ||
|
|
||
| With **Shopware SaaS**, Shopware operates and secures the platform and its infrastructure, including automatically applying platform updates and security patches. | ||
| You do not need to manage servers or install the Security Plugin yourself. | ||
|
|
||
| With **[Shopware PaaS Native](../../../../products/paas/shopware/index.md)**, Shopware manages the underlying infrastructure, including servers, networking, managed databases, and platform backups. | ||
| A [web application firewall](../../../../products/paas/shopware/cdn/security-features.md) is enabled and configured by default. | ||
| You or your agency remain responsible for the application: testing and deploying [Shopware updates](../../../../products/paas/shopware/guides/update-shopware.md), Security Plugin and other extension updates, Composer dependency updates, and security fixes to your custom code. | ||
| Managed infrastructure and a firewall do not replace these application updates. | ||
|
|
||
| In both models, you remain responsible for your configuration, access and user management, and the security of external apps and integrations you operate or connect. | ||
| See section 29.2 of the [Shopware terms and conditions](https://www.shopware.com/en/gtc/) for the responsibility boundary. | ||
| For **self-hosted installations**, you or your hosting provider also manage infrastructure security. | ||
|
|
||
| The application update and extension recommendations below apply to self-hosted and PaaS Native shops. | ||
| Infrastructure maintenance applies to the services you operate yourself. | ||
|
|
||
| ## Stay on a supported Shopware version | ||
|
|
||
| Run a Shopware version that is still receiving security updates. | ||
| Check the [release calendar](https://developer.shopware.com/release-notes/#release-calendar) to see which versions are supported and how security fixes are delivered. | ||
| If your Shopware version is approaching its end of life, plan and complete an upgrade to a supported version before security support ends. | ||
| Apply security updates promptly and keep your extensions and Composer dependencies up to date. | ||
|
|
||
| ## Keep the Security Plugin installed | ||
|
|
||
| Always keep a compatible version of the Security Plugin installed, activated, and up to date, even when Shopware itself is fully updated. | ||
| Having the plugin in place makes it easier to apply the next security update without waiting for a complete platform update. | ||
| The plugin does not replace regular Shopware updates or extend security support for versions that have reached their end of life. | ||
|
|
||
| See the [Security Plugin](security-plugin.md) guide for compatibility, installation, and details about the fixes it provides. | ||
|
|
||
| ## Keep your infrastructure supported | ||
|
|
||
| For infrastructure you operate yourself, run supported versions of your operating system, PHP, database, web server, search engine, and cache or message queue services. | ||
|
Check warning on line 48 in guides/hosting/installation-updates/security-best-practices/index.md
|
||
| Apply their vendors' security updates and check the [recommended stack and supported versions](../../index.md#recommended-stack-and-supported-versions) for compatibility with Shopware. | ||
|
|
||
| Use PHP 8.4 or later on a compatible Shopware release, and keep it updated to the latest patch version of a supported PHP branch. | ||
| PHP 8.4 introduced [driver-specific PDO SQL parsers](https://wiki.php.net/rfc/pdo_driver_specific_parsers), which protect against some [SQL injection techniques caused by parsing mismatches in older PHP versions](https://www.slcyber.io/research/a-novel-technique-for-sql-injection-in-pdos-prepared-statements). | ||
| This is an additional protection layer and does not replace security fixes in Shopware or its extensions. | ||
| On PaaS Native, select supported, compatible PHP and database versions in your [application configuration](../../../../products/paas/shopware/fundamentals/application-yaml.md) and deploy the change. | ||
|
|
||
| ## Manage extensions through deployments | ||
|
|
||
| Consider disabling runtime extension management in production and managing extensions solely through Composer and a separate build and deployment process. | ||
| On PaaS Native, runtime extension management is already disabled; extensions must be managed through Composer and deployments, as described in the [PaaS Native FAQ](../../../../products/paas/shopware/faq.md). | ||
|
|
||
| Runtime plugin installation allows PHP code to be added to the running shop. | ||
| An attacker who gains access to an account with extension installation privileges can use this capability to execute malicious code on the shop server. | ||
| Disabling runtime extension management reduces this route from account compromise to remote code execution. | ||
|
|
||
| As an additional benefit, managing extensions through deployments makes it easier to test new plugins and plugin updates in staging and catch compatibility issues before they affect your production shop. | ||
|
|
||
| See [Extension Management](../extension-management.md) for the Composer workflow and the configuration to make the Administration's Extension Manager read-only. | ||
|
|
||
| Use this deployment process for Security Plugin updates as well, and treat relevant security releases as urgent. | ||
| Test and deploy them as soon as possible; do not wait for the next routine feature release or maintenance window. | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.