[File] [PATCH] of Magdir/database for DMI Management Information Format *.mif

Christos Zoulas christos at zoulas.com
Sat Jan 4 19:38:26 UTC 2020


Committed, thanks!

christos

> On Jan 4, 2020, at 1:24 PM, Jörg Jenderek <joerg.jen.der.ek at gmx.net> wrote:
> 
> Hello,
> 
> some weeks ago i had to handle some ImageMagick bitmaps which have
> sometimes filename extension mif. When searching on my systems for
> such files and similar test files i found a few samples of another
> file type using that file name extension. When running file command
> version 5.38 such examples are described as text with mime type
> text/plain.
> 
> For comparison reason i run other utilities.
> The file identifier tool TrID  (see
> http://mark0.net/soft-trid-e.html) describes such MIF examples
> correctly as "Management Information Format" by definition
> mif-dmi-u.trid.xml.
> 
> Such MIF files describes in a standardized way as text fragments
> components like PC. It is mainly used on Windows system. So magic
> lines could be added to Magdir/windows or Magdir/wordprocessors.
> But best suited in my opinion seems to be Magdir/database.
> 
> First i add to Magdir/database a comment with URL on Wikipedia about
> Management Information Format (MIF) by line:
> # URL: https://en.wikipedia.org/wiki/Management_Information_Format
> 
> On Distributed Management Task Force web site the Desktop Management
> Interface Specification (DMI) can be found as PDF document. For that
> fact i add a comment line like:
> # Ref.: dmtf.org/sites/default/files/standards/documents/DSP0005.pdf
> 
> According to grammar typical at the beginning is a phrase like "Start
> Component" for Component Definition. In most cases this phrase is
> capitalized but i also found low cased variant like in example2.mif.
> According to reference before that phrase a language line should
> appear like:
> Language=fr|CA|iso8859-1
> In my real found examples like mam_21112019.mif generated by Dell
> Display Manager for my monitor this part is missing. So i generate a
> test example like example-language.mif with such a line.
> So magic line to catch all variants now looks like
> 0 search/27/C Start\040Component DMI Management Information Format
> 
> Afterwards file name extension is shown by line
> !:ext	mif
> Instead of generic mime type for text files i display a used defined
> type by line
> !:mime	text/x-dmtf-mif
> 
> After applying the above mentioned modifications by patch
> file-5.38-database-mif.diff then i get an output like
> 
> example-language.mif: DMI Management Information Format,
> 		      ASCII text, with CRLF line terminators
> example.mif:          DMI Management Information Format,
> 		      ASCII text, with CRLF line terminators
> example2.mif:         DMI Management Information Format,
> 		      ASCII text, with CRLF line terminators
> mam_03112018.mif:     DMI Management Information Format,
> 		      ASCII text, with CRLF line terminators
> mam_04112018.mif:     DMI Management Information Format,
> 		      ASCII text, with CRLF line terminators
> mam_21112019.mif:     DMI Management Information Format,
> 		      ASCII text, with CRLF line terminators
> 
> I hope my diff file can be applied in future version of
> file utility.
> 
> With best wishes
> Jörg Jenderek
> --
> Jörg Jenderek
> 
> 
> 
> <file-5_38-database-mif_diff.DEFANGED-4149>--
> File mailing list
> File at astron.com
> https://mailman.astron.com/mailman/listinfo/file
> <sanitizer.log>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 235 bytes
Desc: Message signed with OpenPGP
URL: <https://mailman.astron.com/pipermail/file/attachments/20200104/0d633c04/attachment.asc>


More information about the File mailing list