amazonwebservices/aws-sdk-for-php — pull request #42 by apinstein (2012-09-21 14:52:18+00:00)
Title: Fix bug caused by some SSL implementations with bucket names that have dots in them.

cURL, when compiled with modern versions of libssh2/OpenSSL, uses
stricter wildcard SSL CN matching. This causes bucketnames with dots in
them to generate SSL failures like so:

cURL error: SSL: certificate subject name '*.s3.amazonaws.com' does
not match target host name 'sub.domain.s3.amazonaws.com' (cURL
error code 51)

This patch causes the S3 authenticate() method to auto-detect this
situation and route around it securely by using path-style URL's for
making API calls.

Path-style URL's look like s3.amazonaws.com/[bucket-name]/key and thus
have no problem passing the strict SSL name matching algorithm.