Closed (fixed)
Project:
CDN
Version:
7.x-2.x-dev
Component:
Origin Pull mode
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
7 Feb 2012 at 11:53 UTC
Updated:
24 Feb 2012 at 18:30 UTC
After calling getExernalWrapper(), CDN decodes the uri to perform file-based operations. The URI is never re-encoded though, causing file-names with funky characters (or Unicode) to not be valid. Most browsers seem to still accept them, but stricter tools complain, and some files will break even in the less strict browsers.
For example, on Ubuntu for a file named 'file?&©2012.png' (and yes, unfortunately we've got creative editors who upload all kinds of insanely-named files ;) ):
| Comment | File | Size | Author |
|---|---|---|---|
| cdn-uri-encoding.patch | 1.11 KB | mr.baileys |
Comments
Comment #1
wim leersHah, good catch. Strange that I've never run into this problem!
Comment #2
wim leersThanks again! :) Committed.
D7: http://drupalcode.org/project/cdn.git/commit/b521cdb
D6: http://drupalcode.org/project/cdn.git/commit/4fdce7e
Comment #3
wim leersFollow-up patch for D6: http://drupalcode.org/project/cdn.git/commit/e4884cb. D6 should use drupal_urlencode(), not drupal_encode_path()…