the-djmaze / snappymail

Simple, modern & fast web-based email client
https://snappymail.eu
GNU Affero General Public License v3.0
1.01k stars 121 forks source link

Attached inline image not loading #566

Closed relikd closed 1 year ago

relikd commented 1 year ago

Describe the bug An inline image attachement is not displayed properly / not at all:

screen

For comparison, the same email is displayed fine in Rainloop.

But this issue gets tricky. The image above is after I impersonated a different person (Nextcloud), using the email account of the other person. When I open the same email account from my SnappyMail tab, I see the following:

screen2

As you can see, at least the attachement indicator is shown. However, clicking the image does not open the preview. Instead a blank page loads: /apps/snappymail/run/?/Raw/&q[]=/0/Download/&q[]=/b.... Similarly, the zip download fails and opens another blank URL.

I have not marked this issue with the Nextcloud tag, as I dont know if this is an issue of the impersonate plugin. This could very well be an issue of admin vs. non-admin user.

Expected behavior

The image should actually load inline and be immediatelly visible to the user.

Please complete the following information:

relikd commented 1 year ago

... all of the attachements seem to be broken :(

the-djmaze commented 1 year ago

Issue was caused due to a change in secure filenames to store in Nextcloud. But will also affect standalone releases.

Seems i missed one to fix.

simonbuehler commented 1 year ago

great its working with the fix, thanks!

simonbuehler commented 1 year ago

ok, for some attachemnts i still get

[2022-10-20 14:40:32.317][1514f651] [ERROR]: MailSo-Base-Exceptions-InvalidArgumentException (Folders.php ~ 303)
[2022-10-20 14:40:32.317][1514f651] PATHS[ERROR]: Array
(
    [0] => Raw
    [1] => 0
    [2] => View
    [3] => b3BlbnNzbA.euPIkNeIOTvTqX9X-H-lhQ.ITRU-LTSTmriBjkHByALfQ9yZ3OT_AngUGYHEV-N2hKNoGSWu4qA6e-ul8hooe4FQi9xhwG-OjWTGMtIJbyh_5fuIX0pKUpy2uvK4K3BsySHNVfR35e9I8jK3VT9fJGkVxNCv7O-3sIUOmCC-SRyrcBkY0CS3_HCvSjxjM_KYmWrk6F5eTAim6fGonqB4kd0_1quRPehsHYpzyEuXlpPyY1FSQTR0WeL8PKie_eq1uEBvWtS31oqWsK5RdVHsQBHzvMf3drsuuUDoOO-374K-yh64-RknRlePwSXqvtfQ1A
)
relikd commented 1 year ago

Some improvement but still broken in 2.19.2. Now I can download the file, but the preview button still does not work / redirects to the empty page. And the inline image is still not loaded / displayed. Text stays "Image.jpeg"

relikd commented 1 year ago

And the attachement preview button also does not work yet (the two images above). Comparing admin user vs. non-admin

the-djmaze commented 1 year ago
  1. when there is a chain after the attachment size, it has no preview. Because it is inline and chained to the message content and shown there. Click on it and a new browser tab opens with the image.
  2. it works when snappymail cache is emptied and your browser cache
relikd commented 1 year ago

Ahh, perfect. Yes, indeed. It just worked after a while. 👍 (just for clarification: I was talking about the preview after clicking the eye-button. But now that also works as expected)

simonbuehler commented 1 year ago

ok, for some attachemnts i still get

[2022-10-20 14:40:32.317][1514f651] [ERROR]: MailSo-Base-Exceptions-InvalidArgumentException (Folders.php ~ 303)
[2022-10-20 14:40:32.317][1514f651] PATHS[ERROR]: Array
(
    [0] => Raw
    [1] => 0
    [2] => View
    [3] => b3BlbnNzbA.euPIkNeIOTvTqX9X-H-lhQ.ITRU-LTSTmriBjkHByALfQ9yZ3OT_AngUGYHEV-N2hKNoGSWu4qA6e-ul8hooe4FQi9xhwG-OjWTGMtIJbyh_5fuIX0pKUpy2uvK4K3BsySHNVfR35e9I8jK3VT9fJGkVxNCv7O-3sIUOmCC-SRyrcBkY0CS3_HCvSjxjM_KYmWrk6F5eTAim6fGonqB4kd0_1quRPehsHYpzyEuXlpPyY1FSQTR0WeL8PKie_eq1uEBvWtS31oqWsK5RdVHsQBHzvMf3drsuuUDoOO-374K-yh64-RknRlePwSXqvtfQ1A
)

is this another issue?