From f015b1eda358221b251da75cad5eb636c934c7f0 Mon Sep 17 00:00:00 2001 From: Jason Chavannes Date: Fri, 23 May 2025 21:10:25 -0700 Subject: [PATCH 01/17] Use real revocation tx id --- brc100frames/acquire-certificate.ts | 3 ++- generated/brc100/acquireCertificate-simple-args.json | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/brc100frames/acquire-certificate.ts b/brc100frames/acquire-certificate.ts index f79c99a..34569f0 100644 --- a/brc100frames/acquire-certificate.ts +++ b/brc100frames/acquire-certificate.ts @@ -5,6 +5,7 @@ const SubjectPubKeyHex = "025ad43a22ac38d0bc1f8bacaabb323b5d634703b7a774c4268f6a const CertifierPubKeyHex = "0294c479f762f6baa97fbcd4393564c1d7bd8336ebd15928135bbcf575cd1a71a1"; const TypeBase64 = "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAB0ZXN0LXR5cGU="; const SerialNumberBase64 = "AAAAAAAAAAAAAAAAAAB0ZXN0LXNlcmlhbC1udW1iZXI="; +const RevocationOutpoint = "aec245f27b7640c8b1865045107731bfb848115c573f7da38166074b1c9e475d.0"; export const acquireCertificate: Record> = { 'acquireCertificate-simple': generateWireFramesFor( @@ -26,7 +27,7 @@ export const acquireCertificate: Record Date: Wed, 28 May 2025 10:31:33 -0700 Subject: [PATCH 02/17] Use actual outpoints and signatures --- brc100frames/acquire-certificate.ts | 7 ++++--- brc100frames/discover-by-attributes.ts | 4 ++-- brc100frames/discover-by-identity-key.ts | 4 ++-- brc100frames/list-certificates.ts | 4 ++-- brc100frames/prove-certificate.ts | 4 ++-- generated/brc100/acquireCertificate-simple-args.json | 2 +- generated/brc100/acquireCertificate-simple-result.json | 6 +++--- generated/brc100/discoverByAttributes-simple-result.json | 6 +++--- generated/brc100/discoverByIdentityKey-simple-result.json | 6 +++--- generated/brc100/listCertificates-simple-result.json | 6 +++--- generated/brc100/proveCertificate-simple-args.json | 6 +++--- 11 files changed, 28 insertions(+), 27 deletions(-) diff --git a/brc100frames/acquire-certificate.ts b/brc100frames/acquire-certificate.ts index 34569f0..68e5c13 100644 --- a/brc100frames/acquire-certificate.ts +++ b/brc100frames/acquire-certificate.ts @@ -16,9 +16,10 @@ export const acquireCertificate: Record Date: Wed, 28 May 2025 16:32:52 -0700 Subject: [PATCH 03/17] Use 32 bytes, not 33 --- brc100frames/list-certificates.ts | 2 +- generated/brc100/listCertificates-simple-args.json | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/brc100frames/list-certificates.ts b/brc100frames/list-certificates.ts index 14a4fde..b703659 100644 --- a/brc100frames/list-certificates.ts +++ b/brc100frames/list-certificates.ts @@ -29,7 +29,7 @@ export const listCertificates: Record Date: Fri, 6 Jun 2025 15:59:31 -0700 Subject: [PATCH 04/17] Update some tests to use real data --- brc100frames/acquire-certificate.ts | 2 +- brc100frames/create-signature.ts | 2 +- brc100frames/verify-signature.ts | 2 +- generated/brc100/acquireCertificate-simple-args.json | 2 +- generated/brc100/createSignature-simple-result.json | 4 ++-- generated/brc100/verifySignature-simple-args.json | 4 ++-- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/brc100frames/acquire-certificate.ts b/brc100frames/acquire-certificate.ts index 68e5c13..04e5706 100644 --- a/brc100frames/acquire-certificate.ts +++ b/brc100frames/acquire-certificate.ts @@ -31,7 +31,7 @@ export const acquireCertificate: Record Date: Fri, 20 Jun 2025 17:31:59 -0700 Subject: [PATCH 05/17] New ts-sdk negative one handling. Use correct data types for internalize action args. --- .gitignore | 1 + brc100frames/internalize-action.ts | 6 +++--- generated/brc100/createAction-1-out-args.json | 2 +- generated/brc100/createAction-1-out-result.json | 2 +- generated/brc100/createAction-no-signAndProcess-args.json | 2 +- .../brc100/createAction-no-signAndProcess-result.json | 2 +- generated/brc100/internalizeAction-simple-args.json | 8 ++++---- generated/brc100/listActions-simple-args.json | 2 +- generated/brc100/listActions-simple-result.json | 2 +- generated/brc100/listOutputs-simple-args.json | 2 +- generated/brc100/listOutputs-simple-result.json | 2 +- generated/brc100/signAction-simple-args.json | 2 +- generated/brc100/signAction-simple-result.json | 2 +- 13 files changed, 18 insertions(+), 17 deletions(-) diff --git a/.gitignore b/.gitignore index a77cdb7..e327e82 100644 --- a/.gitignore +++ b/.gitignore @@ -17,6 +17,7 @@ # Dependency directories (remove the comment below to include it) # vendor/ node_modules/ +bun.lock # Go workspace file go.work diff --git a/brc100frames/internalize-action.ts b/brc100frames/internalize-action.ts index b03d69c..7c71824 100644 --- a/brc100frames/internalize-action.ts +++ b/brc100frames/internalize-action.ts @@ -16,9 +16,9 @@ export const internalizeAction: Record Date: Sat, 21 Jun 2025 00:32:56 +0000 Subject: [PATCH 06/17] chore: update generated files --- generated/brc100/createAction-1-out-args.json | 2 +- generated/brc100/createAction-1-out-result.json | 2 +- generated/brc100/createAction-no-signAndProcess-args.json | 2 +- generated/brc100/createAction-no-signAndProcess-result.json | 2 +- generated/brc100/listActions-simple-args.json | 2 +- generated/brc100/listActions-simple-result.json | 2 +- generated/brc100/listOutputs-simple-args.json | 2 +- generated/brc100/listOutputs-simple-result.json | 2 +- generated/brc100/signAction-simple-args.json | 2 +- generated/brc100/signAction-simple-result.json | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) diff --git a/generated/brc100/createAction-1-out-args.json b/generated/brc100/createAction-1-out-args.json index 97ba75d..399f114 100644 --- a/generated/brc100/createAction-1-out-args.json +++ b/generated/brc100/createAction-1-out-args.json @@ -17,5 +17,5 @@ "test-label" ] }, - "wire": "0100175465737420616374696f6e206465736372697074696f6effffffffffffffffffffffffffffffffffff011976a9143cf53c49c322d9d811728182939aee2dca087f9888acfde7030b54657374206f75747075740b746573742d6261736b6574115465737420696e737472756374696f6e730108746573742d746167ffffffffffffffffffffffffffffffffffff010a746573742d6c6162656c00" + "wire": "0100175465737420616374696f6e206465736372697074696f6effff011976a9143cf53c49c322d9d811728182939aee2dca087f9888acfde7030b54657374206f75747075740b746573742d6261736b6574115465737420696e737472756374696f6e730108746573742d746167ffff010a746573742d6c6162656c00" } \ No newline at end of file diff --git a/generated/brc100/createAction-1-out-result.json b/generated/brc100/createAction-1-out-result.json index fbb67b3..4cf9d65 100644 --- a/generated/brc100/createAction-1-out-result.json +++ b/generated/brc100/createAction-1-out-result.json @@ -196,5 +196,5 @@ 0 ] }, - "wire": "000103895fb984362a4196bc9931629318fcbb2aeba7c6293638119ea653fa31d11901c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac00000000ffffffffffffffffffffffffffffffffffff00" + "wire": "000103895fb984362a4196bc9931629318fcbb2aeba7c6293638119ea653fa31d11901c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac00000000ffff00" } \ No newline at end of file diff --git a/generated/brc100/createAction-no-signAndProcess-args.json b/generated/brc100/createAction-no-signAndProcess-args.json index 33450b0..30eb11a 100644 --- a/generated/brc100/createAction-no-signAndProcess-args.json +++ b/generated/brc100/createAction-no-signAndProcess-args.json @@ -20,5 +20,5 @@ "signAndProcess": false } }, - "wire": "0100335465737420616374696f6e206465736372697074696f6e20776974682074727573742073656c6620616e64206e6f2d73656e64ffffffffffffffffffffffffffffffffffff011976a9143cf53c49c322d9d811728182939aee2dca087f9888acfde7030b54657374206f75747075740b746573742d6261736b6574115465737420696e737472756374696f6e730108746573742d746167ffffffffffffffffffffffffffffffffffff010a746573742d6c6162656c0100ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff" + "wire": "0100335465737420616374696f6e206465736372697074696f6e20776974682074727573742073656c6620616e64206e6f2d73656e64ffff011976a9143cf53c49c322d9d811728182939aee2dca087f9888acfde7030b54657374206f75747075740b746573742d6261736b6574115465737420696e737472756374696f6e730108746573742d746167ffff010a746573742d6c6162656c0100ffffffffffffffff" } \ No newline at end of file diff --git a/generated/brc100/createAction-no-signAndProcess-result.json b/generated/brc100/createAction-no-signAndProcess-result.json index 5e12b35..c0fafc9 100644 --- a/generated/brc100/createAction-no-signAndProcess-result.json +++ b/generated/brc100/createAction-no-signAndProcess-result.json @@ -198,5 +198,5 @@ "reference": "dGVzdA==" } }, - "wire": "000000ffffffffffffffffffffffffffffffffffff01c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac000000000474657374" + "wire": "000000ffff01c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac000000000474657374" } \ No newline at end of file diff --git a/generated/brc100/listActions-simple-args.json b/generated/brc100/listActions-simple-args.json index a4abe7a..f674afe 100644 --- a/generated/brc100/listActions-simple-args.json +++ b/generated/brc100/listActions-simple-args.json @@ -6,5 +6,5 @@ "includeOutputs": true, "limit": 10 }, - "wire": "0400010a746573742d6c6162656cffffffffff01ff0affffffffffffffffffff" + "wire": "0400010a746573742d6c6162656cffffffffff01ff0affff" } \ No newline at end of file diff --git a/generated/brc100/listActions-simple-result.json b/generated/brc100/listActions-simple-result.json index 4716ae6..2f87638 100644 --- a/generated/brc100/listActions-simple-result.json +++ b/generated/brc100/listActions-simple-result.json @@ -27,5 +27,5 @@ } ] }, - "wire": "00011234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdeffde80301011254657374207472616e73616374696f6e2031ffffffffffffffffff010affffffffffffffffff0101fde8031976a9143cf53c49c322d9d811728182939aee2dca087f9888ac010b54657374206f7574707574076261736b6574310204746167310474616732ffffffffffffffffff" + "wire": "00011234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdeffde80301011254657374207472616e73616374696f6e2031ff010aff0101fde8031976a9143cf53c49c322d9d811728182939aee2dca087f9888ac010b54657374206f7574707574076261736b6574310204746167310474616732ff" } \ No newline at end of file diff --git a/generated/brc100/listOutputs-simple-args.json b/generated/brc100/listOutputs-simple-args.json index f16c236..0a57d67 100644 --- a/generated/brc100/listOutputs-simple-args.json +++ b/generated/brc100/listOutputs-simple-args.json @@ -10,5 +10,5 @@ "includeTags": true, "limit": 10 }, - "wire": "06000b746573742d6261736b657402047461673104746167320201ff01ff0affffffffffffffffffff" + "wire": "06000b746573742d6261736b657402047461673104746167320201ff01ff0affff" } \ No newline at end of file diff --git a/generated/brc100/listOutputs-simple-result.json b/generated/brc100/listOutputs-simple-result.json index 5d66f68..6356455 100644 --- a/generated/brc100/listOutputs-simple-result.json +++ b/generated/brc100/listOutputs-simple-result.json @@ -20,5 +20,5 @@ } ] }, - "wire": "000204010203041234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef00fde803ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffabcdef1234567890abcdef1234567890abcdef1234567890abcdef123456789002fd8813ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff" + "wire": "000204010203041234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef00fde803ffffffffabcdef1234567890abcdef1234567890abcdef1234567890abcdef123456789002fd8813ffffffff" } \ No newline at end of file diff --git a/generated/brc100/signAction-simple-args.json b/generated/brc100/signAction-simple-args.json index 34f3d08..72802aa 100644 --- a/generated/brc100/signAction-simple-args.json +++ b/generated/brc100/signAction-simple-args.json @@ -7,5 +7,5 @@ } } }, - "wire": "020001001976a91489abcdefabbaabbaabbaabbaabbaabbaabbaabba88acffffffffffffffffff047465737400" + "wire": "020001001976a91489abcdefabbaabbaabbaabbaabbaabbaabbaabba88acff047465737400" } \ No newline at end of file diff --git a/generated/brc100/signAction-simple-result.json b/generated/brc100/signAction-simple-result.json index f7614d5..d73b1ec 100644 --- a/generated/brc100/signAction-simple-result.json +++ b/generated/brc100/signAction-simple-result.json @@ -196,5 +196,5 @@ 0 ] }, - "wire": "000103895fb984362a4196bc9931629318fcbb2aeba7c6293638119ea653fa31d11901c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac00000000ffffffffffffffffff" + "wire": "000103895fb984362a4196bc9931629318fcbb2aeba7c6293638119ea653fa31d11901c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac00000000ff" } \ No newline at end of file From e2e38be68592e7aea26c46b6b226137a886f6402 Mon Sep 17 00:00:00 2001 From: Jason Chavannes Date: Tue, 24 Jun 2025 12:25:36 -0700 Subject: [PATCH 07/17] ListOutputs spendable true --- brc100frames/list-outputs.ts | 2 +- generated/brc100/listOutputs-simple-result.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/brc100frames/list-outputs.ts b/brc100frames/list-outputs.ts index dd26d73..f578a03 100644 --- a/brc100frames/list-outputs.ts +++ b/brc100frames/list-outputs.ts @@ -13,7 +13,7 @@ export const listOutputs: Record Date: Tue, 24 Jun 2025 12:27:47 -0700 Subject: [PATCH 08/17] Overwritten updates --- generated/brc100/createAction-1-out-args.json | 2 +- generated/brc100/createAction-1-out-result.json | 2 +- generated/brc100/createAction-no-signAndProcess-args.json | 2 +- generated/brc100/createAction-no-signAndProcess-result.json | 2 +- generated/brc100/listActions-simple-args.json | 2 +- generated/brc100/listActions-simple-result.json | 2 +- generated/brc100/listOutputs-simple-args.json | 2 +- generated/brc100/listOutputs-simple-result.json | 2 +- generated/brc100/signAction-simple-args.json | 2 +- generated/brc100/signAction-simple-result.json | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) diff --git a/generated/brc100/createAction-1-out-args.json b/generated/brc100/createAction-1-out-args.json index 399f114..97ba75d 100644 --- a/generated/brc100/createAction-1-out-args.json +++ b/generated/brc100/createAction-1-out-args.json @@ -17,5 +17,5 @@ "test-label" ] }, - "wire": "0100175465737420616374696f6e206465736372697074696f6effff011976a9143cf53c49c322d9d811728182939aee2dca087f9888acfde7030b54657374206f75747075740b746573742d6261736b6574115465737420696e737472756374696f6e730108746573742d746167ffff010a746573742d6c6162656c00" + "wire": "0100175465737420616374696f6e206465736372697074696f6effffffffffffffffffffffffffffffffffff011976a9143cf53c49c322d9d811728182939aee2dca087f9888acfde7030b54657374206f75747075740b746573742d6261736b6574115465737420696e737472756374696f6e730108746573742d746167ffffffffffffffffffffffffffffffffffff010a746573742d6c6162656c00" } \ No newline at end of file diff --git a/generated/brc100/createAction-1-out-result.json b/generated/brc100/createAction-1-out-result.json index 4cf9d65..fbb67b3 100644 --- a/generated/brc100/createAction-1-out-result.json +++ b/generated/brc100/createAction-1-out-result.json @@ -196,5 +196,5 @@ 0 ] }, - "wire": "000103895fb984362a4196bc9931629318fcbb2aeba7c6293638119ea653fa31d11901c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac00000000ffff00" + "wire": "000103895fb984362a4196bc9931629318fcbb2aeba7c6293638119ea653fa31d11901c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac00000000ffffffffffffffffffffffffffffffffffff00" } \ No newline at end of file diff --git a/generated/brc100/createAction-no-signAndProcess-args.json b/generated/brc100/createAction-no-signAndProcess-args.json index 30eb11a..33450b0 100644 --- a/generated/brc100/createAction-no-signAndProcess-args.json +++ b/generated/brc100/createAction-no-signAndProcess-args.json @@ -20,5 +20,5 @@ "signAndProcess": false } }, - "wire": "0100335465737420616374696f6e206465736372697074696f6e20776974682074727573742073656c6620616e64206e6f2d73656e64ffff011976a9143cf53c49c322d9d811728182939aee2dca087f9888acfde7030b54657374206f75747075740b746573742d6261736b6574115465737420696e737472756374696f6e730108746573742d746167ffff010a746573742d6c6162656c0100ffffffffffffffff" + "wire": "0100335465737420616374696f6e206465736372697074696f6e20776974682074727573742073656c6620616e64206e6f2d73656e64ffffffffffffffffffffffffffffffffffff011976a9143cf53c49c322d9d811728182939aee2dca087f9888acfde7030b54657374206f75747075740b746573742d6261736b6574115465737420696e737472756374696f6e730108746573742d746167ffffffffffffffffffffffffffffffffffff010a746573742d6c6162656c0100ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff" } \ No newline at end of file diff --git a/generated/brc100/createAction-no-signAndProcess-result.json b/generated/brc100/createAction-no-signAndProcess-result.json index c0fafc9..5e12b35 100644 --- a/generated/brc100/createAction-no-signAndProcess-result.json +++ b/generated/brc100/createAction-no-signAndProcess-result.json @@ -198,5 +198,5 @@ "reference": "dGVzdA==" } }, - "wire": "000000ffff01c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac000000000474657374" + "wire": "000000ffffffffffffffffffffffffffffffffffff01c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac000000000474657374" } \ No newline at end of file diff --git a/generated/brc100/listActions-simple-args.json b/generated/brc100/listActions-simple-args.json index f674afe..a4abe7a 100644 --- a/generated/brc100/listActions-simple-args.json +++ b/generated/brc100/listActions-simple-args.json @@ -6,5 +6,5 @@ "includeOutputs": true, "limit": 10 }, - "wire": "0400010a746573742d6c6162656cffffffffff01ff0affff" + "wire": "0400010a746573742d6c6162656cffffffffff01ff0affffffffffffffffffff" } \ No newline at end of file diff --git a/generated/brc100/listActions-simple-result.json b/generated/brc100/listActions-simple-result.json index 2f87638..4716ae6 100644 --- a/generated/brc100/listActions-simple-result.json +++ b/generated/brc100/listActions-simple-result.json @@ -27,5 +27,5 @@ } ] }, - "wire": "00011234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdeffde80301011254657374207472616e73616374696f6e2031ff010aff0101fde8031976a9143cf53c49c322d9d811728182939aee2dca087f9888ac010b54657374206f7574707574076261736b6574310204746167310474616732ff" + "wire": "00011234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdeffde80301011254657374207472616e73616374696f6e2031ffffffffffffffffff010affffffffffffffffff0101fde8031976a9143cf53c49c322d9d811728182939aee2dca087f9888ac010b54657374206f7574707574076261736b6574310204746167310474616732ffffffffffffffffff" } \ No newline at end of file diff --git a/generated/brc100/listOutputs-simple-args.json b/generated/brc100/listOutputs-simple-args.json index 0a57d67..f16c236 100644 --- a/generated/brc100/listOutputs-simple-args.json +++ b/generated/brc100/listOutputs-simple-args.json @@ -10,5 +10,5 @@ "includeTags": true, "limit": 10 }, - "wire": "06000b746573742d6261736b657402047461673104746167320201ff01ff0affff" + "wire": "06000b746573742d6261736b657402047461673104746167320201ff01ff0affffffffffffffffffff" } \ No newline at end of file diff --git a/generated/brc100/listOutputs-simple-result.json b/generated/brc100/listOutputs-simple-result.json index 8659633..ce113af 100644 --- a/generated/brc100/listOutputs-simple-result.json +++ b/generated/brc100/listOutputs-simple-result.json @@ -20,5 +20,5 @@ } ] }, - "wire": "000204010203041234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef00fde803ffffffffabcdef1234567890abcdef1234567890abcdef1234567890abcdef123456789002fd8813ffffffff" + "wire": "000204010203041234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef00fde803ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffabcdef1234567890abcdef1234567890abcdef1234567890abcdef123456789002fd8813ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff" } \ No newline at end of file diff --git a/generated/brc100/signAction-simple-args.json b/generated/brc100/signAction-simple-args.json index 72802aa..34f3d08 100644 --- a/generated/brc100/signAction-simple-args.json +++ b/generated/brc100/signAction-simple-args.json @@ -7,5 +7,5 @@ } } }, - "wire": "020001001976a91489abcdefabbaabbaabbaabbaabbaabbaabbaabba88acff047465737400" + "wire": "020001001976a91489abcdefabbaabbaabbaabbaabbaabbaabbaabba88acffffffffffffffffff047465737400" } \ No newline at end of file diff --git a/generated/brc100/signAction-simple-result.json b/generated/brc100/signAction-simple-result.json index d73b1ec..f7614d5 100644 --- a/generated/brc100/signAction-simple-result.json +++ b/generated/brc100/signAction-simple-result.json @@ -196,5 +196,5 @@ 0 ] }, - "wire": "000103895fb984362a4196bc9931629318fcbb2aeba7c6293638119ea653fa31d11901c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac00000000ff" + "wire": "000103895fb984362a4196bc9931629318fcbb2aeba7c6293638119ea653fa31d11901c001000000017cd347a6a099f82cde68faec941e888ebc3489b25403e3ffedd3280f3fa4cc03000000006b483045022100f269c3f340a9cfae580b057429f91e1fcb2d0afccb5a3b9d194d705b4decfbda0220725a74244d4618654335f3e14b9fceb50ada1f679bb8a00c087571643eb974714121034d2d6d23fbcb6eefe3e80c47044e36797dcb80d0ac5e96e732ef03c3c550a116ffffffff01e7030000000000001976a9143cf53c49c322d9d811728182939aee2dca087f9888ac00000000ffffffffffffffffff" } \ No newline at end of file From b9df4e924db2d123a11fa16dbe98ba096abaf4e7 Mon Sep 17 00:00:00 2001 From: Jason Chavannes Date: Tue, 24 Jun 2025 14:35:20 -0700 Subject: [PATCH 09/17] Update tests --- brc100frames/create-hmac.ts | 5 +++- brc100frames/get-public-key.ts | 1 - brc100frames/verify-hmac.ts | 5 +++- .../brc100/createHmac-simple-result.json | 26 ++++++++++++++++++- .../brc100/getPublicKey-simple-args.json | 5 ++-- generated/brc100/verifyHmac-simple-args.json | 26 ++++++++++++++++++- 6 files changed, 60 insertions(+), 8 deletions(-) diff --git a/brc100frames/create-hmac.ts b/brc100frames/create-hmac.ts index bfeb055..e398299 100644 --- a/brc100frames/create-hmac.ts +++ b/brc100frames/create-hmac.ts @@ -6,7 +6,10 @@ export const createHmac: Record 'createHmac-simple': generateWireFramesFor( 'createHmac', { - hmac: [50, 60, 70, 80, 90, 100, 110, 120], + hmac: [50, 60, 70, 80, 90, 100, 110, 120, + 50, 60, 70, 80, 90, 100, 110, 120, + 50, 60, 70, 80, 90, 100, 110, 120, + 50, 60, 70, 80, 90, 100, 110, 120], }, { protocolID: [1 /* SecurityLevelEveryApp */, 'test-protocol'], diff --git a/brc100frames/get-public-key.ts b/brc100frames/get-public-key.ts index 0a02c1a..d942830 100644 --- a/brc100frames/get-public-key.ts +++ b/brc100frames/get-public-key.ts @@ -17,7 +17,6 @@ export const getPublicKey: Record privilegedReason: 'test reason', seekPermission: true, data: [10, 20, 30, 40], - hmac: [50, 60, 70, 80, 90, 100, 110, 120], + hmac: [50, 60, 70, 80, 90, 100, 110, 120, + 50, 60, 70, 80, 90, 100, 110, 120, + 50, 60, 70, 80, 90, 100, 110, 120, + 50, 60, 70, 80, 90, 100, 110, 120], } ), // Add more cases if needed diff --git a/generated/brc100/createHmac-simple-result.json b/generated/brc100/createHmac-simple-result.json index 6acaf4f..04751c2 100644 --- a/generated/brc100/createHmac-simple-result.json +++ b/generated/brc100/createHmac-simple-result.json @@ -1,6 +1,30 @@ { "json": { "hmac": [ + 50, + 60, + 70, + 80, + 90, + 100, + 110, + 120, + 50, + 60, + 70, + 80, + 90, + 100, + 110, + 120, + 50, + 60, + 70, + 80, + 90, + 100, + 110, + 120, 50, 60, 70, @@ -11,5 +35,5 @@ 120 ] }, - "wire": "00323c46505a646e78" + "wire": "00323c46505a646e78323c46505a646e78323c46505a646e78323c46505a646e78" } \ No newline at end of file diff --git a/generated/brc100/getPublicKey-simple-args.json b/generated/brc100/getPublicKey-simple-args.json index 3c06230..14140af 100644 --- a/generated/brc100/getPublicKey-simple-args.json +++ b/generated/brc100/getPublicKey-simple-args.json @@ -8,8 +8,7 @@ "counterparty": "0294c479f762f6baa97fbcd4393564c1d7bd8336ebd15928135bbcf575cd1a71a1", "privileged": true, "privilegedReason": "privileged reason", - "seekPermission": true, - "identityKey": true + "seekPermission": true }, - "wire": "080001011170726976696c6567656420726561736f6e01" + "wire": "080000020574657374730b746573742d6b65792d69640294c479f762f6baa97fbcd4393564c1d7bd8336ebd15928135bbcf575cd1a71a1011170726976696c6567656420726561736f6eff01" } \ No newline at end of file diff --git a/generated/brc100/verifyHmac-simple-args.json b/generated/brc100/verifyHmac-simple-args.json index 0441695..e8069d6 100644 --- a/generated/brc100/verifyHmac-simple-args.json +++ b/generated/brc100/verifyHmac-simple-args.json @@ -16,6 +16,30 @@ 40 ], "hmac": [ + 50, + 60, + 70, + 80, + 90, + 100, + 110, + 120, + 50, + 60, + 70, + 80, + 90, + 100, + 110, + 120, + 50, + 60, + 70, + 80, + 90, + 100, + 110, + 120, 50, 60, 70, @@ -26,5 +50,5 @@ 120 ] }, - "wire": "0e00010d746573742d70726f746f636f6c08746573742d6b65790b010b7465737420726561736f6e323c46505a646e78040a141e2801" + "wire": "0e00010d746573742d70726f746f636f6c08746573742d6b65790b010b7465737420726561736f6e323c46505a646e78323c46505a646e78323c46505a646e78323c46505a646e78040a141e2801" } \ No newline at end of file From fa3f5c226e5d90630fe5ba064633e6ebdbef3aa2 Mon Sep 17 00:00:00 2001 From: Jason Chavannes Date: Wed, 2 Jul 2025 12:00:31 -0700 Subject: [PATCH 10/17] Split AcquireCertificate tests --- brc100frames/acquire-certificate.ts | 26 +++++++++++++++++-- .../acquireCertificate-issuance-args.json | 14 ++++++++++ .../acquireCertificate-issuance-result.json | 15 +++++++++++ .../acquireCertificate-simple-args.json | 5 ++-- 4 files changed, 55 insertions(+), 5 deletions(-) create mode 100644 generated/brc100/acquireCertificate-issuance-args.json create mode 100644 generated/brc100/acquireCertificate-issuance-result.json diff --git a/brc100frames/acquire-certificate.ts b/brc100frames/acquire-certificate.ts index 04e5706..0fc25d2 100644 --- a/brc100frames/acquire-certificate.ts +++ b/brc100frames/acquire-certificate.ts @@ -25,16 +25,38 @@ export const acquireCertificate: Record Date: Wed, 2 Jul 2025 13:42:46 -0700 Subject: [PATCH 11/17] Remove problem fields from simple list certs. Add full list certs vector. --- brc100frames/list-certificates.ts | 31 +++++++++++++++++-- .../brc100/listCertificates-full-args.json | 17 ++++++++++ .../brc100/listCertificates-full-result.json | 25 +++++++++++++++ .../listCertificates-simple-result.json | 7 +---- 4 files changed, 72 insertions(+), 8 deletions(-) create mode 100644 generated/brc100/listCertificates-full-args.json create mode 100644 generated/brc100/listCertificates-full-result.json diff --git a/brc100frames/list-certificates.ts b/brc100frames/list-certificates.ts index b703659..6f13b86 100644 --- a/brc100frames/list-certificates.ts +++ b/brc100frames/list-certificates.ts @@ -1,4 +1,5 @@ import {generateWireFramesFor} from "./generator/wire-frames-generator"; +import {ListCertificatesArgs, ListCertificatesResult} from "@bsv/sdk"; // Define the keys used in the test cases const pubKeyHex = "025ad43a22ac38d0bc1f8bacaabb323b5d634703b7a774c4268f6a09e4ddf79097"; @@ -7,6 +8,32 @@ const VerifierHex = "03b106dae20ae8fca0f4e8983d974c4b583054573eecdcdcfad261c0354 export const listCertificates: Record> = { 'listCertificates-simple': generateWireFramesFor( + 'listCertificates', // Corresponds to the Go function/substrate call + { // Result object definition + totalCertificates: 1, + certificates: [ + { + // Certificate fields + type: "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAB0ZXN0LXR5cGU=", + serialNumber: "AAAAAAAAAAAAAAAAAAB0ZXN0LXNlcmlhbC1udW1iZXI=", + subject: pubKeyHex, + certifier: CounterpartyHex, + revocationOutpoint: "aec245f27b7640c8b1865045107731bfb848115c573f7da38166074b1c9e475d.0", + fields: {"name": "Alice", "email": "alice@example.com"}, + signature: "3045022100a6f09ee70382ab364f3f6b040aebb8fe7a51dbc3b4c99cfeb2f7756432162833022067349b91a6319345996faddf36d1b2f3a502e4ae002205f9d2db85474f9aed5a", + } + ] + } as ListCertificatesResult, + { // Args object definition + certifiers: [CounterpartyHex, VerifierHex], + types: ["dGVzdC10eXBlMSAgICAgICAgICAgICAgICAgICAgICA=", "dGVzdC10eXBlMiAgICAgICAgICAgICAgICAgICAgICA="], + limit: 5, + offset: 0, + privileged: true, + privilegedReason: "list-cert-reason", + } as ListCertificatesArgs + ), + 'listCertificates-full': generateWireFramesFor( 'listCertificates', // Corresponds to the Go function/substrate call { // Result object definition totalCertificates: 1, @@ -26,7 +53,7 @@ export const listCertificates: Record Date: Wed, 2 Jul 2025 13:43:31 -0700 Subject: [PATCH 12/17] Don't convert -1 hex (should be fixed elsewhere now) --- brc100frames/generator/wire-frames-generator.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/brc100frames/generator/wire-frames-generator.ts b/brc100frames/generator/wire-frames-generator.ts index e3e8b01..01c6f47 100644 --- a/brc100frames/generator/wire-frames-generator.ts +++ b/brc100frames/generator/wire-frames-generator.ts @@ -42,6 +42,5 @@ export async function generateWireFramesFor< } function frameNumbersToHex(numbers: number[]): string { - const body = new Uint8Array(numbers) - return Array.from(body, byte => byte.toString(16).padStart(2, '0')).join(''); + return Array.from(numbers, num => num.toString(16).padStart(2, '0')).join(''); } From 9d552470841bdcb67a7f93e5920fe265e18e9539 Mon Sep 17 00:00:00 2001 From: Jason Chavannes Date: Wed, 2 Jul 2025 15:25:33 -0700 Subject: [PATCH 13/17] Discover and prove certificate vectors --- brc100frames/discover-by-attributes.ts | 2 +- brc100frames/discover-by-identity-key.ts | 2 +- brc100frames/prove-certificate.ts | 2 +- generated/brc100/discoverByAttributes-simple-result.json | 4 ++-- generated/brc100/discoverByIdentityKey-simple-result.json | 4 ++-- generated/brc100/proveCertificate-simple-result.json | 4 ++-- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/brc100frames/discover-by-attributes.ts b/brc100frames/discover-by-attributes.ts index 28b0ae5..e0304bd 100644 --- a/brc100frames/discover-by-attributes.ts +++ b/brc100frames/discover-by-attributes.ts @@ -28,7 +28,7 @@ export const discoverByAttributes: Record Date: Mon, 7 Jul 2025 11:38:43 -0700 Subject: [PATCH 14/17] Use alphabetical ordering so serialization matches --- brc100frames/prove-certificate.ts | 2 +- generated/brc100/proveCertificate-simple-args.json | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/brc100frames/prove-certificate.ts b/brc100frames/prove-certificate.ts index 78c4b3a..53e248a 100644 --- a/brc100frames/prove-certificate.ts +++ b/brc100frames/prove-certificate.ts @@ -20,7 +20,7 @@ export const proveCertificate: Record Date: Mon, 7 Jul 2025 11:41:00 -0700 Subject: [PATCH 15/17] Bump ts-sdk version to get serialization updates --- package-lock.json | 8 ++++---- package.json | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package-lock.json b/package-lock.json index 3cb9791..506b019 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5,7 +5,7 @@ "packages": { "": { "dependencies": { - "@bsv/sdk": "^1.4.15" + "@bsv/sdk": "^1.6.11" }, "devDependencies": { "@types/node": "^22.13.17", @@ -13,9 +13,9 @@ } }, "node_modules/@bsv/sdk": { - "version": "1.4.15", - "resolved": "https://registry.npmjs.org/@bsv/sdk/-/sdk-1.4.15.tgz", - "integrity": "sha512-dtcyIBzayIkXFZ0hc1dbWcrUtymbhupeRoxy0o4zwbmzlyj8r2uX9VjYTanTq/WhCUzSMD2BYAnvY4LEN8IfIg==", + "version": "1.6.11", + "resolved": "https://registry.npmjs.org/@bsv/sdk/-/sdk-1.6.11.tgz", + "integrity": "sha512-VCPvvYiB7haovSwsA7v/aHsgHDT/EGAre1j1mfMVBH7zfwxw9tYfOoYRbo+1YeowXDbtyOFSxUL5EUY2OLrB6Q==", "license": "SEE LICENSE IN LICENSE.txt" }, "node_modules/@types/node": { diff --git a/package.json b/package.json index 1a2f4e4..b80ea05 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,6 @@ "typescript": "^5.8.2" }, "dependencies": { - "@bsv/sdk": "^1.4.15" + "@bsv/sdk": "^1.6.11" } } From 522fd103bd48bc77af85e33fa78d7c93ec414c00 Mon Sep 17 00:00:00 2001 From: Jason Chavannes Date: Wed, 17 Sep 2025 11:10:42 -0700 Subject: [PATCH 16/17] InternalizeAction utf8 vector instead of base64 --- brc100frames/internalize-action.ts | 4 ++-- generated/brc100/internalizeAction-simple-args.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/brc100frames/internalize-action.ts b/brc100frames/internalize-action.ts index 7c71824..5e9ed62 100644 --- a/brc100frames/internalize-action.ts +++ b/brc100frames/internalize-action.ts @@ -16,8 +16,8 @@ export const internalizeAction: Record Date: Wed, 17 Sep 2025 18:11:37 +0000 Subject: [PATCH 17/17] chore: update generated files --- generated/brc100/internalizeAction-simple-args.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/generated/brc100/internalizeAction-simple-args.json b/generated/brc100/internalizeAction-simple-args.json index 626cb8b..6b56944 100644 --- a/generated/brc100/internalizeAction-simple-args.json +++ b/generated/brc100/internalizeAction-simple-args.json @@ -36,5 +36,5 @@ } ] }, - "wire": "0500040102030402000103b106dae20ae8fca0f4e8983d974c4b583054573eecdcdcfad261c035415ce1ee067072656669780673756666697801020b746573742d6261736b65740b696e737472756374696f6e020474616731047461673202066c6162656c31066c6162656c321074657374207472616e73616374696f6e01" + "wire": "0500040102030402000103b106dae20ae8fca0f4e8983d974c4b583054573eecdcdcfad261c035415ce1ee04a6b79f8b04b2e7df8b01020b746573742d6261736b65740b696e737472756374696f6e020474616731047461673202066c6162656c31066c6162656c321074657374207472616e73616374696f6e01" } \ No newline at end of file