Uploaded zip file is renamed


(Gezim Hoxha) #1

I uploaded files named zip-recipes-friend.zip but when users download the file, it’s name is <GUID>.zip.

I’m fairly certain this is new but not 100% sure. Did my installation get compromised or was this a change that actually happened?

If this is an intended behaviour, what’s the reason behind it?


#2

This is indeed a bug,

and it should have been fixed by @zogstrip!

Could you try upgrading your instance to latest and see if the problem persists? (since this won’t automatically fix the filenames of existing uploads, my bad, misread a followup on the linked topic, see @michaeld’s comment below)


(Michael - DiscourseHosting.com) #3

yes it does, this is not about how it’s being stored but what filename is communicated to the browser upon download.


(Ivan Rapekas) #4

I do a migration from one forum engine to Discourse and this problem has been following me since beta9 approximately. Seems that only new deployed image is free of the problem of the naming of downloaded files.

Actually, I don’t know where I did a mistake, and how to report this problem right way. I just deployed the latest Discourse image, then migrated attachments from an old forum to the new one via API, then both migrated and new uploaded files are downloaded with <hash> in the filename.

I know, my case is specific, therefore my post is just a little confirmation that the problem still persists in some cases.


(Jeff Atwood) #5

Let’s see. Here’s a text file I uploaded called funky-biscuits.txt.

funky-biscuits.txt (18 Bytes)

All correct on our end. So you need to update your instance to latest code.


(Jeff Atwood) #6