Bug #67516 [Com]: wrong mimetypes with finfo_file(filename, FILEINFO_MIME_TYPE)

From: Date: Sun, 25 Jan 2015 08:52:26 +0000
Subject: Bug #67516 [Com]: wrong mimetypes with finfo_file(filename, FILEINFO_MIME_TYPE)
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-190207@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=67516&edit=1

 ID:                 67516
 Comment by:         spam2 at rhsoft dot net
 Reported by:        spam2 at rhsoft dot net
 Summary:            wrong mimetypes with finfo_file(filename,
                     FILEINFO_MIME_TYPE)
 Status:             No Feedback
 Type:               Bug
 Package:            Scripting Engine problem
 Operating System:   Linux
 PHP Version:        5.5.13
 Block user comment: N
 Private report:     N

 New Comment:

no feedback was provided?

i said "sadly i don't see here any option to attach the image" in the original report
and a *really* interested developer would have offered to send the file per mail to him - what
feedback do you expect on a bugtracker from the early 1990's with no capabilities?


Previous Comments:
------------------------------------------------------------------------
[2015-01-25 04:22:21] php-bugs at lists dot php dot net

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.

------------------------------------------------------------------------
[2015-01-11 17:40:36] ab@php.net

Usage of external libmagic isn't possible for various reasons, the patched version is tightly
integrated with PHP. 

@spam2, @fayez, which file/PHP versions was used?

@spam2, please post the image you've an issue with to http://picpaste.com/ . You could probably check with bug #68731
whether it's reproducible for you.

Thanks.

------------------------------------------------------------------------
[2014-07-04 13:56:32] spam2 at rhsoft dot net

i know by myself that it works for most files, but this bugtracker lacks capability to attach the
affected file, 

anyways, if php would use systems file-utilities/libraries the behavior of PHP and other
applications would be indetical and it would not need to carry some MB of redundant data

------------------------------------------------------------------------
[2014-07-04 13:53:03] fayez at bem981 dot cu dot cc

i tried this example with gif image size:8.2m
and i get this result:
/usr/bin/file -b --mime-type
image/gif

finfo_file(filename, FILEINFO_MIME_TYPE)
image/gif
it's work

------------------------------------------------------------------------
[2014-06-29 14:57:44] spam2 at rhsoft dot net

what i completly don't understand is why PHP obviously brings it's on mime-magic and
static implementation instead just use the operating systems file-libs

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=67516


--
Edit this bug report at https://bugs.php.net/bug.php?id=67516&edit=1


Thread (30 messages)

« previous php.bugs (#190207) next »