Fixed
Project:
Entity Embed
Version:
8.x-1.x-dev
Component:
User interface
Priority:
Minor
Category:
Bug report
Assigned:
Reporter:
Created:
16 Nov 2023 at 21:03 UTC
Updated:
19 Nov 2026 at 20:40 UTC
Jump to comment: Most recent, Most recent file


Comments
Comment #2
edmoreta commentedRemoving the escape from the label has resolved the issue for me. Thanks!
Comment #3
mortona2k commentedHere's a patch from the issue fork.
What's next on this?
Comment #6
baluertlThe content of this patch has been committed (53384f76) earlier to a separate branch by the module maintainer, and now an MR (!40) has been opened for better visibility.
Tested, the patch does fix the escaping of special characters indeed:

Comment #7
dave reidI updated this one to mention the browser test added since the first draft. The XSS explanation is already posted on !40 itself, so this comment links to it.
I've rebased !40 onto 8.x-1.x and added tests: a kernel test,
DrupalEntityCKEditor5PluginTest, that fails without the fix, and a browser test,CKEditor5IntegrationTest::testButtonLabelIsText(), confirming that a label containing HTML shows as text and can't run script (details in the MR).A correction to the steps to reproduce: the double-escaped label shows in the editor itself (hover over the embed button while editing content), not on the text format's settings page. That page displays labels correctly, since core's admin UI inserts them as HTML, so
DrupalEntityDeriverkeeps escaping them there.Thanks @baluertl and @mortona2k for testing and moving this along.
Comment #9
dave reid