home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 9 Archive / 09-Archive.zip / unzip531.zip / proginfo / extra.fld < prev    next >
Text File  |  1997-05-31  |  25KB  |  677 lines

  1. The following are the known types of zipfile extra fields as of this
  2. writing.  Extra fields are documented in PKWARE's appnote.txt and are
  3. intended to allow for backward- and forward-compatible extensions to
  4. the zipfile format.  Multiple extra-field types may be chained together,
  5. provided that the total length of all extra-field data is less than 64KB.
  6. (In fact, PKWARE requires that the total length of the entire file header,
  7. including timestamp, file attributes, filename, comment, extra field, etc.,
  8. be no more than 64KB.)
  9.  
  10. Each extra-field type (or subblock) must contain a four-byte header con-
  11. sisting of a two-byte header ID and a two-byte length (little-endian) for
  12. the remaining data in the subblock.  If there are additional subblocks
  13. within the extra field, the header for each one will appear immediately 
  14. following the data for the previous subblock (i.e., with no padding for
  15. alignment).
  16.  
  17. All integer fields in the descriptions below are in little-endian (Intel)
  18. format unless otherwise specified.  Note that "Short" means two bytes and
  19. "Long" means four bytes, regardless of their native sizes.
  20.  
  21. Greg Roelofs, 970531
  22.  
  23.             -------------------------
  24.  
  25. The current list of Header IDs is as follows (0-31 are reserved by PKWARE):
  26.  
  27.       0x0007        AV Info
  28.       0x0009        OS/2 extended attributes
  29.       0x000c        PKWARE VAX/VMS
  30.       0x000d        reserved for Unix
  31.       0x07c8        Info-ZIP Macintosh
  32.       0x2605        ZipIt Macintosh
  33.       0x4341        Acorn/SparkFS (David Pilling)
  34.       0x4453    Windows NT security descriptor (binary ACL)
  35.       0x4704        VM/CMS
  36.       0x470f        MVS
  37.       0x4b46        FWKCS MD5 (third party, see below)
  38.       0x4c41        OS/2 access control list (text ACL)
  39.       0x4d49        Info-ZIP VMS (VAX or Alpha)
  40.       0x5356        AOS/VS (binary ACL)
  41.       0x5455        extended timestamp
  42.       0x5855        Info-ZIP Unix (original; also OS/2, NT, etc.)
  43.       0x6542        BeOS (BeBox, PowerMac, etc.)
  44.       0x756e        ASi Unix
  45.       0x7855        Info-ZIP Unix (new)
  46.       0xfb4a        SMS/QDOS
  47.  
  48. The following are detailed descriptions of the known extra-field block types:
  49.  
  50.      -OS/2 Extended Attributes Extra Field:
  51.       ====================================
  52.  
  53.       The following is the layout of the OS/2 extended attributes "extra"
  54.       block.  (Last Revision 960922)
  55.  
  56.       Note: all fields stored in Intel low-byte/high-byte order.
  57.  
  58.       Local-header version:
  59.  
  60.       Value        Size        Description
  61.       -----        ----        -----------
  62.   (OS/2)  0x0009    Short        tag for this extra block type
  63.       TSize        Short        total data size for this block
  64.       BSize        Long        uncompressed EA data size
  65.       CType        Short        compression type
  66.       EACRC        Long        CRC value for uncompressed EA data
  67.       (var.)    variable    compressed EA data
  68.  
  69.       Central-header version:
  70.  
  71.       Value        Size        Description
  72.       -----        ----        -----------
  73.   (OS/2)  0x0009    Short        tag for this extra block type
  74.       TSize        Short        total data size for this block
  75.       BSize        Long        size of uncompressed local EA data
  76.  
  77.       The value of CType is interpreted according to the "compression
  78.       method" section above; i.e., 0 for stored, 8 for deflated, etc.
  79.  
  80.       The OS/2 extended attribute structure (FEA2LIST) is compressed and
  81.       then stored in its entirety within this structure.  There will only
  82.       ever be one block of data in the variable-length field.
  83.  
  84.  
  85.      -OS/2 Access Control List Extra Field:
  86.       ====================================
  87.  
  88.       The following is the layout of the OS/2 ACL extra block.
  89.       (Last Revision 960922)
  90.  
  91.       Local-header version:
  92.  
  93.       Value        Size        Description
  94.       -----        ----        -----------
  95.   (ACL)   0x4c41    Short        tag for this extra block type
  96.       TSize        Short        total data size for this block
  97.       BSize        Long        uncompressed ACL data size
  98.       CType        Short        compression type
  99.       EACRC        Long        CRC value for uncompressed ACL data
  100.       (var.)    variable    compressed ACL data
  101.  
  102.       Central-header version:
  103.  
  104.       Value        Size        Description
  105.       -----        ----        -----------
  106.   (ACL)   0x4c41    Short        tag for this extra block type
  107.       TSize        Short        total data size for this block
  108.       BSize        Long        size of uncompressed local ACL data
  109.  
  110.       The value of CType is interpreted according to the "compression
  111.       method" section above; i.e., 0 for stored, 8 for deflated, etc.
  112.  
  113.       The uncompressed ACL data consist of a text header of the form
  114.       "ACL1:%hX,%hd\n", where the first field is the OS/2 ACCINFO acc_attr
  115.       member and the second is acc_count, followed by acc_count strings
  116.       of the form "%s,%hx\n", where the first field is acl_ugname (user
  117.       group name) and the second acl_access.  This block type will be
  118.       extended for other operating systems as needed.
  119.  
  120.  
  121.      -Windows NT Security Descriptor Extra Field:
  122.       ==========================================
  123.  
  124.       The following is the layout of the NT Security Descriptor (another
  125.       type of ACL) extra block.  (Last Revision 960922)
  126.  
  127.       Local-header version:
  128.  
  129.       Value        Size        Description
  130.       -----        ----        -----------
  131.   (SD)    0x4453    Short        tag for this extra block type
  132.       TSize        Short        total data size for this block
  133.       BSize        Long        uncompressed SD data size
  134.       Version    Byte        version of uncompressed SD data format
  135.       CType        Short        compression type
  136.       EACRC        Long        CRC value for uncompressed SD data
  137.       (var.)    variable    compressed SD data
  138.  
  139.       Central-header version:
  140.  
  141.       Value        Size        Description
  142.       -----        ----        -----------
  143.   (SD)    0x4453    Short        tag for this extra block type
  144.       TSize        Short        total data size for this block
  145.       BSize        Long        size of uncompressed local SD data
  146.       Version    Byte        version of uncompressed SD data format
  147.  
  148.       The value of CType is interpreted according to the "compression
  149.       method" section above; i.e., 0 for stored, 8 for deflated, etc.
  150.       Version specifies how the compressed data are to be interpreted
  151.       and allows for future expansion of this extra field type.  Currently
  152.       only version 0 is defined.
  153.  
  154.       For version 0, the compressed data are to be interpreted as a single
  155.       valid Windows NT SECURITY_DESCRIPTOR data structure, in self-relative
  156.       format.
  157.  
  158.  
  159.      -PKWARE VAX/VMS Extra Field:
  160.       ==========================
  161.  
  162.       The following is the layout of PKWARE's VAX/VMS attributes "extra"
  163.       block.  (Last Revision 12/17/91)
  164.  
  165.       Note: all fields stored in Intel low-byte/high-byte order.
  166.  
  167.       Value        Size        Description
  168.       -----        ----        -----------
  169.   (VMS)   0x000c        Short           Tag for this "extra" block type
  170.       TSize         Short           Total Data Size for this block
  171.       CRC           Long            32-bit CRC for remainder of the block
  172.       Tag1          Short           VMS attribute tag value #1
  173.       Size1         Short           Size of attribute #1, in bytes
  174.       (var.)        Size1           Attribute #1 data
  175.       .
  176.       .
  177.       .
  178.       TagN          Short           VMS attribute tage value #N
  179.       SizeN         Short           Size of attribute #N, in bytes
  180.       (var.)        SizeN           Attribute #N data
  181.  
  182.       Rules:
  183.  
  184.       1. There will be one or more of attributes present, which will
  185.          each be preceded by the above TagX & SizeX values.  These
  186.          values are identical to the ATR$C_XXXX and ATR$S_XXXX constants
  187.          which are defined in ATR.H under VMS C.  Neither of these values
  188.          will ever be zero.
  189.  
  190.       2. No word alignment or padding is performed.
  191.  
  192.       3. A well-behaved PKZIP/VMS program should never produce more than
  193.          one sub-block with the same TagX value.  Also, there will never
  194.          be more than one "extra" block of type 0x000c in a particular
  195.          directory record.
  196.  
  197.  
  198.      -Info-ZIP VMS Extra Field:
  199.       ========================
  200.  
  201.       The following is the layout of Info-ZIP's VMS attributes extra
  202.       block for VAX or Alpha AXP.  The local-header and central-header
  203.       versions are identical.  (Last Revision 960922)
  204.  
  205.       Value        Size        Description
  206.       -----        ----        -----------
  207.   (VMS2)  0x4d49    Short        tag for this extra block type
  208.       TSize        Short        total data size for this block
  209.       ID        Long        block ID
  210.       Flags        Short        info bytes
  211.       BSize        Short        uncompressed block size
  212.       Reserved    Long        (reserved)
  213.       (var.)    variable    compressed VMS file-attributes block
  214.  
  215.       The block ID is one of the following unterminated strings:
  216.  
  217.         "VFAB"        struct FAB
  218.         "VALL"        struct XABALL
  219.         "VFHC"        struct XABFHC
  220.         "VDAT"        struct XABDAT
  221.         "VRDT"        struct XABRDT
  222.         "VPRO"        struct XABPRO
  223.         "VKEY"        struct XABKEY
  224.         "VMSV"        version (e.g., "V6.1"; truncated at hyphen)
  225.         "VNAM"        reserved
  226.  
  227.       The lower three bits of Flags indicate the compression method.  The
  228.       currently defined methods are:
  229.  
  230.         0    stored (not compressed)
  231.         1    simple "RLE"
  232.         2    deflated
  233.  
  234.       The "RLE" method simply replaces zero-valued bytes with zero-valued
  235.       bits and non-zero-valued bytes with a "1" bit followed by the byte
  236.       value.
  237.  
  238.       The variable-length compressed data contains only the data corre-
  239.       sponding to the indicated structure or string.  Typically multiple
  240.       VMS2 extra fields are present (each with a unique block type).
  241.  
  242.  
  243.      -Info-ZIP Macintosh Extra Field:
  244.       ==============================
  245.  
  246.       The following is the layout of the (old) Info-ZIP resource-fork extra
  247.       block for Macintosh.  The local-header and central-header versions
  248.       are identical.  (Last Revision 960922)
  249.  
  250.       Value        Size        Description
  251.       -----        ----        -----------
  252.   (Mac)   0x07c8    Short        tag for this extra block type
  253.       TSize        Short        total data size for this block
  254.       "JLEE"    beLong        extra-field signature
  255.       FInfo        16 bytes    Macintosh FInfo structure
  256.       CrDat        beLong        HParamBlockRec fileParam.ioFlCrDat
  257.       MdDat        beLong        HParamBlockRec fileParam.ioFlMdDat
  258.       Flags        beLong        info bits
  259.       DirID        beLong        HParamBlockRec fileParam.ioDirID
  260.       VolName    28 bytes    volume name (optional)
  261.  
  262.       All fields but the first two are in native Macintosh format
  263.       (big-endian Motorola order, not little-endian Intel).  The least
  264.       significant bit of Flags is 1 if the file is a data fork, 0 other-
  265.       wise.  In addition, if this extra field is present, the filename
  266.       has an extra 'd' or 'r' appended to indicate data fork or resource
  267.       fork.  The 28-byte VolName field may be omitted.
  268.  
  269.  
  270.      -ZipIt Macintosh Extra Field:
  271.       ===========================
  272.  
  273.       The following is the layout of the ZipIt extra block for Macintosh.
  274.       The local-header and central-header versions are identical.
  275.       (Last Revision 970130)
  276.  
  277.       Value        Size        Description
  278.       -----        ----        -----------
  279.   (Mac2)  0x2605    Short        tag for this extra block type
  280.       TSize        Short        total data size for this block
  281.       "ZPIT"    beLong        extra-field signature
  282.       FnLen        Byte        length of FileName
  283.       FileName    variable    full Macintosh filename
  284.       FileType    beLong        four-byte Mac file type string
  285.       Creator    beLong        four-byte Mac creator string
  286.  
  287.  
  288.      -Acorn SparkFS Extra Field:
  289.       =========================
  290.  
  291.       The following is the layout of David Pilling's SparkFS extra block
  292.       for Acorn RISC OS.  The local-header and central-header versions are
  293.       identical.  (Last Revision 960922)
  294.  
  295.       Value        Size        Description
  296.       -----        ----        -----------
  297.   (Acorn) 0x4341    Short        tag for this extra block type
  298.       TSize        Short        total data size for this block
  299.       "ARC0"    Long        extra-field signature
  300.       LoadAddr    Long        load address or file type
  301.       ExecAddr    Long        exec address
  302.       Attr        Long        file permissions
  303.       Zero        Long        reserved; always zero
  304.  
  305.       The following bits of Attr are associated with the given file
  306.       permissions:
  307.  
  308.         bit 0        user-writable ('W')
  309.         bit 1        user-readable ('R')
  310.         bit 2        reserved
  311.         bit 3        locked ('L')
  312.         bit 4        publicly writable ('w')
  313.         bit 5        publicly readable ('r')
  314.         bit 6        reserved
  315.         bit 7        reserved
  316.  
  317.  
  318.      -VM/CMS Extra Field:
  319.       ==================
  320.  
  321.       The following is the layout of the file-attributes extra block for
  322.       VM/CMS.  The local-header and central-header versions are
  323.       identical.  (Last Revision 960922)
  324.  
  325.       Value        Size        Description
  326.       -----        ----        -----------
  327.  (VM/CMS) 0x4704    Short        tag for this extra block type
  328.       TSize        Short        total data size for this block
  329.       flData    variable    file attributes data
  330.  
  331.       flData is an uncompressed fldata_t struct.
  332.  
  333.  
  334.      -MVS Extra Field:
  335.       ===============
  336.  
  337.       The following is the layout of the file-attributes extra block for
  338.       MVS.  The local-header and central-header versions are identical.
  339.       (Last Revision 960922)
  340.  
  341.       Value        Size        Description
  342.       -----        ----        -----------
  343.   (MVS)   0x470f    Short        tag for this extra block type
  344.       TSize        Short        total data size for this block
  345.       flData    variable    file attributes data
  346.  
  347.       flData is an uncompressed fldata_t struct.
  348.  
  349.  
  350.      -Extended Timestamp Extra Field:
  351.       ==============================
  352.  
  353.       The following is the layout of the extended-timestamp extra block.
  354.       (Last Revision 970118)
  355.  
  356.       Local-header version:
  357.  
  358.       Value        Size        Description
  359.       -----        ----        -----------
  360.   (time)  0x5455    Short        tag for this extra block type
  361.       TSize        Short        total data size for this block
  362.       Flags        Byte        info bits
  363.       (ModTime)    Long        time of last modification (UTC/GMT)
  364.       (AcTime)    Long        time of last access (UTC/GMT)
  365.       (CrTime)    Long        time of original creation (UTC/GMT)
  366.  
  367.       Central-header version:
  368.  
  369.       Value        Size        Description
  370.       -----        ----        -----------
  371.   (time)  0x5455    Short        tag for this extra block type
  372.       TSize        Short        total data size for this block
  373.       Flags        Byte        info bits (refers to local header!)
  374.       (ModTime)    Long        time of last modification (UTC/GMT)
  375.  
  376.       The central-header extra field contains the modification time only,
  377.       or no timestamp at all.  TSize is used to flag its presence or
  378.       absence.  But note:
  379.  
  380.           If "Flags" indicates that Modtime is present in the local header
  381.           field, it MUST be present in the central header field, too!
  382.           This correspondence is required because the modification time
  383.           value may be used to support trans-timezone freshening and
  384.           updating operations with zip archives.
  385.  
  386.       The time values are in standard Unix signed-long format, indicating
  387.       the number of seconds since 1 January 1970 00:00:00.  The times
  388.       are relative to Coordinated Universal Time (UTC), also sometimes
  389.       referred to as Greenwich Mean Time (GMT).  To convert to local time,
  390.       the software must know the local timezone offset from UTC/GMT.
  391.  
  392.       The lower three bits of Flags in both headers indicate which time-
  393.       stamps are present in the LOCAL extra field:
  394.  
  395.         bit 0        if set, modification time is present
  396.         bit 1        if set, access time is present
  397.         bit 2        if set, creation time is present
  398.         bits 3-7    reserved for additional timestamps; not set
  399.  
  400.       Those times that are present will appear in the order indicated, but
  401.       any combination of times may be omitted.  (Creation time may be
  402.       present without access time, for example.)  TSize should equal
  403.       (1 + 4*(number of set bits in Flags)), as the block is currently
  404.       defined.  Other timestamps may be added in the future.
  405.  
  406.  
  407.      -Info-ZIP Unix Extra Field (type 1):
  408.       ==================================
  409.  
  410.       The following is the layout of the old Info-ZIP extra block for
  411.       Unix.  It has been replaced by the extended-timestamp extra block
  412.       (0x5455) and the Unix type 2 extra block (0x7855).
  413.       (Last Revision 970118)
  414.  
  415.       Local-header version:
  416.  
  417.       Value        Size        Description
  418.       -----        ----        -----------
  419.   (Unix1) 0x5855    Short        tag for this extra block type
  420.       TSize        Short        total data size for this block
  421.       ModTime    Long        time of last modification (UTC/GMT)
  422.       AcTime    Long        time of last access (UTC/GMT)
  423.       UID        Short        Unix user ID
  424.       GID        Short        Unix group ID
  425.  
  426.       Central-header version:
  427.  
  428.       Value        Size        Description
  429.       -----        ----        -----------
  430.   (Unix1) 0x5855    Short        tag for this extra block type
  431.       TSize        Short        total data size for this block
  432.       ModTime    Long        time of last modification (GMT/UTC)
  433.       AcTime    Long        time of last access (GMT/UTC)
  434.  
  435.       The file modification and access times are in standard Unix signed-
  436.       long format, indicating the number of seconds since 1 January 1970
  437.       00:00:00.  The times are relative to Coordinated Universal Time
  438.       (UTC), also sometimes referred to as Greenwich Mean Time (GMT).  To
  439.       convert to local time, the software must know the local timezone
  440.       offset from UTC/GMT.  The modification time may be used by non-Unix
  441.       systems to support inter-timezone freshening and updating of zip
  442.       archives.
  443.  
  444.       The local-header extra block may optionally contain UID and GID
  445.       info for the file.  The local-header TSize value is the only
  446.       indication of this.  Note that Unix UIDs and GIDs are usually
  447.       specific to a particular machine, and they generally require root
  448.       access to restore.
  449.  
  450.       This extra field type is obsolete, but it has been in use since
  451.       mid-1994.  Therefore future archiving software should continue to
  452.       support it.  Some guidelines:
  453.  
  454.           An archive member should either contain the old "Unix1"
  455.           extra field block or the new extra field types "time" and/or
  456.           "Unix2".
  457.  
  458.           If both the old "Unix1" block type and one or both of the new
  459.           block types "time" and "Unix2" are found, the "Unix1" block
  460.           should be considered invalid and ignored.
  461.  
  462.           Unarchiving software should recognize both old and new extra
  463.           field block types, but the info from new types overrides the
  464.           old "Unix1" field.
  465.  
  466.           Archiving software should recognize "Unix1" extra fields for
  467.           timestamp comparison but never create it for updated, freshened
  468.           or new archive members.  When copying existing members to a new
  469.           archive, any "Unix1" extra field blocks should be converted to
  470.           the new "time" and/or "Unix2" types.
  471.  
  472.  
  473.      -Info-ZIP Unix Extra Field (type 2):
  474.       ==================================
  475.  
  476.       The following is the layout of the new Info-ZIP extra block for
  477.       Unix.  (Last Revision 960922)
  478.  
  479.       Local-header version:
  480.  
  481.       Value        Size        Description
  482.       -----        ----        -----------
  483.   (Unix2) 0x7855    Short        tag for this extra block type
  484.       TSize        Short        total data size for this block
  485.       UID        Short        Unix user ID
  486.       GID        Short        Unix group ID
  487.  
  488.       Central-header version:
  489.  
  490.       Value        Size        Description
  491.       -----        ----        -----------
  492.   (Unix2) 0x7855    Short        tag for this extra block type
  493.       TSize        Short        total data size for this block
  494.  
  495.       The data size of the central-header version is zero; it is used
  496.       solely as a flag that UID/GID info is present in the local-header
  497.       extra field.  If additional fields are ever added to the local
  498.       version, the central version may be extended to indicate this.
  499.  
  500.       Note that Unix UIDs and GIDs are usually specific to a particular
  501.       machine, and they generally require root access to restore.
  502.  
  503.  
  504.      -ASi Unix Extra Field:
  505.       ====================
  506.  
  507.       The following is the layout of the ASi extra block for Unix.  The
  508.       local-header and central-header versions are identical.
  509.       (Last Revision 960916)
  510.  
  511.       Value        Size        Description
  512.       -----        ----        -----------
  513.   (Unix3) 0x756e    Short        tag for this extra block type
  514.       TSize        Short        total data size for this block
  515.       CRC        Long        CRC-32 of the remaining data
  516.       Mode        Short        file permissions
  517.       SizDev    Long        symlink'd size OR major/minor dev num
  518.       UID        Short        user ID
  519.       GID        Short        group ID
  520.       (var.)    variable    symbolic link filename
  521.  
  522.       Mode is the standard Unix st_mode field from struct stat, containing
  523.       user/group/other permissions, setuid/setgid and symlink info, etc.
  524.  
  525.       If Mode indicates that this file is a symbolic link, SizDev is the
  526.       size of the file to which the link points.  Otherwise, if the file
  527.       is a device, SizDev contains the standard Unix st_rdev field from
  528.       struct stat (includes the major and minor numbers of the device).
  529.       SizDev is undefined in other cases.
  530.  
  531.       If Mode indicates that the file is a symbolic link, the final field
  532.       will be the name of the file to which the link points.  The file-
  533.       name length can be inferred from TSize.
  534.  
  535.       [Note that TSize may incorrectly refer to the data size not counting
  536.        the CRC; i.e., it may be four bytes too small.]
  537.  
  538.  
  539.      -BeOS Extra Field:
  540.       ================
  541.  
  542.       The following is the layout of the file-attributes extra block for
  543.       BeOS.  (Last Revision 970531)
  544.  
  545.       Local-header version:
  546.  
  547.       Value        Size        Description
  548.       -----        ----        -----------
  549.   (BeOS)  0x6542    Short        tag for this extra block type
  550.       TSize        Short        total data size for this block
  551.       BSize        Long        uncompressed file attribute data size
  552.       Flags        Byte        info bits
  553.       (CType)    Short        compression type
  554.       (CRC)        Long        CRC value for uncompressed file attribs
  555.       Attribs    variable    file attribute data
  556.  
  557.       Central-header version:
  558.  
  559.       Value        Size        Description
  560.       -----        ----        -----------
  561.   (BeOS)  0x6542    Short        tag for this extra block type
  562.       TSize        Short        total data size for this block
  563.       BSize        Long        size of uncompressed local EF block data
  564.       Flags        Byte        info bits
  565.  
  566.       The least significant bit of Flags in both headers indicates whether
  567.       the LOCAL extra field is uncompressed (and therefore whether CType
  568.       and CRC are omitted):
  569.  
  570.         bit 0        if set, Attribs is uncompressed (no CType, CRC)
  571.         bits 1-7    reserved; if set, assume error or unknown data
  572.  
  573.       Currently the only supported compression types are deflated (type 8)
  574.       and stored (type 0); the latter is not used by Info-ZIP's Zip but is
  575.       supported by UnZip.
  576.  
  577.       Attribs is a BeOS-specific block of data in big-endian format with
  578.       the following structure (if compressed, uncompress it first):
  579.  
  580.           Value    Size        Description
  581.           -----    ----        -----------
  582.           Name    variable    attribute name (null-terminated string)
  583.           Type    Long        attribute type (32-bit unsigned integer)
  584.           Size    Long Long    data size for this sub-block (64 bits)
  585.           Data    variable    attribute data
  586.  
  587.       The attribute structure is repeated for every attribute.  The Data
  588.       field may contain anything--text, flags, bitmaps, etc.
  589.  
  590.  
  591.      -SMS/QDOS Extra Field:
  592.       ====================
  593.  
  594.       The following is the layout of the file-attributes extra block for
  595.       SMS/QDOS.  The local-header and central-header versions are identical.
  596.       (Last Revision 960929)
  597.  
  598.       Value        Size        Description
  599.       -----        ----        -----------
  600.   (QDOS)  0xfb4a    Short        tag for this extra block type
  601.       TSize        Short        total data size for this block
  602.       LongID    Long        extra-field signature
  603.       (ExtraID)    Long        additional signature/flag bytes
  604.       QDirect    64 bytes    qdirect structure
  605.  
  606.       LongID may be "QZHD" or "QDOS".  In the latter case, ExtraID will
  607.       be present.  Its first three bytes are "02\0"; the last byte is
  608.       currently undefined.
  609.  
  610.       QDirect contains the file's uncompressed directory info (qdirect
  611.       struct).  Its elements are in native (big-endian) format:
  612.  
  613.       d_length    beLong        file length
  614.       d_access    byte        file access type
  615.       d_type    byte        file type
  616.       d_datalen    beLong        data length
  617.       d_reserved    beLong        unused
  618.       d_szname    beShort        size of filename
  619.       d_name    36 bytes    filename
  620.       d_update    beLong        time of last update
  621.       d_refdate    beLong        file version number
  622.       d_backup    beLong        time of last backup (archive date)
  623.  
  624.  
  625.      -AOS/VS Extra Field:
  626.       ==================
  627.  
  628.       The following is the layout of the extra block for Data General
  629.       AOS/VS.  The local-header and central-header versions are identical.
  630.       (Last Revision 961125)
  631.  
  632.       Value        Size        Description
  633.       -----        ----        -----------
  634.   (AOSVS) 0x5356    Short        tag for this extra block type
  635.       TSize        Short        total data size for this block
  636.       "FCI\0"    Long        extra-field signature
  637.       Version    Byte        version of AOS/VS extra block (10 = 1.0)
  638.       Fstat        variable    fstat packet
  639.       AclBuf    variable    raw ACL data ($MXACL bytes)
  640.  
  641.       Fstat contains the file's uncompressed fstat packet, which is one of
  642.       the following:
  643.  
  644.         normal fstat packet        (P_FSTAT struct)
  645.         DIR/CPD fstat packet        (P_FSTAT_DIR struct)
  646.         unit (device) fstat packet    (P_FSTAT_UNIT struct)
  647.         IPC file fstat packet        (P_FSTAT_IPC struct)
  648.  
  649.       AclBuf contains the raw ACL data; its length is $MXACL.
  650.  
  651.  
  652.          -FWKCS MD5 Extra Field:
  653.           =====================
  654.  
  655.       The following is the layout of the optional extra block used by the
  656.       FWKCS utility.  There is no local-header version; the following
  657.       applies only to the central header.  (Last Revision 961207)
  658.  
  659.       Central-header version:
  660.  
  661.       Value        Size        Description
  662.       -----        ----        -----------
  663.   (MD5)   0x4b46    Short        tag for this extra block type
  664.       TSize        Short        total data size for this block (19)
  665.       "MD5"        3 bytes        extra-field signature
  666.       MD5hash    16 bytes    128-bit MD5 hash of uncompressed data
  667.  
  668.       The MD5 hash in this extra block is used to automatically identify
  669.       files independent of their filenames; it is an an enhanced contents-
  670.       signature.  Adding or removing this block should preserve the PKWARE
  671.       AV (Authenticity Verification) signature.
  672.  
  673.       ``The MD5 algorithm is being placed in the public domain for review
  674.       and possible adoption as a standard.'' (Ron Rivest, MIT Laboratory
  675.       for Computer Science and RSA Data Security, Inc., April 1992, RFC
  676.       1321, 11.76-77).  FWKCS is a trademark of Frederick W. Kantor.
  677.