What GZip extra field subfields exist?

Viewed 235

RFC 1952 (GZIP File Format Specification) section 2.3.1.1 reads:

2.3.1.1. Extra field

   If the FLG.FEXTRA bit is set, an "extra field" is present in
   the header, with total length XLEN bytes.  It consists of a
   series of subfields, each of the form:

      +---+---+---+---+==================================+
      |SI1|SI2|  LEN  |... LEN bytes of subfield data ...|
      +---+---+---+---+==================================+

   SI1 and SI2 provide a subfield ID, typically two ASCII letters
   with some mnemonic value.  Jean-Loup Gailly
   <email@hidden> is maintaining a registry of subfield
   IDs; please send him any subfield ID you wish to use.  Subfield
   IDs with SI2 = 0 are reserved for future use.  The following
   IDs are currently defined:

      SI1         SI2         Data
      ----------  ----------  ----
      0x41 ('A')  0x70 ('P')  Apollo file type information

   LEN gives the length of the subfield data, excluding the 4
   initial bytes.

Do any subfield types exist beyond the AP given in the RFC? A web search doesn't find a list; neither is there any mention on GZip's Wikipedia page, the GNU homepage, in the gzip source code, or on Stack Overflow.

2 Answers

As far as I know, there is no such registry being maintained. Jean-loup no longer works on gzip.

Here is one more subfield in use:

The BGZF format (which is gzip-conformant) developed for use in bioinformatics, uses the subfield type "BC", to indicate the size of the current block. This is used to make parallel decompression easy.

From the specification at http://samtools.github.io/hts-specs/SAMv1.pdf :

Each BGZF block contains a standard gzip file header with the following standard-compliant extensions:

  1. The F.EXTRA bit in the header is set to indicate that extra fields are present.
  2. The extra field used by BGZF uses the two subfield ID values 66 and 67 (ASCII ‘BC’).
  3. The length of the BGZF extra field payload (field LEN in the gzip specification) is 2 (two bytes of payload).
  4. The payload of the BGZF extra field is a 16-bit unsigned integer in little endian format. This integer gives the size of the containing BGZF block minus one.
Related