[NUT-devel] r20838 - trunk/DOCS/tech/nut.txt

Rich Felker dalias at aerifal.cx
Sun Nov 12 04:34:06 CET 2006


On Sat, Nov 11, 2006 at 11:29:01PM +0100, Michael Niedermayer wrote:
> Hi
> 
> On Fri, Nov 10, 2006 at 09:50:50PM +0100, Luca Barbato wrote:
> > michael wrote:
> > >  
> > >  file_id_string
> > >      "nut/multimedia container\0"
> > > +    the very first thing in every nut file, usefull for identifying nut
> > > +    files
> > 
> > I guess that it could be pointed as the magic string for file (btw I
> > could add a IANA formal request if you thing it's time)
> 
> please elaborate
> you mean some sort of official "files starting with 
> "nut/multimedia container\0"
> are nut files as defined by nut.txt from IANA?
> 
> if so iam in favor of that unless rich or oded or anyone else
> has any objections or suggestions to change the string?

the only suggestion i would make is to mandate that the main header
startcode come immediately following the null byte. this is required
anyway for a valid nut file so anything doing filetype detection via
magic numbers should require it as well.. and it might prevent false
positives in some weird borderline cases (e.g. a text file beginning
with "nut/multimedia container" where subsequent data is missing and
replaced by null bytes).

rich





More information about the NUT-devel mailing list