php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #78701 exif_read_data: corrupt EXIF header: maximum directory nesting level reached
Submitted: 2019-10-20 14:43 UTC Modified: 2019-10-23 20:36 UTC
Votes:2
Avg. Score:4.5 ± 0.5
Reproduced:2 of 2 (100.0%)
Same Version:2 (100.0%)
Same OS:1 (50.0%)
From: gino0631 at centaurus dot cloud Assigned:
Status: Open Package: EXIF related
PHP Version: 7.3.11 OS: CentOS
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2019-10-20 14:43 UTC] gino0631 at centaurus dot cloud
Description:
------------
exif_read_data with the following image:
https://maps.gisforthought.com/Photos/12_Adventure_Duck.jpg

produces:
"exif_read_data(12_Adventure_Duck.jpg): corrupt EXIF header: maximum directory nesting level reached

This looks similar to:
https://bugs.php.net/bug.php?id=75424

but opening a new issue as requested in the comment by @requinix.



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2019-10-20 14:50 UTC] girgias@php.net
Related To: Bug #75424
 [2019-10-20 15:36 UTC] cmb@php.net
With PHP 7.3 (current HEAD) on Windows I get:

PHP Warning:  exif_read_data(78701.php): File not supported in %s on line %d
 [2019-10-20 22:12 UTC] gino0631 at centaurus dot cloud
wget https://maps.gisforthought.com/Photos/12_Adventure_Duck.jpg
echo '<?php $exif = exif_read_data("12_Adventure_Duck.jpg");' > test.php

/opt/remi/php71/root/bin/php --version
PHP 7.1.32 (cli) (built: Aug 28 2019 12:57:54) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2018 Zend Technologies

/opt/remi/php71/root/bin/php test.php
# No error

/opt/remi/php72/root/bin/php --version
PHP 7.2.23 (cli) (built: Sep 25 2019 07:56:34) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies

/opt/remi/php72/root/bin/php test.php
PHP Warning:  exif_read_data(12_Adventure_Duck.jpg): corrupt EXIF header: maximum directory nesting level reached in /tmp/test.php on line 1

/opt/remi/php73/root/bin/php --version
PHP 7.3.10 (cli) (built: Sep 24 2019 09:20:18) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.10, Copyright (c) 1998-2018 Zend Technologies
    with Zend OPcache v7.3.10, Copyright (c) 1999-2018, by Zend Technologies

/opt/remi/php73/root/bin/php test.php
PHP Warning:  exif_read_data(12_Adventure_Duck.jpg): corrupt EXIF header: maximum directory nesting level reached in /tmp/test.php on line 1
 [2019-10-23 20:36 UTC] gino0631 at centaurus dot cloud
-PHP Version: 7.3.10 +PHP Version: 7.3.11
 [2019-10-23 20:36 UTC] gino0631 at centaurus dot cloud
With PHP 7.2.24 and 7.3.11, the results are the same.
 
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Thu Nov 14 21:01:41 2019 UTC