In Curl driver headers aren't returned, example:
$ch = curl_init('file:///c:/foo/bar/baz.txt');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HEADER, true);
curl_setopt($ch, CURLOPT_NOBODY, true);
$headers = curl_exec($ch);
curl_close($ch);
var_dump($headers);
In PHP 7.2 (and olders) returns:
string(88) "Content-Length: 57
Accept-ranges: bytes
Last-Modified: Sun, 29 Dec 2019 05:31:32 GMT
"
In PHP 7.3 and PHP 7.4 returns empty string: