Commit 4b555076 authored by Reed Loden's avatar Reed Loden

Bug 453425 - Send "X-Content-Type-Options: nosniff" header when displaying…

Bug 453425 - Send "X-Content-Type-Options: nosniff" header when displaying attachments so IE8 doesn't try to sniff the content type. [r=LpSolit a=LpSolit]
parent 8ba061b3
...@@ -338,7 +338,8 @@ sub view { ...@@ -338,7 +338,8 @@ sub view {
} }
print $cgi->header(-type=>"$contenttype; name=\"$filename\"", print $cgi->header(-type=>"$contenttype; name=\"$filename\"",
-content_disposition=> "$disposition; filename=\"$filename\"", -content_disposition=> "$disposition; filename=\"$filename\"",
-content_length => $attachment->datasize); -content_length => $attachment->datasize,
-x_content_type_options => "nosniff");
disable_utf8(); disable_utf8();
print $attachment->data; print $attachment->data;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment