From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Fri, 17 Jan 2025 05:48:34 -0800 Received: from mail-oo1-f64.google.com ([209.85.161.64]) by mail.fairlystable.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1tYmi9-0006Wz-V5 for bitcoindev@gnusha.org; Fri, 17 Jan 2025 05:48:34 -0800 Received: by mail-oo1-f64.google.com with SMTP id 006d021491bc7-5f6e2ef3190sf1651912eaf.1 for ; Fri, 17 Jan 2025 05:48:33 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1737121707; cv=pass; d=google.com; s=arc-20240605; b=Je3boLrunSGyuZ782RIbZhHqhii/rIXHMF3aN01ZcOpRnL4Dp/eKzvuzJwQ3a55H/f DYHnKmPCdertPY54r/QS1ABRFXujP+KSg+tXDGzg+aql70wxvv4SvPQFq7hjHxhuzuyE XW4EFKXxVuPgrZNdYyq1cXjUqp/fMAyBiKuTgaDX34mv+gL4v3J+bqv1UQ5OIChiZLS7 gnZEAgliNeTjFXagWMxJ7Mvx/+lSIYqaHPcomsBi5OU9PkYgpbKxzPZJ6pm+sJH/rhBm ER4pzrjCN0WFXMknUaXDEgsmzNCZgChjt689gCJima7dkyI/c3O58o9Gi09SOfJo/YfX ykXA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:sender:dkim-signature :dkim-signature; bh=Q34lA6oSb5wXDDufAiJ4fSmhF63idIuAPsalWzcmAlA=; fh=7Gzg6+UulecU7lIvB+sIvyZDsp6viLXq1BO4tbmYGG0=; b=EpGvs4WfqHnBwws8jZy7iDVLJLI0nhbP7J1anmGohlysCysgrDtMsjXF+auuucA8At VtebHSlug4fI1OyGE5tCfgjtUyXBeK8ij1CB0PizqoTSW2nTCGN2CztIisC4BTAZ4U3e eBymkn05ypYWSPBLkiQMlYMCykjalQhr7wyEQkB06NiU7ETEy5b55zqjnjStsvW9J9RH hAxTJRLtyTooUU/nVQpRTrZwnZK6Y6Mw7Iuumo4QpX0vcjUCbHaceJwGFEymmSKPpc94 vV/qGA+oZ+LXHwpoiHVhAegCUeL4h+3k4rBb2fOamaC02wp+EZHeWfi4STXwjBIBhyJH i66g==; darn=gnusha.org ARC-Authentication-Results: i=2; gmr-mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=FTUT+sK1; spf=pass (google.com: domain of salvatore.ingala@gmail.com designates 2607:f8b0:4864:20::c29 as permitted sender) smtp.mailfrom=salvatore.ingala@gmail.com; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com; dara=pass header.i=@googlegroups.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1737121707; x=1737726507; darn=gnusha.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:x-original-authentication-results :x-original-sender:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:sender:from:to:cc:subject:date:message-id :reply-to; bh=Q34lA6oSb5wXDDufAiJ4fSmhF63idIuAPsalWzcmAlA=; b=aVQXL9gB0/U4t4kFRjzL7+240/Z1xSUCoU0TTIiOmnCk1dEOkqfgeWUaTgw0s3sb1c L/8Ye3BzuEXm9mOYCNvNBajFw0vYIFzJ1sJUy5QkevTChNqqj5Gul0Rry1ZldalaxmnI Qhti8z94vwUKy4tTI2An7wC+Dw1IHjB1hAHDVBrNDAjDWE0CGWIVnOtSShoo9FjdAC1L nStsD9TQipMrMjIubQ/Y5ow6lNXtKAJ99N7Vo0haXD2qRC+rHJr1dqGhMmr/Ww2Ih9u7 X0mPIf6oh55M10A6VKomJfX4BPsMTml1T0fJT5ut1o07r5tJC9hKMU3anSrmGhEu+z+X DvQg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1737121707; x=1737726507; darn=gnusha.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:x-original-authentication-results :x-original-sender:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Q34lA6oSb5wXDDufAiJ4fSmhF63idIuAPsalWzcmAlA=; b=acwlAoiQH3YQgJ5D8xUTFEUUxFaWFtNNj8RiNelS/RJrzD/v9jsE/p3gNr0ioyCAGc vUzsQ7fWGK3dxfyDyM0fdt78RPNIswx5NPhgJs0r9hWCnDnbG1ROd6hSprZJZcQ1+3td vs4YeV2/hd19/V0dmHEp13cWO7vgFguOYz+48JXCeuUlnLmBW4D8u/df/HzCq0npbcfc qQJ9AWwiMect+CmEBC7lLQjTbiN520VSFaZ7o4FgHMm2NAogcXP4w8MamhDoQ0Uu9cRM 2HJ+MTIVG3aEobYBHCt8Dlf/Yl+cwmTDOtxo1mzbjfb9/TCGJ5mLGOIE0PauggYAlhfF w8tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1737121707; x=1737726507; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:x-original-authentication-results :x-original-sender:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:x-beenthere:x-gm-message-state:sender:from :to:cc:subject:date:message-id:reply-to; bh=Q34lA6oSb5wXDDufAiJ4fSmhF63idIuAPsalWzcmAlA=; b=WCx621f06kMSXJTynIwrw0E8o5OHyURSnq62LMp+kEVV2EIJkTU6YTEGe7lDPrGjm8 VD7HrKTdP55XM74a3r0aGoKkeHbzRcl0gZQUMXzuQ4UXTEOwL0Oepowe9ylc3crqh7S0 9pt5GJoO0u5Lg8R3y6ZfzflJOqdGi3d8LIqghVKwR/1aBarA5twjh5+ZBbtL+UV7Flmq VRO2eH5UwpqUElRvPn9m30TiVfFu7jgh7Fe2LiK0+EzG9ansRqBYs5HNaaPjMD+EJqQS RqExcPhFNdlIXP5VaL1IIcX0Al7fkWkQEOX3aQghNT1/cizBwk/PE3mjXORcXKCiJMBm GTEg== Sender: bitcoindev@googlegroups.com X-Forwarded-Encrypted: i=2; AJvYcCW0IloK9PiTUA54Z5lOStpSSdfpTc4tBngYg42JJpTf3E4wCaF2K3EPliJLbZOvKrLLDV5Y3oX5L92S@gnusha.org X-Gm-Message-State: AOJu0Yy4OaiHpwa/dtDyFwPnszI0We7tUi9Xyn+KkVns9HaaQ6cNVqQo Nf5yiQ1LplQo3s2M96v9h8KV4+9//IDuxiB2sbUB720cKsTGytEH X-Google-Smtp-Source: AGHT+IGoGebkqeCODwmDVcgMgjp7nZ5TkFXk7NJTlzhN2yxfz79soS6LrZDS4L5+ImyjTCqk1R9HvQ== X-Received: by 2002:a05:6820:4d01:b0:5f6:a2c6:fea with SMTP id 006d021491bc7-5fa38db103cmr1354615eaf.0.1737121707178; Fri, 17 Jan 2025 05:48:27 -0800 (PST) X-BeenThere: bitcoindev@googlegroups.com Received: by 2002:a05:6820:c20c:b0:5f2:d36c:1775 with SMTP id 006d021491bc7-5fa28766405ls807527eaf.0.-pod-prod-00-us; Fri, 17 Jan 2025 05:48:25 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCUv9NOs3MFID7Y/V+ovXVPcg60iLCEilVr55+b3D1BauoY889YvCOq06NeMBeqPAqOmpxL6oHvZ2avS@googlegroups.com X-Received: by 2002:a05:6808:130c:b0:3eb:58bd:1a42 with SMTP id 5614622812f47-3f095af8fd1mr6704966b6e.12.1737121704935; Fri, 17 Jan 2025 05:48:24 -0800 (PST) Received: by 2002:a05:6808:101:b0:3eb:7446:f871 with SMTP id 5614622812f47-3f1a00c64cemsb6e; Fri, 17 Jan 2025 05:03:02 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCUzE8DWvffS7uM7FcNR1NYucAp2e4SxMKEObsGZZBGdN2wdjalH1v4Ch3X6CIcQi7URKPMwxekCCEKK@googlegroups.com X-Received: by 2002:a05:6830:e0b:b0:71d:4dbb:7232 with SMTP id 46e09a7af769-724858ec912mr6017926a34.3.1737118981919; Fri, 17 Jan 2025 05:03:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1737118981; cv=none; d=google.com; s=arc-20240605; b=kd92G5Br+4p6e3MPUZXN+JMwVjV3VLkxiPJnqlMRhLiKCQmz23Kj+hKRJTvQLbGWUz joCYrGM0qXWL9nf1M9TafpENiCUSy3V33WIQxYyi5MpB3+ABeHkWBzT7Fd3eOo5R+Bq1 mmkWWWA+6mSyYcYQ0L8/xZ0TDBIjFMYs/v/wTBW5FKEX1T2YR7cSREOFcYNqZc2OiBz8 7q/LBpP6z3ghsiUCxEY0N1rzCa2w0Kqx7RNJ0JmJtsFREnEi9GsFtAMs59cwFCRcOvKl alspYsFR7CszXe+flhEkRk8Z1SXulp+05ixKC7SnfziTRt/p/AuWTK772g/AidSkVCzz dlAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=ZGrX1fLB6yw27KeWSQE+t/r8rhdnKJSatbuH9dy8Bmw=; fh=z/T0aH+C56ZnyY6MxrG/SVvdc//FHjhQwJzV/UowaSc=; b=QoSz0ts0LhD++6o/B3SzQWg1SvmN/NgnrI0cLcN9+8eeESrx9yuQrEQiGqIVy80BHy x2aeWlgaj3qn8Q4UzfkreaYa9G4HCM1Y2Rjr9H2dzHTLQp80wHR3Xgi0vz9FNtREKnas h5ZyH+ci0W+Xc6tk87+R/bxqJT8Nh2N5yc6Z9tr4aQ46XMNq1M78DOYFjiW8SD3xp43a 1hpVuQvw5A+cDHhNm1laDDnt39aCfxls1JubBDFlcE18b6EtxPeedagoRpVF7HHkVqwt LYHlkyqrIeY68xqp8CkHXUHhn99klHcT9SmKFZJiRVdVOkQewZ4rYfTGFpCTaaycKPmc WZpA==; dara=google.com ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=FTUT+sK1; spf=pass (google.com: domain of salvatore.ingala@gmail.com designates 2607:f8b0:4864:20::c29 as permitted sender) smtp.mailfrom=salvatore.ingala@gmail.com; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com; dara=pass header.i=@googlegroups.com Received: from mail-oo1-xc29.google.com (mail-oo1-xc29.google.com. [2607:f8b0:4864:20::c29]) by gmr-mx.google.com with ESMTPS id 46e09a7af769-7249b22a28dsi101636a34.0.2025.01.17.05.03.01 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 17 Jan 2025 05:03:01 -0800 (PST) Received-SPF: pass (google.com: domain of salvatore.ingala@gmail.com designates 2607:f8b0:4864:20::c29 as permitted sender) client-ip=2607:f8b0:4864:20::c29; Received: by mail-oo1-xc29.google.com with SMTP id 006d021491bc7-5f321876499so1124240eaf.1 for ; Fri, 17 Jan 2025 05:03:01 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCWv4J5nxYgXsX4Vih4v4PC5gaqJ/eBbQ4iSw+ER2feMQuwlT2//wSami6auR/YPhszYg5Tsf3lKws5L@googlegroups.com X-Gm-Gg: ASbGncsogREpp9Ti/fPrgeFDWRBTP8idHN4fPcHuiv7LMlTyWsZkWHDZNQk3oCIA5nx m26D3MyTgs9enEeKkY/eMeZng8jUDMdlMS4dC3A== X-Received: by 2002:a05:6870:ae03:b0:29f:b645:ce86 with SMTP id 586e51a60fabf-2b186c1ffe1mr6782961fac.12.1737118981191; Fri, 17 Jan 2025 05:03:01 -0800 (PST) MIME-Version: 1.0 References: <6FDAD97F-7C5F-474B-9EE6-82092C9073C5@sprovoost.nl> In-Reply-To: From: Salvatore Ingala Date: Fri, 17 Jan 2025 14:02:50 +0100 X-Gm-Features: AbW1kvamfab7yqIXS5TsIZ17XvuE6ocjKUmxKusj5PKu77kPks8_iRNZVJkUyWE Message-ID: Subject: Re: [bitcoindev] Who uses or wants to use PSBTv2 (BIP370) To: Kalle Rosenbaum Cc: Sjors Provoost , bitcoindev@googlegroups.com Content-Type: multipart/alternative; boundary="000000000000ce8178062be687d4" X-Original-Sender: salvatore.ingala@gmail.com X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=FTUT+sK1; spf=pass (google.com: domain of salvatore.ingala@gmail.com designates 2607:f8b0:4864:20::c29 as permitted sender) smtp.mailfrom=salvatore.ingala@gmail.com; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com; dara=pass header.i=@googlegroups.com Precedence: list Mailing-list: list bitcoindev@googlegroups.com; contact bitcoindev+owners@googlegroups.com List-ID: X-Google-Group-Id: 786775582512 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , X-Spam-Score: -0.5 (/) --000000000000ce8178062be687d4 Content-Type: text/plain; charset="UTF-8" Yes, but it is to be noted that all the Psbt implementations in the various Ledger client libraries are bare bones, containing just what's needed for the communication protocol. They are not general purpose and not otherwise complete (nor planned to become so). Best, Salvatore Ingala On Fri, 17 Jan 2025 at 11:38, Kalle Rosenbaum wrote: > I might have linked to a slightly outdated version of ledger's psbtv2. I > haven't been involved lately. The correct one could be > https://github.com/LedgerHQ/app-bitcoin-new/blob/53dfd1727ab55182f9e365747b26b862e48b7b8b/bitcoin_client_js/src/lib/psbtv2.ts. > Is that right, Salvatore? > > /Kalle > > On Fri, 17 Jan 2025 at 11:03, Salvatore Ingala > wrote: > >> Hi Sjors, >> >> The Ledger Bitcoin app uses PSBTv2 since version 2.0.0 in 2021 [0], quite >> possibly the first adopter - although for somewhat unusual reasons. >> >> Working with embedded devices with just a few kb of RAM, even sending the >> entire PSBT is not generally feasible. >> Therefore, the client instead sends a 'merkleized' commitment to the >> entire PSBT at the beginning of the signing process. >> This enables the device to obtain random access to the PSBT by querying >> the client (who provides the data - and the Merkle proof - on demand). >> >> In PsbtV0, the unsigned transaction is a binary blob, which was a huge >> headache because the device had to parse it while streaming it (and >> therefore, no RAM access to the individual transaction fields is possible). >> PsbtV2 fixed this by having the transaction already 'parsed' into >> individual fields. >> >> The companion client libraries of the Ledger Bitcoin app support both >> versions, and PsbtV0 is converted to PsbtV2 on the fly. >> Broader support would certainly be useful. >> >> Best, >> Salvatore Ingala >> >> [0] https://www.ledger.com/blog/bitcoin-2 >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Bitcoin Development Mailing List" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to bitcoindev+unsubscribe@googlegroups.com. >> To view this discussion visit >> https://groups.google.com/d/msgid/bitcoindev/CAMhCMoGONKFok_SuZkic%2BT%3DyoWZs5eeVxtwJL6Ei%3DyysvA8rrg%40mail.gmail.com >> >> . >> > -- You received this message because you are subscribed to the Google Groups "Bitcoin Development Mailing List" group. To unsubscribe from this group and stop receiving emails from it, send an email to bitcoindev+unsubscribe@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/CAMhCMoGArSJ1_x2yhqUuedVpBZt1iPwioujJCH2eLVPEy9_QNA%40mail.gmail.com. --000000000000ce8178062be687d4 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Yes, but it is to be noted that all the Psbt implementatio= ns in the various Ledger client libraries are bare bones, containing just w= hat's needed for the communication protocol.
They are not general p= urpose and not otherwise complete (nor planned to become so).

