Skip to main content
Menu
Advisories

Live Components Configured With a Custom Route Can Still Be Reached Through the Default Route

GHSA-XXRR-RHW9-37P7Published Updated GitHub

Description

#[AsLiveComponent(route: '...')] makes a live component send its requests to another route. The documentation suggests it so that the component lives under a specific firewall, for example. The default /_components/{_live_component}/{_live_action} route still served the component, though. A request to it rendered the component and ran its actions outside the firewall and the access rules of the configured route.

The request needs props signed by the application, which a page that rendered the component provides. Controller attributes on the component, like #[IsGranted], still applied.

Resolution

A live component is now only served by the route it is configured with.

The patches for this issue are available here for branch 2.x and here for branch 3.x.

Credits

We would like to thank Nicolas Grekas for reporting the issue.

Affected versions

References

GitHub · symfony/ux