[noise] New draft: "noh2" branch

Trevor Perrin trevp at trevp.net
Thu Aug 27 23:35:35 PDT 2015


On Thu, Aug 27, 2015 at 10:22 AM, Tiffany Bennett <tiffany at stormbit.net> wrote:
> I am against
> out-of-band connection termination, if that makes it clearer.
[...]



Thought about this more:

Interactive protocols often have "in-band" signaling of termination.
So having this in the crypto layer is arguably unnecessary and
confusing.

I think file formats rely on EOF for termination more often.   So if
Noise is used to encrypt single files, some sort of length field or
terminator will need to be added, and arguably having this in the
Noise API is safer.

This is a hard layering question.  But I removed the terminator byte
from "noh2" branch, for now:

https://github.com/trevp/noise/blob/noh2/noise.md

Reasons:

 * The application layer is in the best position to know what sort of
termination it needs (length field, terminator byte, other).

 * Providing an API for this in the crypto layer doesn't guarantee the
application will use it correctly, so we're dependent on the
application in any case, we might as well let the application handle
the whole thing.

 * We've punted padding and handshake extensions to the application
layer, so this feels consistent.

 * This remains a close call, but I'd rather err on the side of simplicity.


Trevor


More information about the Noise mailing list