ZF-6549: Zend_Service_Amazon_S3_Stream incorrectly parses object names
Description
Location: Zend_Service_Amazon_S3_Stream-> _getNamePart()
Problem: Adds an addition / between the host and path when forming the S3 object name.
Example: s3://bucket-name/object-name returns a name of bucket-name//object-name
Impact: Other calls such as getInfo() fail as the object is not found.
Cause: parse_url includes / in the 'path', there for a second "/" separator between the $url['host'] and $url['path'] is not required
Suggested fix Current line: return $url['path'] ? $url['host'].'/'.$url['path'] : $url['host']; Proposed line: return $url['path'] ? $url['host'].$url['path'] : $url['host'];
Hope this helps Glenn
Comments
Posted by Matthew Weier O'Phinney (matthew) on 2009-05-06T04:45:08.000+0000
Assigning to Stas.
Posted by Stanislav Malyshev (stas) on 2009-05-08T13:01:13.000+0000
fixed, thanks