Re: comments on WOFF File Format 1.0, W3C Working Draft 27 July 2010

Bob Hallissy <[email protected]>
Newsgroups gmane.comp.web.fonts
Message-ID <[email protected]>
On 2010-08-04  at 1:44  John Daggett wrote:
> 2. Overall File Structure
>> >  Except for padding with a maximum of three null bytes in places
>> >  where 4-byte alignment of a table length or data block is specified,
>> >  there MUST NOT be any extraneous data outside the font tables and
>> >  data blocks as pointed to by the header and table directory entries.
>>      
> Change [outside the font tables and data blocks] to [between font
> tables or other data blocks].
>    

Such a change would permit extraneous data after the last valid table or 
block, and I think that should be prohibited (for security reasons).

If the word "outside" is your concern, perhaps replace that word with 
"other than"?

> Append at the end of the section:
>
> All sizes described in this document are assumed to be in bytes unless
> otherwise noted.
>    

Thanks for this suggestion. I recommend including offsets in this, i.e:

All sizes and offsets described in this document are assumed to be in bytes unless
otherwise noted.


Which brings up a question: Is "size" different from "length" and, if 
not, could the spec be consistent? For example, I see in the WOFF header 
these items:

> UInt32    totalSfntSize    Total size needed for the uncompressed font 
> data, including the sfnt header, directory, and tables.
> UInt32    metaLength    Length of compressed metadata block.
> UInt32    metaOrigLength    Uncompressed size of metadata block.
> UInt32    privLength    Length of private data block.

If these two terms are distinct, then perhaps the spec should say:

All sizes, lengths and offsets described in this document are assumed to be in bytes unless otherwise noted.


Bob
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.