discourse/lib/file_store
Martin Brennan 72f139191e
FIX: S3 store has_been_uploaded? was not taking into account s3 bucket path (#9810)
In some cases, between Discourse forums the hostname of a URL could match if they are hosting S3 files on the same bucket but the S3 bucket path might not. So e.g. https://testbucket.somesite.com/testpath/some/file/url.png vs https://testbucket.somesite.com/prodpath/some/file/url.png. So has_been_uploaded? was returning true for the second URL, even though it may have been uploaded on a different Discourse forum.

This is a very rare case but must be accounted for, because this impacts UrlHelper.is_local which mistakenly thinks the file has already been downloaded and thus allows the URL to be cooked, where we want to return the full URL to be downloaded using PullHotlinkedImages.
2020-05-20 10:40:38 +10:00
..
base_store.rb FEATURE: extend duration allowed for download 2020-05-15 12:45:47 +10:00
local_store.rb REFACTOR: Restoring of backups and migration of uploads to S3 2020-01-14 11:41:35 +01:00
s3_store.rb FIX: S3 store has_been_uploaded? was not taking into account s3 bucket path (#9810) 2020-05-20 10:40:38 +10:00
to_s3_migration.rb FIX: Restore to S3 didn't work without env variables 2020-04-19 20:24:40 +02:00