Inscriptions are stored in witness (not op_return)? Does knots apply the 83 byte limit to witness too?
Login to reply
Replies (4)
It applies it to inscription envelopes specifically, by testing for the existence of the bytes for "OP_FALSE OP_IF" in the witness
And the limit is the same 83B?
I think so. Here is the relevant code snippet: https://github.com/bitcoinknots/bitcoin/blob/eeb9cc1120661d0e9fd28ddb6fef2c04992a4666/src/script/script.cpp#L329
It is a function called DatacarrierBytes and I don't know c++ all that well but it appears to match transactions containing OP_FALSE OP_IF or OP_RETURN, and counts the number of bytes they carry as a payload. I assume this function gets called wherever the data arrives filter is applied, which I suppose is probably in policy.cpp -- though I haven't checked
I don't know enough either, but I wonder if the is used also on inputs, or just outputs.