David M. Johnson created ROL-2184:
-------------------------------------

             Summary: Pasted desktop images disappear from published entries
                 Key: ROL-2184
                 URL: https://issues.apache.org/jira/browse/ROL-2184
             Project: Apache Roller
          Issue Type: Bug
          Components: Themes and Macros, User Interface - Weblog Editor, Media 
files / uploads
            Reporter: David M. Johnson


Reported against 6.1.6.

If you drag a desktop image into the rich text editor, it becomes a {{data:}} 
image. It shows while you edit, but the published entry leaves it out: 
rendering strips {{data:}} images, and the bundled themes' CSP blocks them. Fix 
both paths:

# *Upload (preferred).* When upload is available, upload new pasted or dropped 
images as media files. Convert stored inline images the next time an entry is 
saved. Leave remote images unchanged. Use Roller's existing checks for upload 
permission, file type, size and quota.
# *Inline fallback.* When upload is unavailable, or when the new global "inline 
images" preference is set, store the image inline. Accept only strictly 
validated PNG, JPEG and GIF data images, with a 60,000-byte field limit.

h3. Acceptance
* New pastes and drops, and edits of old entries, produce working published 
images on both paths. Check the draft and publish flows.
* A failed upload, or an invalid or oversized inline image, shows a clear 
message. It never silently publishes a missing image.
* Valid inline images render in the bundled themes. Non-image data URLs and 
active content stay blocked.
* The docs say that custom themes with their own CSP must allow {{data:}} under 
{{img-src}}.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to