Best,
Salvatore Ingala

On Fri, 17 Jan 2025 at 11= :38, Kalle Rosenbaum <kalle@rosenbaum.se> wrote:
I might have linked to a slightly = outdated version of ledger's psbtv2. I haven't been involved lately= . The correct one could be=C2=A0https://github.com/LedgerHQ/app-bitco= in-new/blob/53dfd1727ab55182f9e365747b26b862e48b7b8b/bitcoin_client_js/src/= lib/psbtv2.ts. Is that right, Salvatore?

/Kalle

On Fri, 17 Jan 20= 25 at 11:03, Salvatore Ingala <salvatore.ingala@gmail.com> wrote:
<= blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-l= eft:1px solid rgb(204,204,204);padding-left:1ex">
Hi=C2=A0Sjors,

The Ledger Bitcoin app uses PSBT= v2 since version 2.0.0 in 2021 [0], quite possibly the first adopter - alth= ough for somewhat unusual reasons.

Working with em= bedded devices with just a few kb of RAM, even sending the entire PSBT is n= ot generally feasible.
Therefore, the client instead sends a 'merkle= ized' commitment to the entire PSBT at the beginning of the signing pro= cess.
This enables the device to obtain random access to the PSBT= by querying the client (who provides the data - and the Merkle proof - on = demand).

In PsbtV0, the unsigned transaction is a binary blob, which= was a huge headache because the device had to=C2=A0parse it while streamin= g it (and therefore, no RAM access to the individual transaction fields is = possible).
PsbtV2 fixed this by having the transaction already 'pars= ed' into individual fields.

The companio= n client libraries of the Ledger Bitcoin app support both versions, and Psb= tV0 is converted to PsbtV2 on the fly.
Broader support would cert= ainly be useful.

Best,
Salvatore Ingala<= /div>

<= /div>

--
You received this message because you are subscribed to the Google Groups &= quot;Bitcoin Development Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to bitcoindev+unsubscribe@googlegroups.com.
To view this discussion visit ht= tps://groups.google.com/d/msgid/bitcoindev/CAMhCMoGONKFok_SuZkic%2BT%3DyoWZ= s5eeVxtwJL6Ei%3DyysvA8rrg%40mail.gmail.com.

--
You received this message because you are subscribed to the Google Groups &= quot;Bitcoin Development Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to bitcoind= ev+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/ms= gid/bitcoindev/CAMhCMoGArSJ1_x2yhqUuedVpBZt1iPwioujJCH2eLVPEy9_QNA%40mail.g= mail.com.
--000000000000ce8178062be687d4--