Oleg Andreev [ARCHIVE] on Nostr: 📅 Original date posted:2015-11-06 📝 Original message:> One and zero should be ...
📅 Original date posted:2015-11-06
📝 Original message:> One and zero should be defined as arrays of length one. Otherwise, it is still possible to mutate the transaction by changing the length of the array.
>
> They should also be minimally encoded but that is covered by previous rules.
These two lines contradict each other. Minimally-encoded "zero" is an array of length zero, not one. I'd suggest defining this explicitly here as "IF/NOTIF argument must be either zero-length array or a single byte 0x01".
Published at
2023-06-07 17:44:17Event JSON
{
"id": "6ed3c04a2475a1756316445fce10886c0adbfee08700b0597f93f541525994db",
"pubkey": "8a620b25e89444e9903ffc62514250941ca318d3dd371308821b4cbe30dd482a",
"created_at": 1686159857,
"kind": 1,
"tags": [
[
"e",
"8bea40c9aca13fd590801b4ac87b57a3fa19ab1b40338c62d08701cf4269e071",
"",
"root"
],
[
"e",
"da1ac7112d24447e68eeedfd87ee252d2c2d7abfe1ea1b622dcb59637def5193",
"",
"reply"
],
[
"p",
"46986f86b97cc97829a031b03209644d134b939d0163375467f0b1363e0d875e"
]
],
"content": "📅 Original date posted:2015-11-06\n📝 Original message:\u003e One and zero should be defined as arrays of length one. Otherwise, it is still possible to mutate the transaction by changing the length of the array. \n\u003e \n\u003e They should also be minimally encoded but that is covered by previous rules.\n\nThese two lines contradict each other. Minimally-encoded \"zero\" is an array of length zero, not one. I'd suggest defining this explicitly here as \"IF/NOTIF argument must be either zero-length array or a single byte 0x01\".",
"sig": "405373b34f3046f19e077416249f97e8bf3d3a48445d1ab192f61de65e9065e960df30348c8826577ca0d7c21e055b6f6435c90155208622032107c598db5e48"
}