Unsupported SSL protocol version in PayPal-PHP-SDK
<p>I used this snippet in my application in Symfony2 + KMJPayPalBridgeBundle</p>

<p><a href="http://paypal.github.io/PayPal-PHP-SDK/sample/doc/payments/CreatePaymentUsingPayPal.html" rel="nofollow">http://paypal.github.io/PayPal-PHP-SDK/sample/doc/payments/CreatePaymentUsingPayPal.html</a></p>

<p>Few months ago it was all good but now I'm getting "Unsupported SSL protocol version" error.</p>

<p>Controller code</p>

<pre><code>public function testAction()
{
    $paypal = $this-&gt;get('paypal');
    $apiContext = $paypal-&gt;getApiContext();

    $payer = new Payer(); 
    $payer-&gt;setPaymentMethod("paypal");

    $item1 = new Item(); 
    $item1-&gt;setName('Ground Coffee 40 oz') 
            -&gt;setCurrency('USD') 
            -&gt;setQuantity(1) 
            -&gt;setSku("123123"); // Similar to `item_number` in Classic API -&gt;setPrice(7.5); 
    $item2 = new Item(); 
    $item2-&gt;setName('Granola bars') 
            -&gt;setCurrency('USD') 
            -&gt;setQuantity(5) 
            -&gt;setSku("321321"); // Similar to `item_number` in Classic API -&gt;setPrice(2);

    $itemList = new ItemList(); 
    $itemList-&gt;setItems(array($item1, $item2));

    $details = new Details(); 
    $details-&gt;setShipping(1.2) 
            -&gt;setTax(1.3) 
            -&gt;setSubtotal(17.50);
    $amount = new Amount(); 
    $amount-&gt;setCurrency("USD") 
            -&gt;setTotal(20) 
            -&gt;setDetails($details);

    $transaction = new Transaction(); 
    $transaction-&gt;setAmount($amount) 
                -&gt;setItemList($itemList) 
                -&gt;setDescription("Payment description") 
                -&gt;setInvoiceNumber(uniqid());

    $baseUrl = "http://development.local"; 
    $redirectUrls = new RedirectUrls(); 
    $redirectUrls-&gt;setReturnUrl("$baseUrl/ExecutePayment.php?success=true") 
                -&gt;setCancelUrl("$baseUrl/ExecutePayment.php?success=false");

    $payment = new Payment(); 
    $payment-&gt;setIntent("sale") 
            -&gt;setPayer($payer) 
            -&gt;setRedirectUrls($redirectUrls) 
            -&gt;setTransactions(array($transaction));

    $request = clone $payment;
    try { $payment-&gt;create($apiContext); } catch (Exception $ex) {
        ResultPrinter::printError("Created Payment Using PayPal. Please visit the URL to Approve.", 
                                    "Payment", null, $request, $ex); exit(1); 
    }
    $approvalUrl = $payment-&gt;getApprovalLink();
    ResultPrinter::printResult("Created Payment Using PayPal. Please visit the URL to Approve.", 
                                    "Payment", "&lt;a href='$approvalUrl' &gt;$approvalUrl&lt;/a&gt;", $request, $payment); 

    return array();
}
</code></pre>