Bundle certificate (fix #36)
This commit is contained in:
parent
ff4fa1eefa
commit
ade8b0e5a6
|
|
@ -107,7 +107,9 @@ class MarketController extends Controller
|
||||||
if (app()->environment('testing') || ! $this->registryCache) {
|
if (app()->environment('testing') || ! $this->registryCache) {
|
||||||
try {
|
try {
|
||||||
$pluginsJson = $this->guzzle->request(
|
$pluginsJson = $this->guzzle->request(
|
||||||
'GET', config('plugins.registry')
|
'GET',
|
||||||
|
config('plugins.registry'),
|
||||||
|
['verify' => resource_path('misc/ca-bundle.crt')],
|
||||||
)->getBody();
|
)->getBody();
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
throw new Exception(trans('admin.plugins.market.connection-error', [
|
throw new Exception(trans('admin.plugins.market.connection-error', [
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,11 @@ class UpdateController extends Controller
|
||||||
$acceptableSpec = 1;
|
$acceptableSpec = 1;
|
||||||
if (! $this->info) {
|
if (! $this->info) {
|
||||||
try {
|
try {
|
||||||
$json = $this->guzzle->request('GET', $this->updateSource)->getBody();
|
$json = $this->guzzle->request(
|
||||||
|
'GET',
|
||||||
|
$this->updateSource,
|
||||||
|
['verify' => resource_path('misc/ca-bundle.crt')],
|
||||||
|
)->getBody();
|
||||||
$info = json_decode($json, true);
|
$info = json_decode($json, true);
|
||||||
if (Arr::get($info, 'spec') == $acceptableSpec) {
|
if (Arr::get($info, 'spec') == $acceptableSpec) {
|
||||||
$this->info = $info;
|
$this->info = $info;
|
||||||
|
|
|
||||||
|
|
@ -23,6 +23,7 @@ class Captcha implements Rule
|
||||||
'secret' => $secretkey,
|
'secret' => $secretkey,
|
||||||
'response' => $value,
|
'response' => $value,
|
||||||
],
|
],
|
||||||
|
'verify' => resource_path('misc/ca-bundle.crt'),
|
||||||
]);
|
]);
|
||||||
if ($response->getStatusCode() == 200) {
|
if ($response->getStatusCode() == 200) {
|
||||||
$body = json_decode((string) $response->getBody());
|
$body = json_decode((string) $response->getBody());
|
||||||
|
|
|
||||||
|
|
@ -29,6 +29,7 @@ class PackageManager
|
||||||
$this->guzzle->request('GET', $url, [
|
$this->guzzle->request('GET', $url, [
|
||||||
'sink' => $path,
|
'sink' => $path,
|
||||||
'progress' => $this->onProgress,
|
'progress' => $this->onProgress,
|
||||||
|
'verify' => resource_path('misc/ca-bundle.crt'),
|
||||||
]);
|
]);
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
throw new Exception(trans('admin.download.errors.download', ['error' => $e->getMessage()]));
|
throw new Exception(trans('admin.download.errors.download', ['error' => $e->getMessage()]));
|
||||||
|
|
|
||||||
3401
resources/misc/ca-bundle.crt
Executable file
3401
resources/misc/ca-bundle.crt
Executable file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user