diff --git a/20.md b/20.md index d612181..7f59a98 100644 --- a/20.md +++ b/20.md @@ -9,6 +9,7 @@ This NUT defines signature-based authentication for mint quote redemption. When requesting a mint quote, clients provide a public key. The mint will then require a valid signature from the corresponding secret key to process the mint operation. > [!CAUTION] +> > [NUT-04][04] mint quotes without a public key can be minted by anyone who knows the mint quote id without providing a signature. ## Mint quote @@ -34,7 +35,8 @@ with the requested `amount`,`unit`, and `description` according to [NUT-04][04]. `pubkey` is the public key that will be required for signature verification during the minting operation. The mint will only mint ecash after receiving a valid signature from the corresponding private key in the subsequent `PostMintRequest`. -> [!IMPORTANT] +> [!IMPORTANT] +> > **Privacy:** To prevent the mint from being able to link multiple mint quotes, wallets **SHOULD** generate a unique public key for each mint quote request. The mint `Bob` then responds with a `PostMintQuoteBolt11Response`: @@ -78,6 +80,7 @@ Response of `Bob`: To provide a signature for a mint request, the owner of the signing public keys must concatenate the quote ID `quote` in `PostMintQuoteBolt11Response` and the `B_` fields of all `BlindedMessages` in the `PostMintBolt11Request` (i.e., the outputs, see [NUT-00][00]) to a single message string in the order they appear in the `PostMintRequest`. This concatenated string is then hashed and signed (see [Signature scheme](#signature-scheme)). > [!NOTE] +> > Concatenating the quote ID and the outputs into a single message prevents maliciously replacing the outputs. If a request has `n` outputs, the message to sign becomes: