|
|
|
@ -160,10 +160,10 @@ implementation as well as the software that interacts with message parsing. A
|
|
|
|
|
curious reader might ask "why not just use protobufs"? In response, the
|
|
|
|
|
Lighting developers would respond that we're able to have the best of the
|
|
|
|
|
extensibility of protobufs while also having the benefit of a smaller
|
|
|
|
|
implementation and thus attacks surface in the context of Lightning. As of
|
|
|
|
|
version v3.15.6, the protobuf compiler weighs in at over 656,671 lines of code.
|
|
|
|
|
In comparison lnd's implementation of the TLV message format weighs in at only
|
|
|
|
|
2.3k lines of code (including tests).
|
|
|
|
|
implementation and thus smaller attack. As of version v3.15.6, the protobuf
|
|
|
|
|
compiler weighs in at over 656,671 lines of code. In comparison lnd's
|
|
|
|
|
implementation of the TLV message format weighs in at only 2.3k lines of code
|
|
|
|
|
(including tests).
|
|
|
|
|
|
|
|
|
|
With the necessary background presented, we're now ready to describe the TLV
|
|
|
|
|
format in detail. A TLV message extension is said to be a _stream_ of
|
|
|
|
|