Project: Webinterface II - Fidonet Packet Structure: *.PKT

AMBROSIA60-Portal  Webinterface II Project


Document: FTS-0001
Version:  016
Date:     30-Sep-95


                     A Basic FidoNet(r) Technical Standard
|                                Revision 16
                      Formerly known as FSC001,  FSC-0001
|                      Randy Bush, Pacific Systems Group
|                             September 30, 1995


 C. Presentation Layer : the User from the System's View

   1. Presentation Layer Data Definition : the Packed Message

      To  conserve space and eliminate fields which would be meaningless  if
      sent  (e.g. timesRead), messages are packed for transmission.  As this
      is  a data structure which is actually transferred, its definition  is
      critical  to FidoNet.  A packed  message has a number of fixed  length
      fields followed by four null terminated strings.

      While  most of the string fields in a stored message are fixed length,
      to  conserve space strings are variable length when in a packet.   All
      variable  length strings are all Null terminated, including especially
      the message text.


                                Packed Message

       Offset
      dec hex
              .-----------------------------------------------.
        0   0 |    0     |     2      |    0      |    0      |
              +-----------------------+-----------------------+
        2   2 | origNode (low order)  | origNode (high order) |
              +-----------------------+-----------------------+
        4   4 | destNode (low order)  | destNode (high order) |
              +-----------------------+-----------------------+
        6   6 | origNet (low order)   | origNet (high order)  |
              +-----------------------+-----------------------+
        8   8 | destNet (low order)   | destNet (high order)  |
              +-----------------------+-----------------------+
       10   A | Attribute (low order) | Attribute (high order)|
              +-----------------------+-----------------------+
       12   C |   cost (low order)    |   cost (high order)   |
              +-----------------------+-----------------------+
       14   E |                                               |
              ~                    DateTime                   ~
              |                    20 bytes                   |
              +-----------------------+-----------------------+
       34  22 |                  toUserName                   |
              ~                  max 36 bytes                 ~
              |                null terminated                |
              +-----------------------+-----------------------+
              |                 fromUserName                  |
              ~                  max 36 bytes                 ~
              |                null terminated                |
              +-----------------------+-----------------------+
              |                    subject                    |
              ~                  max 72 bytes                 ~
              |                null terminated                |
              +-----------------------+-----------------------+
              |                      text                     |
              ~                    unbounded                  ~
              |                 null terminated               |
              `-----------------------------------------------'

      Due  to routing, the origin and  destination net and node of a  packet
      are  often quite different from  those of the messages within it,  nor
      need  the origin and destination nets and nodes of the messages within
      a packet be homogenous.

      PakdMessage  = 02H 00H           (* message type, old type-1 obsolete *)
                     origNode          (* of message *)
                     destNode          (* of message *)
                     origNet           (* of message *)
                     destNet           (* of message *)
                     AttributeWord
                     cost              (* in lowest unit of originator's
                                          currency *)
                     DateTime          (* message body was last edited *)
                     toUserName{36}    (* Null terminated *)
                     fromUserName{36}  (* Null terminated *)
                     subject{72}       (* Null terminated *)
                     text{unbounded}   (* Null terminated *)


© 2003-2024 by Ulrich Schroeter   02293