Disable SSL checks on API calls

This commit is contained in:
tomyvi 2022-04-07 10:34:07 +02:00 committed by GitHub
parent 758c174141
commit c5817c9b2e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -191,7 +191,13 @@ class ItemController extends Controller
'icon' => $path,
]);
} elseif (strpos($request->input('icon'), 'http') === 0) {
$contents = file_get_contents($request->input('icon'));
$options=array(
"ssl"=>array(
"verify_peer"=>false,
"verify_peer_name"=>false,
),
);
$contents = file_get_contents($request->input('icon'), false, stream_context_create($options));
if ($application) {
$icon = $application->icon;