RE:are offsets enough? --was: (dictionary or not) Re: [dtn-security] 00 version of the Bundle Security Protocol Spec.

"Susan F. Symington" <susan@mitre.org> Wed, 25 May 2005 18:31 UTC

Received: from smtp-bedford.mitre.org (smtp-bedford-x.mitre.org [192.160.51.76]) by webbie.berkeley.intel-research.net (8.11.6/8.11.6) with ESMTP id j4PIVkV31977 for <dtn-security@mailman.dtnrg.org>; Wed, 25 May 2005 11:31:46 -0700
Received: from smtp-bedford.mitre.org (localhost.localdomain [127.0.0.1]) by smtp-bedford.mitre.org (8.11.6/8.11.6) with SMTP id j4PIVj328531 for <dtn-security@mailman.dtnrg.org>; Wed, 25 May 2005 14:31:45 -0400
Received: from smtp-bedford.mitre.org (localhost.localdomain [127.0.0.1]) by smtp-bedford.mitre.org (Postfix) with ESMTP id 9AA79BF7E for <dtn-security@mailman.dtnrg.org>; Wed, 25 May 2005 14:31:45 -0400 (EDT)
Received: from MAILHUB1 (mailhub1.mitre.org [129.83.20.31]) by smtp-bedford.mitre.org (8.11.6/8.11.6) with ESMTP id j4PIVRX27084; Wed, 25 May 2005 14:31:27 -0400
Message-Id: <200505251831.j4PIVRX27084@smtp-bedford.mitre.org>
Received: from mm122433-pc.mitre.org (128.29.14.10) by mailhub1.mitre.org with SMTP id 17561840; Wed, 25 May 2005 14:31:24 -0400
From: "Susan F. Symington" <susan@mitre.org>
To: "'Michael Demmer'" <demmer@cs.berkeley.edu>, <dtn-security@mailman.dtnrg.org>
Cc: "'Stephen Farrell'" <stephen.farrell@cs.tcd.ie>
Subject: RE:are offsets enough? --was: (dictionary or not) Re: [dtn-security] 00 version of the Bundle Security Protocol Spec.
Date: Wed, 25 May 2005 14:31:19 -0400
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
X-Mailer: Microsoft Office Outlook, Build 11.0.6353
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
Thread-index: AcVhSFwPgi7ZXVzSSgCXWnXhj4NhHQADlFIw
In-reply-to: <20050525163945.GC14911@pisco.cs.berkeley.edu>
Sender: dtn-security-admin@mailman.dtnrg.org
Errors-To: dtn-security-admin@mailman.dtnrg.org
X-BeenThere: dtn-security@mailman.dtnrg.org
X-Mailman-Version: 2.0.13
Precedence: bulk
Reply-To: dtn-security@mailman.dtnrg.org
List-Unsubscribe: <http://mailman.dtnrg.org/mailman/listinfo/dtn-security>, <mailto:dtn-security-request@mailman.dtnrg.org?subject=unsubscribe>
List-Id: DTN Security Discussion <dtn-security.mailman.dtnrg.org>
List-Post: <mailto:dtn-security@mailman.dtnrg.org>
List-Help: <mailto:dtn-security-request@mailman.dtnrg.org?subject=help>
List-Subscribe: <http://mailman.dtnrg.org/mailman/listinfo/dtn-security>, <mailto:dtn-security-request@mailman.dtnrg.org?subject=subscribe>
List-Archive: <http://mailman.dtnrg.org/pipermail/dtn-security/>

> Personally, I think I'd rather that dictionary entries contain
> a length field (whatever encoding) since I've found lists of
> null-terminated strings are a great source for implementation
> errors.

Mike: Yeah -- I just feel like it's not worth the bytes. My other thought is
that we can infer the string lengths based on the various offsets
scattered throughout the bundle, in other words, if all the offsets
(i.e. src, dest, custodian, etc) were sorted, we could then infer the
various lengths based on the differences. But this is probably harder
to read (though more efficient) than just scanning for the null.

Susan: It occurs to me that when a bundle is fragmented, we won't always be
able to infer the various dictionary string lengths based on the various
offsets scattered through the bundle, because not all headers (and therefore
not all offsets) are guaranteed to be in every fragment.  The CH and PSH are
two examples of headers that may contain an offset but that most likely will
not be in every fragment. In the new FLAGS field we defined last week, one
bit is for indicating whether the header must be duplicated on all fragments
or just the first.  So, it seems like the PSH and CH may not be the only
examples. 

So, if terminating the strings with nulls is not sufficient, then it seems
we need something like a length field to go along with the offset.

-susan