IPeCompany / SmsPanelV2.Laravel

Laravel Package for new webapp v2
MIT License
11 stars 4 forks source link

cURL error 60: SSL certificate problem: unable to get local issuer certificate #2

Open MojSkin opened 2 years ago

MojSkin commented 2 years ago

I faced this error when I want to call any Send methods. I've checked any stackoverflow solutions with local certificate, but was not useful.

Is there any option to disable HTTPS requests?

cryptommer commented 2 years ago

Do you use Wampp or Xamp Services to run your code?

MojSkin commented 2 years ago

I'm using Laragon, but my server provided by Laravel artisan command

cryptommer commented 2 years ago

there isn't a way to disable https but i will add it soon

MojSkin commented 2 years ago

So what should I do now, I'm using Laragon to run apache and php, but my server is managed by Laravel artisan...

Two of my systems runs well the project, but one of them has problem to connect with sms.ir web service

On Wed, Aug 17, 2022, 23:01 Pouya Biglari @.***> wrote:

there isn't a way to disable https but i will add it soon

— Reply to this email directly, view it on GitHub https://github.com/IPeCompany/SmsPanelV2.Laravel/issues/2#issuecomment-1218359174, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKFXHWPQTPRHUB25VK6SATLVZUVW3ANCNFSM56YZFVBQ . You are receiving this because you modified the open/close state.Message ID: @.***>

alerji commented 1 year ago

i solved this problem in the file \vendor\cryptommer\smsir\src\Classes\Smsir.php change this code public function post(string $path, array $params = []) { $response = $this->client->post($path, ['body' => json_encode($params)]); if ($response->getStatusCode() !== 200) { throw new HttpException(__('smsir.error.'.$response->getStatusCode())); } return json_decode($response->getBody()->getContents(), true, 512); }

to this code public function post(string $path, array $params = []) { $response = $this->client->post($path, ['verify' => false,'body' => json_encode($params)]); if ($response->getStatusCode() !== 200) { throw new HttpException(__('smsir.error.'.$response->getStatusCode())); } return json_decode($response->getBody()->getContents(), true, 512); }

Shjpr9 commented 1 month ago

I fixed the same issue using this. hope it works: https://stackoverflow.com/questions/29822686/curl-error-60-ssl-certificate-unable-to-get-local-issuer-certificate