Closed Bug 1292518 Opened 10 years ago Closed 10 years ago

Bad value in content-type with some pdf files

Categories

(Firefox :: Untriaged, defect)

47 Branch
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: tifenn.legoff, Unassigned, NeedInfo)

Details

Attachments

(1 file)

15.22 KB, application/rdf+xml
Details
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:47.0) Gecko/20100101 Firefox/47.0 Build ID: 20160609214634 Steps to reproduce: Hello, We use SOGo as a Webmail and Firefox (46 and 47) with Windows7 When we send some pdf files, some of them are unreadable for recipients and in send mailbox. The files seems be blank. PDF file type is the one who be concerned by this problem, we haven't this result with other file type. When we send this same file with an other navigator, we haven't this problem. This problem is aleatory. Actual results: When we received files, they seems be blank. If we inspect source code, we see : ------=_=-_OpenGroupware_org_NGMime-16013-1470296048.391775-5------ content-type: text/html content-disposition: attachment; filename="xxx.pdf" content-length: 244028 content-transfer-encoding: quoted-printable %PDF-1.4%=E2=E3=CF=D3 7 0 obj<</Linearized 1/L 106356/O 10/E 102350/N 1/T 106051/H [ 526 170]= >>endobj 29 0 obj<</DecodeParms<</Columns 5/Predictor 12>>/Encrypt 8 0 R/Filter/= FlateDecode/ID[<6A39EF7EFA80062DE6F8234C5A628319><CAADB934B1FC4E429587D= 6D76DF1021B>]/Index[7 34]/Info 6 0 R/Length 111/Prev 106052/Root 9 0 R/= Size 41/Type/XRef/W[1 3 1]>>stream ... The content-type value should be application/pdf and not text/html. We already had this problem with old Firefox version but that seems be resolved for some time but we have this problem again now. This problem is very aleatory, we haven't this problem with other navigator and with other files types. Expected results: The file should be upload with content-type: application/pdf value.
Have you double-checked on your local hard disk that the MIME type is correctly set for files that are affected by this problem?
Flags: needinfo?(tifenn.legoff)
Hello, Thanks for your answer, the MIME is correct for me, on Windows, he detect it's an Adobe Acrobat Document and on Linux, he detect it's a PDF document, version 1.4. I will ask to the person concerned if he got the same thing as me.
What is the exact, literal value for the MIME type that is shown by Microsoft Windows? Screenshot very welcome. :)
Hello, Sorry for the late. When I use mimetypes library with Python from my computer, I get this: >>> mimetypes.MimeTypes().guess_type("E:\Downloads\BOUES Va 4juillet2016_BOUES STEP VAL D ISERE 4JUILLET2016__ BASPA_25_4_LAB16_14818_1-1.pdf") ('application/pdf', None) >>> mimetypes.MimeTypes().guess_type("E:\Downloads\BOUES_VAseule1erjuin STEP AIME__ BASPA_15_1_LAB16_12479_1.pdf") ('application/pdf', None) >>> mimetypes.MimeTypes().guess_type("E:\Downloads\2013 KBis SEM.pdf") ('application/pdf', None) I will try to get more information from user. Thanks.
I think we have resolved the problem, we have rename file mimeTypes.rdf in mimeTypesSav.rdf, restart FireFox, try to send mail and we have no problem.
Attached file Bad mimeTypes.rdf
When we rename mimeTypes.rdf and restart Firefox, we have no more this problem.
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Resolution: --- → WORKSFORME
Marked as wfm based on comment 6
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: