From 51995cc228a6c65f9a74dd24962fe9562a472d83 Mon Sep 17 00:00:00 2001 From: Sjors Provoost Date: Wed, 23 Sep 2026 13:32:00 +0200 Subject: [PATCH] bip138: clarify receive-only descriptor sets Make change_descriptor explicitly optional for non-multipath descriptors. Add a receive-only document vector with no change descriptor or optional metadata; the existing vectors cover a receive/change pair and multipath. --- bip-0138.md | 3 ++- bip-0138/test_vectors/bip380_descriptor_backup.json | 12 ++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/bip-0138.md b/bip-0138.md index cca356ac..9affdfb7 100644 --- a/bip-0138.md +++ b/bip-0138.md @@ -474,7 +474,8 @@ For BIP389 multipath descriptors, `/<0;1>` means receive and change, respectively. The `change_descriptor` field MUST NOT be used. For descriptors without BIP389 multipath key expressions, `descriptor` is the -receive descriptor and `change_descriptor` is the change descriptor. +receive descriptor. The optional `change_descriptor` string can be omitted for a +receive-only set. If optional boolean `archived` is `true`, importing wallets SHOULD NOT use the descriptor set for new address generation. diff --git a/bip-0138/test_vectors/bip380_descriptor_backup.json b/bip-0138/test_vectors/bip380_descriptor_backup.json index 719d0e11..3066c8b3 100644 --- a/bip-0138/test_vectors/bip380_descriptor_backup.json +++ b/bip-0138/test_vectors/bip380_descriptor_backup.json @@ -29,5 +29,17 @@ } ] } + }, + { + "description": "Receive-only descriptor set without optional metadata", + "valid": true, + "document": { + "version": 1, + "descriptor_sets": [ + { + "descriptor": "wpkh([d34db33f/84h/1h/0h]tpubDC5FSnBiZDMmhiuCmWAYsLwgLYrrT9rAqvTySfuCCrgsWz8wxMXUS9Tb9iVMvcRbvFcAHGkMD5Kx8koh4GquNGNTfohfk7pgjhaPCdXpoba/0/*)" + } + ] + } } ]