Error connecting to Authorize.NET PHP SDK

I get the following error message after I uploaded my code on a live server

[error_message] => Error connecting to AuthorizeNet

I am using AIM, and the same code gives the correct answer on our development server. When I upload it to my live server, it does not work

+4
source share
2 answers

the first. Update your SDK library, there is a cert.pem file, which if obsolete will generate this error.

second. You can disable ssl checking to avoid this error. However, use option 1 first.

$yourIPNInstance->VERIFY_PEER = false
+4
source

An extension of Arnold Roa's answer above, which specifically refers to the Authorize.net IP network gateway.

VERIFY_PEER Authorize.net AIM.

, VERIFY_PEER = false TEMPORARY. .

$transaction = new AuthorizeNetAIM()
$transaction->VERIFY_PEER = false;

SDK . , , , cert.pem SDK/ .

AuthorizeNet

/​​ SDK , , , SDK , SHA1. lib/ssl/cert.pem , secure.authorize.net, , . .

lib/ssl/cert.pem cert.pem PHP SDK https://github.com/AuthorizeNet/sdk-php/blob/master/lib/ssl/cert.pem .

, cert.pem, ,

    $transaction->VERIFY_PEER = true;

, , Authorize.net ( 3-4 ), cert.pem SDK.

+4

Source: https://habr.com/ru/post/1543056/


All Articles