Metacat creates an Invalid Content-Disposition value for some filenames
Related to #2566, Metacat is now creating
Content-Disposition HTTP headers with filenames either found in an objects' SystemMetadata, or constructing one from the identifier in it's absence. We've run into a minor issue when the stated filename in the SystemMetadata contains commas. For example, with:
notice that the filename has commas. So, visiting:
ERR_RESPONSE_HEADERS_MULTIPLE_CONTENT_DISPOSITION in Chrome 52 on Mac. With FF on Mac, the file gets downloaded, but with the wrong name. It is truncated with a name of just 'Modeled '. Either way, I think the solution is to replace commas with underscores for filenames when setting the
Content-Disposition header. I tried to figure out what was 'allowed'. RFC 2616 says the
filename-parm is a 'quoted-string'. So, perhaps instead of doing character replacements, we just quote all filenames prior to building the header.