- Package
- drupal/menu_link_attributes
- Fixed in
- 1.8.0
- Published
- Wed 7 Oct 2026, 17:34 LisbonUpdated Mon 26 Oct 2026, 04:26 Lisbon
In plain words
The module does not sufficiently sanitise HTML attributes applied to menu link container elements (<li>), allowing an attacker to apply unsafe attributes. The attacker must have both “Administer menus and menu links” and “Use menu link attributes” permissions, and an unsafe container attribute must already have been configured by someone with “Administer menu link attributes” permission. The default configuration is not affected.
Am I affected?
Look for drupal/menu_link_attributes and its version in composer.lock. The advisory lists 1.8.0 as fixed but gives no affected version range. Check whether an unsafe container attribute has been configured and whether any role has both “Administer menus and menu links” and “Use menu link attributes” permissions.
What to do
Check which version you have, then update to a fixed release for your branch (1.8.0):
composer show drupal/menu_link_attributes | grep versions
composer update drupal/menu_link_attributes
If your version constraint in composer.json keeps you below a fixed release, raise it first. Whether your configuration is affected, and the exact version ranges, are in the advisory itself.
If you cannot update yet
The advisory identifies the default configuration and the required permissions as mitigating factors, but gives no specific workaround steps.
The advisory's description
This module enables you to add HTML attributes to menu links and their container elements (<li>).
The module doesn't sufficiently sanitize the attributes it applies to menu link container elements.
This vulnerability is mitigated by the fact that an attacker must have a role with the permissions "Administer menus and menu links" and "Use menu link attributes". In addition, an unsafe container attribute must already be configured by a user with the restricted permission "Administer menu link attributes". The default configuration is not affected.
The advisory
- OSV.dev: DRUPAL-CONTRIB-2026-209
- The week's digest, with the other advisories from 5 Oct 2026
- All advisories for drupal/menu_link_attributes