diff --git a/includes/common.inc b/includes/common.inc
index ea353d1..b771dee 100644
--- a/includes/common.inc
+++ b/includes/common.inc
@@ -448,11 +448,14 @@ function drupal_access_denied() {
  *   A float representing the maximum number of seconds the function call may
  *   take. The default is 30 seconds. If a timeout occurs, the error code is set
  *   to the HTTP_REQUEST_TIMEOUT constant.
+ * @param $ssl_version
+ *   The HTTPS certificate version used by the remote server. The value should
+ *   either be 'sslv2', 'sslv3' or 'tls'.
  * @return
  *   An object containing the HTTP request headers, response code, protocol,
  *   status message, headers, data and redirect status.
  */
-function drupal_http_request($url, $headers = array(), $method = 'GET', $data = NULL, $retry = 3, $timeout = 30.0) {
+function drupal_http_request($url, $headers = array(), $method = 'GET', $data = NULL, $retry = 3, $timeout = 30.0, $ssl_version = NULL) {
   global $db_prefix;
 
   $result = new stdClass();
@@ -485,7 +488,8 @@ function drupal_http_request($url, $headers = array(), $method = 'GET', $data =
       // Note: Only works for PHP 4.3 compiled with OpenSSL.
       $port = isset($uri['port']) ? $uri['port'] : 443;
       $host = $uri['host'] . ($port != 443 ? ':'. $port : '');
-      $fp = @fsockopen('ssl://'. $uri['host'], $port, $errno, $errstr, $timeout);
+      $transport = isset($ssl_version) ? $ssl_version . '://' : 'ssl://';
+      $fp = @fsockopen($transport . $uri['host'], $port, $errno, $errstr, $timeout);
       break;
     default:
       $result->error = 'invalid schema '. $uri['scheme'];
