collect user data in buffer; /* assemble packet: */ packet.pvno := protocol version; /* 5 */ packet.msg-type := message type; /* KRB_SAFE */ body.user-data := buffer; /* DATA */ if (using timestamp) then get system_time; body.timestamp, body.usec := system_time; endif if (using sequence numbers) then body.seq-number := sequence number; endif body.s-address := sender host addresses; if (only one recipient) then body.r-address := recipient host address; endif checksum.cksumtype := checksum type; compute checksum over body; checksum.checksum := checksum value; /* checksum.checksum */ packet.cksum := checksum; packet.safe-body := body;