Cyberduck Mountain Duck CLI

#2892 closed defect (fixed)

Upload to Cloud Files

Reported by: anonymous Owned by: dkocher
Priority: normal Milestone: 3.1.2
Component: cloudfiles Version: 3.1.1
Severity: normal Keywords:
Cc: Architecture:
Platform:

Description

When I upload a .jpg with Cyberduck to Mosso Cloud Files and then try to view it with through the CDN with Firefox, it prompts me to download it.

When I do the same thing with a .png it works fine and displays in the browser like it should.

Can we get Cyberduck to the file type on upload appropriately on .jpg and any other files to they are served appropriately?

Change History (6)

comment:1 Changed on Jan 13, 2009 at 7:04:31 PM by dkocher

I properly get a image/jpeg in the Content-Type header returned when accessing a JPEG in my Mosso Container. Also when debugging Cyberduck, it does set the content type when uploading a JPEG for me. So I cannot replicate this. Will check with Mosso for possible reasons this might fail.

comment:2 Changed on Jan 13, 2009 at 7:04:46 PM by dkocher

  • Component changed from core to cloudfiles

comment:4 Changed on Jan 13, 2009 at 9:19:59 PM by ej@…

So with some more testing, it appears as if the the user uploads a JPEG with a file extension of .JPG or .JPEG (upper case), the content-type is not being set and defaulting to application/octet-stream.

This does not seem to be isolated to Cyberduck. Uploading through Mosso's web interface also breaks with a .JPEG file extension (although they did handle .JPG). I suspect the mime/content type determination is based on file extension rather than the files "magic number".

comment:5 Changed on Jan 13, 2009 at 9:24:54 PM by ej@…

Grep'ing through the Cyberduck source, I'm wondering if this is a case-senstivity issue? It seems like the source consults a lib/mime.types file. That file looks like it would map "jpeg jpe jpg" to content-type "image/jpeg". So if the source file is .JPG or .JPEG the match is failing?

comment:6 Changed on Jan 13, 2009 at 9:40:49 PM by dkocher

  • Milestone set to 3.1.2
  • Resolution set to fixed
  • Status changed from new to closed

In r4468. This fix also applies to content uploaded to S3.

Note: See TracTickets for help on using tickets.