Skip to content

Commit

Permalink
Suppress warnings in remote class if system CA is outside of open_bas…
Browse files Browse the repository at this point in the history
…edir
  • Loading branch information
bastianallgeier committed Mar 1, 2024
1 parent 5b46304 commit e981493
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Http/Remote.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,9 @@ public function __construct(string $url, array $options = [])
// use the system CA store by default if
// one has been configured in php.ini
$cainfo = ini_get('curl.cainfo');
if (empty($cainfo) === false && is_file($cainfo) === true) {

// Suppress warnings e.g. if system CA is outside of open_basedir (See: issue #6236)
if (empty($cainfo) === false && @is_file($cainfo) === true) {
$defaults['ca'] = self::CA_SYSTEM;
}

Expand Down

0 comments on commit e981493

Please sign in to comment.