Text-based IPC for Userspace Implementations
Jason A. Donenfeld
Jason at zx2c4.com
Wed May 17 20:10:57 CEST 2017
On Wed, May 17, 2017 at 8:07 PM, Toke Høiland-Jørgensen <toke at toke.dk> wrote:
> My point was not so much "just use JSON". My point was "you are
> disguising something that requires stateful parsing as a simple
> key/value scheme, which is bound to lead to bugs eventually". I.e. if
> someone were to write a parser that would (e.g.) just grep for a public
> key, they'd end up with ambiguous results at best.
If your random 256-bit public key is accidentally the prefix or suffix
of something else somewhere else, you have a problem with your RNG.
Anyway, JSON is not regular, though it is context-free, which I think
is your argument. If I had to choose between the two, I'd easily
choose something that's regular to parse, since it can be implemented
in a bug free fashion trivially anywhere.
More information about the WireGuard
mailing list