'file' Command Giving False Positives
Dan Nelson
dnelson at allantgroup.com
Fri Jul 2 14:52:44 UTC 2010
In the last episode (Jul 02), Tim Daneliuk said:
> I have a data file with the content:
>
> LZasdadqjwjqwjqwjeqwe
>
> 'file' (incorrectly) reports this as an MS-DOS executable.
I dunno; if I create a file "a.exe" on my XP system with those contents, I
can run it from a cmd prompt, and it doesn't print any errors, so
technically it is an MS-DOS executable :)
> Does anyone happen to know the proper changes to 'magic' that would
> fix this?
Easiest fix would be to remove line 377 from
/usr/src/contrib/file/Magdir/msdos and rebuild & reinstall
/usr/src/lib/libmagic/ .
--
Dan Nelson
dnelson at allantgroup.com
More information about the freebsd-questions
mailing list