WebP not using the file_create_url() API causes "Invalid security token" errors when serving WebP files from CDN

Created on 3 May 2020, almost 5 years ago
Updated 9 February 2023, about 2 years ago

Hi there. I see that CSS, JS and normal images works OK but some webp images gives 403 error:

https://cdn.mydomain.com/cdn/ff/gLX3QbC_KGrdldtdTUqOgpb7copVIjeg0Qrl8tD4VPo/1588373402/public/styles/articulos_lg_width/public/2020-04/myimage.webp

If I try to enter into the 403 blocked assets I can read 'Invalid security token' (because their don't have tokens). I'm in Nginx, no problems without the module. Correct path of working webp images:

https://cdn.mydomain.com/sites/default/files/styles/articulos_md_width/public/2020-04/myimage.webp?itok=xSxS3sgb

If you need more info please ask.

Thanks.

🐛 Bug report
Status

Needs work

Version

1.0

Component

Code

Created by

🇦🇷Argentina renguer0

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇧🇪Belgium tim-diels Belgium 🇧🇪

    @sokru, why a new patch that is different then what is in the MR? Without explanation and interdiff this is not the way to help with this issue.
    Hiding the patch as not relevant.

  • 🇧🇪Belgium tim-diels Belgium 🇧🇪

    I was a bit to fast to say the patch was not relevant. The patch is indeed working and the MR not.
    But when uploading a patch, a description on why and what would be helpful.

    So the MR does not work as DuaelFr stated and the patch from #20 works.

  • 🇧🇪Belgium tim-diels Belgium 🇧🇪
  • Status changed to Needs work about 2 years ago
  • 🇧🇪Belgium tim-diels Belgium 🇧🇪

    But unable to get this working with the patch.

Production build 0.71.5 2024