CVE-2026-49400: October CMS: PHP Object Injection via Backend Widget Session Storage

Published Sep 14, 2026
·
Updated

October System provides the system module for October Content Management System. Prior to versions 3.7.17 and 4.2.21, the backend SessionMaker trait stored widget session state as base64(serialize(...)) and consumed it with unserialize() without an allowedclasses restriction. Any code path that could write to a widget. session key with attacker-controlled bytes could trigger PHP object injection the next time the widget read its session state, allowing instantiation of arbitrary classes and reachable PHP gadget chains. This issue only affects installations running with cms.safemode enabled. Safe Mode is a niche opt-in feature, primarily used for demo installations and multi-tenant or shared-editor scenarios where untrusted users are deliberately granted access to the CMS markup editor. In standard production deployments Safe Mode is off, backend access is restricted to trusted administrators, and a markup editor can already execute arbitrary PHP directly. The session-write path that reaches this sink is gated by the Safe Mode sandbox, so installations without Safe Mode enabled are not exposed. Scope of impact is narrow even with Safe Mode enabled. The standard backend code paths that populate widget session state (search terms, sort options, selected IDs, filter values) wrap the input inside a known array shape before serializing, so user-supplied values never reach unserialize() as a controllable serialized payload. Exploitation requires the Safe Mode session-write path together with a suitable PHP gadget chain reachable from the installed dependency set. The hardening below removes the underlying object-injection sink so the class of issue is closed off regardless. The vulnerability has been patched in v3.7.17 and v4.2.21. Two changes were applied. Backend\Traits\SessionMaker now stores widget session state as plain JSON instead of base64(serialize(...)), eliminating the object-injection sink entirely for new writes. Reads transparently fall back to the legacy format for one upgrade cycle so existing sessions retain their saved widget state. The legacy unserialize() fallback path now sets allowedclasses => false, so even values written before the upgrade cannot instantiate objects. As a workaround, restrict CMS markup editing access to fully trusted administrators only, the standard October CMS recommendation for any deployment.

Other sources

The backend SessionMaker trait stored widget session state as base64(serialize(...)) and consumed it with unserialize() without an allowedclasses restriction. Any code path that could write to a widget. session key with attacker-controlled bytes could trigger PHP object injection the next time the widget read its session state, allowing instantiation of arbitrary classes and reachable PHP gadget chains.

This issue only affects installations running with cms.safemode enabled. Safe Mode is a niche opt-in feature, primarily used for demo installations and multi-tenant or shared-editor scenarios where untrusted users are deliberately granted access to the CMS markup editor. In standard production deployments Safe Mode is off, backend access is restricted to trusted administrators, and a markup editor can already execute arbitrary PHP directly. The session-write path that reaches this sink is gated by the Safe Mode sandbox, so installations without Safe Mode enabled are not exposed.

Scope of impact is narrow even with Safe Mode enabled. The standard backend code paths that populate widget session state (search terms, sort options, selected IDs, filter values) wrap the input inside a known array shape before serializing, so user-supplied values never reach unserialize() as a controllable serialized payload. Exploitation requires the Safe Mode session-write path together with a suitable PHP gadget chain reachable from the installed dependency set. The hardening below removes the underlying object-injection sink so the class of issue is closed off regardless.

Impact - Arbitrary PHP code execution as the web server user, via a gadget chain deserialized from a widget session key, triggered the next time the affected widget is rendered - Requires cms.safemode to be enabled, and a backend user with CMS markup editing access who is not intended to be trusted as a full administrator - A suitable PHP gadget chain must be reachable from the installed dependency set - Not exploitable when Safe Mode is disabled

Patches The vulnerability has been patched in v3.7.17 and v4.2.21. Two changes were applied:

- Backend\Traits\SessionMaker now stores widget session state as plain JSON instead of base64(serialize(...)), eliminating the object-injection sink entirely for new writes. Reads transparently fall back to the legacy format for one upgrade cycle so existing sessions retain their saved widget state. - The legacy unserialize() fallback path now sets allowedclasses => false, so even values written before the upgrade cannot instantiate objects.

Workarounds If upgrading immediately is not possible, restrict CMS markup editing access to fully trusted administrators only, the standard October CMS recommendation for any deployment.

References - Reported by EndlssNightmare

GitHub

Affected Software

6 affected componentsFixes available
October CMS October CMS>0<=3.7.16
October CMS October CMS>0<=4.2.20
October CMS October CMS<3.7.17
October CMS October CMS<4.2.21
composer/october/system>=4.0.0<4.2.23
4.2.23
composer/october/system<3.7.17
3.7.17

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade composer/october/system to a version that resolves this vulnerability.

    Fixed in 4.2.23
  2. Upgrade

    Upgrade composer/october/system to a version that resolves this vulnerability.

    Fixed in 3.7.17
  3. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 3.7.17
  4. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 4.2.21
  5. Configuration

    If upgrading immediately is not possible, restrict CMS markup editor access to fully trusted administrators only (the standard October CMS recommendation), since this issue only affects installations running with `cms.safe_mode` enabled and with untrusted users who can access the CMS markup editor.

    October CMS cms.safe_mode = enabled only for trusted administrators

Event History

Sep 14, 2026
Advisory Published
via GitHub·05:08 PM
Data Sourced
via GitHub·05:08 PM
DescriptionSeverityWeaknessAffected Software
CVE Published
via MITRE·05:15 PM
Data Sourced
via MITRE·05:15 PM
DescriptionSeverityWeakness

Frequently Asked Questions

1

Which installations are exposed?

Only installations with cms.safe_mode enabled are affected. Standard production deployments with Safe Mode disabled are not exposed through this session-write path.

2

What does an attacker need to exploit this issue?

The attacker needs a way to write attacker-controlled bytes to a widget.* session key, then cause the relevant widget to read that session state. Exploitation also depends on reachable PHP gadget chains.

3

How can I remediate or reduce exposure?

Upgrade to October CMS 3.7.17 or 4.2.21, as applicable. If upgrading is not immediately possible, disabling cms.safe_mode removes the affected exposure path described here.

4

How can I determine whether action is needed?

Check whether cms.safe_mode is enabled and whether the installation is running a version prior to 3.7.17 or 4.2.21. If Safe Mode is off, this issue does not affect the installation.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203