Privacy Protection Method for Blockchain Transactions Based on the Stealth Address and the Note Mechanism

: Blockchain is a distributed ledger technology that possesses characteristics such as decentralization, tamper resistance


Introduction
Blockchain technology, as a distributed ledger, has distinct features and advantages, such as distributed, tamper-proof, and traceable transactions, compared to centralized systems [1].With the continuous development of blockchain technology, it has been applied to solve the problems of low security, poor reliability, low efficiency, and high cost of the current centralized transaction model [2].Blockchain technology is expected to reshape the shape of society and bring profound reforms in the fields of technology, finance, politics, and culture [3].
However, with the widespread adoption and development of blockchain technology, there is an increasing variety of attack methods targeting blockchain.Blockchain faces numerous technical challenges in terms of security and privacy protection.In traditional centralized transaction systems, the identities of transaction participants and transaction details are typically protected.However, on a blockchain, all transaction records are publicly stored, and attackers can access users' transaction data, network addresses, and other information [4].Some attacks involve clustering user behavior to analyze their anonymous Appl.Sci.2024, 14, 1642 2 of 24 identities, including a heuristic model learning of transaction behavior [5,6], IP address clustering [7], address clustering of transaction data [8], and so on, posing significant threats to the privacy protection of current blockchain transactions.The leakage of transaction privacy can expose sensitive information, such as the identities of participants, transaction amounts, and relationships, leading to various potential issues, including financial fraud, personal information disclosure, and disclosure of business secrets.Therefore, protecting the privacy of blockchain transactions has become a key challenge in current research and practice.
Regarding the issue of protecting transaction privacy in blockchain, there have been several relevant studies [9][10][11], mainly focusing on two approaches: direct privacy protection and indirect privacy protection.Indirect privacy protection methods employ indirect means to protect transaction privacy, mainly through techniques such as coin mixing [12], ring signature [13], and stealth address [14].Direct privacy protection methods directly hide transaction information and are mainly based on zero-knowledge proof.However, current blockchain transaction privacy protection schemes are not yet fully mature, and they have certain limitations in terms of efficiency, security, and privacy.These issues need to be addressed, especially in scenarios such as data trading that require a balance between privacy and service performance.
Blockchain not only ensures open and transparent transactions but also brings the risk of privacy leakage.Attackers can infer the true identity of blockchain users with a high success rate through clustering analysis and other methods.At present, some mainstream privacy protection methods also have many problems.For example, in the stealth address scheme, transactions need to be accompanied by the temporary public key, resulting in the loss of certain privacy information.In addition, the recipient needs to continuously scan block data and repeatedly perform complex calculations, which is inefficient and requires high computing resources; in the ZCash privacy trading system, a note-based privacy trading scheme is adopted, which uses zk-SNARKs to prove relevant legitimacy and ownership, requiring a series of complex calculations, which is very unfriendly to controlling transaction costs.In addition, zk-SNARKs require additional trusted third parties for trusted settings, and the existence of nonprivate transactions also leads to the loss of certain privacy.How to address the shortcomings of the above solutions and effectively integrate their advantages is an important research question and challenge faced in this article.
In response to the challenges and difficulties of protecting transaction privacy in blockchain, this article aims to contribute to the privacy and security of blockchain transactions and presents the blockchain transaction privacy protection scheme BTPP (Blockchain Transaction Privacy Protection), which is based on the note mechanism in Zcash and the DKSAP protocol.In response to the temporary public key exposure problem of the former, the BTPP protocol extracts the shared knowledge of both parties as a random seed, enhancing the privacy of transactions.In response to the complex proving process and dependence on third parties in the note mechanism, the BTPP protocol uses the Note Commitments table to maintain the binding relationship between temporary addresses and corresponding notes, achieving efficient transfer and verification of note ownership.Through the Nullifier table, the uniqueness of the temporary address is used as the invalidation identifier for the note, achieving efficient verification of the correctness of note invalidation identifiers and eliminating dependence on third parties.Through these improvements, the BTPP protocol ensures transaction performance while protecting the privacy of transactions.The BTPP method consists of three stages: note construction, generation of amount Pedersen commitments and range proofs, and verification of transaction legality.It leverages these stages to generate relevant proofs of transaction legality off-chain and completes the relevant verification of transaction legality on-chain, thus confirming the transaction.This approach ensures the protection of critical information, such as the transaction relationship and amount for both parties, guaranteeing the privacy of transactions.The BTPP method achieves fully decentralized blockchain transactions while ensuring privacy and performance.

Related Works
With the continuous development and application of blockchain technology, many scholars have begun to explore and develop various privacy protection mechanisms and technologies.The goal of privacy protection is to effectively safeguard the privacy of transaction participants while ensuring the security and trustworthiness of the blockchain, enabling anonymous blockchain transactions.Currently, research on blockchain transaction privacy protection primarily focuses on indirect and direct methods.

Indirect Privacy Protection
Indirect privacy protection methods employ an indirect approach to safeguarding transaction privacy information.These methods mainly rely on techniques such as obfuscation or temporary generation.Common technological solutions include coin mixing, stealth addresses, and ring signatures.

Coin mixing technology
Mixing technology achieves privacy by disrupting the correspondence between the addresses of the transacting parties, ensuring transaction unlinkability.In centralized approaches, an additional third party serves as a mixer, disrupting the relationship between the currency and the transactors during the mixing service.Malicious entities find it difficult to obtain critical transaction information.However, this approach relies on a third party, requires payment for the mixing service, and carries the risk of token theft.A decentralized approach, Coinjoin [15], was introduced to address these issues.It eliminates the need for an anonymous third-party intermediary.The coordinator of the mixing service combines multiple transactions, severing the relationship between the transactions and the transacting parties to blur the linkability of the transactions.However, this approach introduces new challenges.It is difficult to ensure that all participants in the mixing process are honest users, and it cannot eliminate the risk of Sybil attacks or guarantee internal unlinkability.To tackle these limitations, a new decentralized mixing scheme called CoinShuffle [16] was proposed.Users shuffle the transaction relationships using a shuffling protocol, and their address information is protected to ensure the security of the mixing transactions.However, users need to be online throughout the mixing process.Addressing this drawback, the CoinParty scheme [17] was introduced.Unlike CoinShuffle, it does not require users to be online throughout the process.Instead, participating users only need to send encrypted output addresses and corresponding funds to the mixing group before the mixing service begins.
Decentralized mixing technologies have improved privacy and convenience, but they still have some limitations, such as susceptibility to DoS attacks and relatively low mixing efficiency.Currently, they are not able to provide fully mature privacy protection.

Ring signature technology
Ring signature is a simplified form of group signature where the core idea is that users (members of the ring set) can utilize a "ring" signature that represents the members of the ring [18,19], but it cannot be attributed to any specific signer.The ring set is a collection without any central authority, providing features such as non-repudiation, privacy, and traceability, significantly enhancing the privacy of blockchain transactions.
CryptoNote [20] is one of the most prominent protocols based on ring signature technology.It utilizes linkable ring signatures to conceal the sender's address in transactions.Monero [21], a cryptocurrency, is built upon this key technology.Monero implements ring confidential transactions (RingCT), which leverage homomorphic commitments and ring signatures to achieve range proofs, thereby hiding transaction amounts while ensuring public verifiability.
Due to its anonymity and anti-counterfeiting properties, ring signature technology has been widely applied in fields such as intellectual property protection and anonymous voting.However, ring signature privacy protection schemes also face security threats.Research studies [4, 22,23] have demonstrated privacy vulnerabilities in ring signature technology.In such schemes, the length of signatures increases as more members join, and there are also issues related to malicious repudiation of signatures by signers and vulnerability to key selection attacks.

Stealth address
The stealth address technology primarily aims to hide transaction addresses and provide privacy protection for the recipients [24].The sender computes a temporary address before the transaction, and the payment tokens are sent to that address.The true recipient can confirm the transaction's validity using the corresponding keys, thereby obfuscating the association between the transacting parties.
Many research efforts have focused on improving stealth address schemes.Fan et al. [25] proposed a scheme that reduces the storage cost for users by only requiring them to store a key pair during initialization.In the original protocol, the recipient needs to continuously scan transaction data and compute the target address, which poses limitations in resource-constrained environments like the Internet of Things (IoT).To address this, Fan et al. [26] introduced DKSAP-IoT, a double-key stealth address protocol based on blockchain, which achieves faster communication between parties and reduces the size of transactions.
Although stealth address schemes have their merits, they are not without flaws.Each anonymous transaction requires the inclusion of a transaction's temporary public key, making the privacy of such transactions susceptible to identification, resulting in the loss of certain private information.Additionally, there are efficiency issues, such as the need for the recipient to repeatedly perform elliptic curve scalar multiplication operations.These challenges need to be addressed, especially in scenarios like data transactions that prioritize both privacy and service performance.

Direct Privacy Protection
The direct privacy protection approach aims to directly hide crucial transaction information and is primarily based on zero-knowledge proof technology.The critical aspect of this approach is that when the prover proves the correctness of a message to the verifier, they do not need to disclose specific content.As a result, the verifier cannot obtain any unnecessary information, thereby achieving the goal of protecting transaction privacy.
Zcash, proposed by Ben-Sasson et al. [27], is a typical example of applying the noninteractive zero-knowledge proof.When proving the validity of transactions, Zcash does not reveal any private information to the relevant verifiers, thus ensuring strong privacy.Although Zcash achieves good anonymity, the generation of initialized parameters requires the participation of trusted parties, making it inherently weakly centralized.Furthermore, the efficiency and throughput of proof generation in Zcash are not ideal.To address these issues, Benedikt et al. [28] designed the Bulletproof protocol, which uses short proof and does not rely on the trusted setup.It effectively improves the speed of proof generation through secure multiparty computation.Li et al. [29] applied the Bulletproof protocol to data privacy protection in energy trading scenarios.They used the Bulletproof protocol to provide range proofs for transaction amounts, hiding the specific transaction amounts.Additionally, to address the issue of the authenticity of auditing receipts, they combined zero-knowledge proof and the ElGamal encryption technique, enabling regulators to reliably monitor transaction privacy data without revealing commitments.As the number of network nodes increases, the data volume corresponding to computing proofs in the Bulletproof protocol also increases, implying a higher cost of storing this data in the blockchain and posing new challenges.

Comparison of Privacy Protection Methods
In the realm of blockchain transaction privacy protection, each privacy protection mechanism exhibits unique advantages and limitations in terms of privacy preservation and processing efficiency.
Coin mixing technology, by amalgamating transactions from multiple users, complicates the tracing of transaction origins.However, this method may decrease system efficiency, particularly when processing a large volume of transactions.The stealth address scheme generates the unique address for each transaction, offering a higher degree of privacy protection, and is relatively more efficient, especially in comparison to coin mixing.However, the key to stealth address schemes is that they can only conceal the identity of the receiver while exposing other aspects of the transaction (such as the sender's identity and amount).The ring signature technology, by obscuring the true sender within a group of users, provides robust anonymity for the sender but may incur increased complexity in the verification process and a reduction in system efficiency.In contrast, direct privacy protection schemes such as zero-knowledge proof technology provide the highest level of privacy protection, which enables the validation of transactions' legitimacy without disclosing any specific details.However, this elevated level of privacy protection is often accompanied by heightened computational complexity and reduced transaction processing efficiency.
In summary, selecting an appropriate privacy protection mechanism necessitates finding a balance between privacy and efficiency.While the coin mixing scheme and the stealth address scheme provide effective privacy protection to a certain extent, each has its limitations.The ring signature scheme and the zero-knowledge proof approach offer a deeper level of anonymity but may come at the cost of reduced processing efficiency.Therefore, in practical applications, it is crucial to choose the most suitable privacy protection strategy based on the specific context and requirements.

Proposed Method
In order to clearly demonstrate the method proposed in this article, this section will be divided into the following subsections: Section 3.1 (Question Quotation) mainly explains what problems the method designed in this article aims to solve and what challenges exist.Section 3.2 (Design Principle) mainly explains some of the ideas this article considers when designing solutions for these problems and challenges-that is, how some key technologies of the entire solution are designed.Section 3.3 (Framework Design) mainly describes the scheme proposed in this article from a framework perspective, clarifying the design of the technical framework of the entire method and the participants.Section 3.4 (Process Design) elaborates on the specific implementation process and technical details of the proposed method.

Question Quotation
The public and transparent nature of blockchain brings transparency to transactions, but it also introduces the risk of transaction privacy information leakage.Although users conduct transactions on the blockchain under anonymous identities, once the transaction behavior is linked to a real identity, attackers can infer the real identities of blockchain users with a high success rate using methods like clustering analysis, leading to privacy breaches.
The UTXO-based note mechanism scheme in Zcash uses zk-SNARKs to generate relevant proofs, which involves circuit encoding for proofs.This approach has slow execution speed, high transaction fees, and requires a complex trusted setup.Additionally, not all transactions in Zcash are automatically private, leading to the risk of privacy information leakage.In the DKSAP protocol, temporary addresses are generated for each transaction to hide the receiver's real address, but the transaction still needs to include the temporary public key R, resulting in the loss of certain privacy information.Moreover, the receiver needs to continuously scan the blockchain's transaction data and perform elliptic curve scalar multiplications to verify if they are the authorized recipient of the transaction.Both of these schemes have issues in terms of performance and transaction privacy security, especially in high-performance transaction service scenarios.To address these issues, this paper improves upon the drawbacks of both schemes and combines their advantages to propose the Blockchain Transaction Privacy Protection (BTPP) method for protecting transaction privacy in blockchain.

Design Principle
The BTPP method aims to protect transaction privacy in blockchain, which is based on the stealth address and the note mechanism.In the BTPP method, a stealth address is embedded in the note as the temporary address of the recipient.The uniqueness of the stealth address is used to identify the note, ensuring that even if the note content is leaked, the specific recipient information cannot be inferred.In the calculation of the stealth address, the BTPP method utilizes the randomness seed for generating the temporary private key r based on the Diffie-Hellman key exchange protocol.This approach avoids the issue of exposing the temporary public key in the transaction.Both parties involved in the transaction can independently compute their corresponding temporary addresses, allowing the recipient to determine if they are the intended real recipient.
In the maintenance of the world state of the note, the Note Commitments table maintains the mapping between the note and its corresponding stealth address.The Nullifier table utilizes the uniqueness of the stealth address to serve as the invalidation identifier for the note.By leveraging the binding relationship between the note and its stealth address, the ownership of the note is transferred to the ownership of the confirmation key t corresponding to the stealth address of the note.Only the genuine recipient can compute the confirmation key t, enabling efficient transfer, proof, and verification of note ownership.The Nullifier table uses the stealth address associated with the note as its invalidation identifier, and when verifying the correctness of the invalidation identifier for a note, it only needs to validate the binding relationship between the stealth address and the note, achieving efficient verification of the invalidation identifier for the note.

Framework Design
The framework of the BTPP method is illustrated in Figure 1 and involves the following roles:

•
Transaction Sender (Bob): Bob is responsible for constructing the output notes, generating Pedersen commitments and Bulletproofs range proofs for the relevant amounts, proving ownership of input notes, and transferring ownership of the output notes to the recipient.• Transaction Recipient (Alice): Alice is responsible for generating Pedersen commitments and Bulletproofs range proofs for the relevant amounts, verifying the correctness and ownership of the payment note received, and receiving payment notes representing the income.

•
Smart Contract: In the BTPP method, the smart contract acts as the executor of the transaction and is responsible for carrying out the necessary verification and transaction logic to ensure fair transactions between the parties.

•
Blockchain: The blockchain, maintained by relevant nodes, is responsible for maintaining the world state of the notes, verifying the validity of transactions, achieving consensus, and providing a secure execution environment for smart contracts.The BTPP method comprises a set of polynomial-time algorithms, including GSetup, UserKeyGen, NoteSRCH, Random, NoteCreate, Commit, Open, RangeProve, RangeVerify, OVerify, NfVerify, and TVerify.These algorithms are formally defined as follows: 1.
pp ← GSetup 1 λ : Public parameter generation: Given the security parameter λ as input, the algorithm outputs the public parameters pp. 2.
(pk u , sk u ) ← UserKeyGen(pp, pk ca , ID u ) : User key pair generation: Given the public parameters pp, the main key pk ca of the CA, and the user identifier ID u as input, the algorithm outputs the user's asymmetric key pair (pk u , sk u ); 3.
note in ← NoteSRCH(v, note u ) : Search for eligible input notes: Given the user's list of notes and the transaction amount v as input, the algorithm searches for notes that exactly match the value v.If there is a note with a value equal to v, it is outputted.Otherwise, if there are multiple notes whose combined value is greater than or equal to v, they are outputted.4.
r ← Random(seed) : Random number generation: The Random function takes a random seed as input and generates a random number r.The random number r is generated differently for different random seeds.The Random function is primarily used when calculating stealth addresses to generate consistent temporary publicprivate key pairs based on shared knowledge between the transaction parties.5.
note out ← NoteCreate(v, r, S, B) : Construction of transaction output note.The input includes the note value v, the transaction temporary private key r, the recipient's scan public key S, and the spend public key B. The output is the transaction's corresponding output note note out .6.
C ← Commit(x, r) : Pedersen commitment generation.The input consists of the target value x to be bound and hidden in the commitment and the random blinding factor r.
The output is the commitment C that binds x while revealing no information about x. 7.
1/0 ← Open(C, x, r) : Validity verification of Pedersen commitment.The input consists of the commitment C that binds the target value x, the target value x that is bound and hidden in the commitment, and the blinding factor r. The output indicates whether the commitment C is indeed bound to the claimed value x.

8.
π ← RangeProve(x, r, C) : Generation of range proof based on Bulletproofs.The input consists of the value x, the Pedersen commitment C to x, and the blinding factor r used for verifying whether a hidden integer in a Pedersen commitment is equal to a given value.The output is a proof π that demonstrates that the value x is within a specified range, specifically proving that x is non-negative.9.
1/0 ← RangeVeri f y(π, C) : Verification of the correctness of a range proof based on Bulletproofs.The input consists of the range proof π and the corresponding Pedersen commitment C. If π matches C and the hidden value in commitment C is a non-negative integer, the verification passes.Otherwise, the verification fails.10. 1/0 ← OVeri f y(t, T) : Ownership verification of a note.The input consists of the stealth address T and its corresponding address confirmation key t.The OVerify algorithm determines whether the confirmation key t can successfully confirm the stealth address T. The output indicates whether the owner of the confirmation key t has ownership of the note bound to the stealth address T. 11. 1/0 ← N f Veri f y(nulli f ier, T) : Note validity verification.The NfVerify algorithm is primarily responsible for verifying whether the input note has a "double spend" issue.It takes the Nullifier table, which contains nullifiers of invalidated notes in the current note world state, and the nullifier T corresponding to the note, as input.The NfVerify algorithm checks whether T exists in the Nullifier table.The output indicates whether the note bound to the stealth address T has been double-spent.12. 1/0 ← TVeri f y C p , C q , r p , r q : Transaction input-output balance verification.The TVerify algorithm is primarily responsible for verifying whether the transaction input and output amounts are balanced, meaning that the sum of input amounts equals the sum of output amounts.The algorithm takes the sender's commitment C p to the amounts and chosen blinding factors r p , as well as the receiver's commitment C q to the amounts and chosen blinding factors r q , as input.The output indicates whether the transaction inputs and outputs are balanced.

Process Design
BTPP consists of three stages: the construction of output notes, the generation of transaction amount commitments and range proofs, and the verification of transaction legality.The processes for each stage are shown in Figure 2. The following text provides a detailed description of each stage's specific procedures.The meanings of the symbols used are listed in Table 1.
whether the note bound to the stealth address T has been double-spent.15. 1/0 ← ( ,  ,  ,  ) : Transaction input-output balance verification.The TVerify algorithm is primarily responsible for verifying whether the transaction input and output amounts are balanced, meaning that the sum of input amounts equals the sum of output amounts.The algorithm takes the sender's commitment  to the amounts and chosen blinding factors  , as well as the receiver's commitment  to the amounts and chosen blinding factors  , as input.The output indicates whether the transaction inputs and outputs are balanced.

Process Design
BTPP consists of three stages: the construction of output notes, the generation of transaction amount commitments and range proofs, and the verification of transaction legality.The processes for each stage are shown in Figure 2. The following text provides a detailed description of each stage's specific procedures.The meanings of the symbols used are listed in Table 1.

Symbol Meaning (sa, Sa)
The scan key pair of the recipient (sb, Sb) The scan key pair of the sender (ba, Ba) The spend key pair of the recipient (bb, Bb) The spend key pair of the sender notei The i-th note Ti The corresponding stealth address of the note notei ti The confirmation key corresponding to the stealth address Ti

Symbol Meaning
(s a , S a ) The scan key pair of the recipient (s b , S b ) The scan key pair of the sender (b a , B a ) The spend key pair of the recipient (b b , B b ) The spend key pair of the sender note i The i-th note T i The corresponding stealth address of the note note i t i The confirmation key corresponding to the stealth address T i The temporary public-private key pair for the transaction corresponding to the note note i v i The value corresponding to the note note i c i The transaction shared key corresponding to the note note i C i Pedersen commitment to the amount v i π i Range proof for the amount v i h i The hash value corresponding to the note note i

The Initialization Phase
Initialization is primarily performed by the CA, which accepts the security parameter λ.Let G 1 and G 2 be the additive cyclic group and the multiplicative cyclic group, G be the elliptic curve group, G be the generating element of the group G, H ∈ G, and the discrete logarithm of H is unknown.Choose two different generating elements P and q from G 1 and G 2 , respectively, and choose the bilinear mapping e : q and H 2 : {0, 1} * × G 2 → Z * q , and randomly choose s ∈ Z * q as the private key sk ca of the CA, and the public key pk ca = sP, sP → G 1 .Finally, the common parameter pp of the system is obtained : where pp = (λ, G 1 , G 2 , e, P, q, pk ca , H 1 , H 2 ).The system defines two large prime numbers p and a, where p is a prime number, and a is a primitive root modulo p.The transaction user provides unique identifier ID to the CA, and the CA generates the corresponding user key pair (pk, sk) using the key generation algorithm UserKenGen: Suppose the public-private key pair of the transaction sender is (pk b , sk b ), the public- private key pair of the transaction receiver is (pk a , sk a ), and each transaction participant user publishes its public key pk.
The transaction user generates the dual key pairs, i.e., the scan key pair is (s, S) and the spend key pair (b, B), where S = s•G, B = b•G.Assume that the dual key pairs for the transaction sender are (s b , S b ) and (b b , B b ), and the dual key pairs for the transaction receiver are (s a , S a ) and (b a , B a ).

The Construction Phase of the Output Note
Suppose the transaction sender Bob's note list is note b = [note 1 , note 2 , note 3 ], where , and the amount of the transaction is v = 9.The interaction flow of each participant is shown in Figure 3, and the detailed process is described below.1.
The transaction sender Bob finds the notes that meet the transfer criteria If Bob's note list happens to have note with v = 9, then the number of input and output notes is 1 each; otherwise, Bob needs to make a combined payment.This process corresponds to step 1 in Figure 2. The process is as follows: (1) Bob finds one or more of notes that have not yet been spent, i.e., note 1 , note 2 and note 3 ; (2) Bob decrypts the notes by the private key sk b to obtain the values and other information; (3) Bob finds the notes that matche the transfer amount v as the input notes for this transaction, i.e., note in = [note 1 , note 2 ], satisfying v in = v 1 + v 2 ≥ v, and the whole process is shown as Equation (3): The transaction sender Bob constructs the output note This process corresponds to step 2 in Figure 2. When the total value v in of the input notes note in exceeds the amount v, Bob needs to generate payment note note 4 and change note note 5 with values v 4 = 9 and v 5 = v in − v 4 = 2, respectively, with the following construction process: (1) Bob obtains the scan public key S a and the spend public key B a of Alice; (2) Bob chooses a random integer k 1 , i.e., 0 < k 1 < p − 1, and computes and sends the public key Pub b : (3) Alice chooses a random integer k 2 , i.e., 0 < k 2 < p − 1, and computes and sends the public key pub a : (4) Bob receives the public key pub a calculated by Alice and uses the private key k 1 to calculate the shared key K 1 : (5) Alice receives the public key pub b computed by Bob and uses the private key k 2 to compute the shared key K 2 : (6) Both sides of the transaction have the same shared key, i.e., K 1 = K 2 , only both sides of the transaction know the shared key, and both sides use the shared key to compute the randomness seed: where Hash(•) is the secure hash function.(7) Bob calculates the temporary public-private key pair (r 4 , R 4 ) for the payment note note 4 transaction based on seed: In order to achieve concealment of the transaction amount, both parties to the transaction calculate the Pedersen commitments for the relevant amounts separately and generate the range proofs for the corresponding amounts based on Bulletproofs.This process corresponds to steps 3, 4, and 5 in Figure 2, the specific process of which is described below.

1.
The transaction sender generates the commitments and range proofs for the relevant amounts (1) The transaction sender Bob selects random numbers r b 1 , r b 2 , and r b 5 as blind factors and generates commitments C 1 , C 2 , and C 5 for input amounts v 1 , v 2 , and change amount v 5 , respectively: (2) Bob generates the range proof π 5 for the change amount v 5 based on Bulletproofs: (3) Bob sends the commitments C 5 ] and the blind factor r b to the transaction receiver Alice, where The transaction receiver generates the commitments and range proofs for the relevant amounts (1) After receiving the commitments from Bob, Alice first verifies the correctness of the commitments: where C 1 + C 2 is Bob's commitment to the input of the transaction; C 5 is Bob's commitment to the change amount; and r b •G + v 4 •H is Bob's commitment to transfer the amount to Alice, i.e., to verify that the input and output of the transaction are balanced: (2) Alice chooses the random number r a , generates the Pedersen commitment C 4 for the payment amount v 4 , and computes K: (3) Alice generates the range proof π 4 of payment amount v 4 based on Bulletproofs: RangeProve(v 4 , r a , C 4 ) = π 4 (16)

Verification Stage of Transaction Legitimacy
In order to describe the change of the note world state before and after the transaction, assume that the current note world state is shown in Table 2.The Note Commitments table in the BTPP method maintains the mapping relationship between the hash of note and its stealth address, while the Nullifier table maintains the stealth address of the invalid note.The verification of transaction legitimacy includes the ownership and legitimacy verification of the input notes, the legitimacy verification of the transaction amount, and the correctness verification of the payment note.The entire process corresponds to steps 6 to 11 in Figure 2, the specific process of which is described below.

Note Commitments Nullifier Set
(h 1 = Hash(note Verify the sender's ownership of the input notes (1) The sender Bob sends to the verification network the hash h in = [h 1 , h 2 ] of the input note note in , the corresponding confirmation key t in = [t 1 , t 2 ], and the hash h out = [h 4 , h 5 ] of the output notes note 4 , note 5 ; (2) The verification nodes calculate the corresponding stealth addresses

Verify the legality of the input notes
The legitimacy verification of input notes is to detect whether there is a "double spend" problem with the input notes.Since the Note Commitments table maintains the binding relationship between the notes and their stealth addresses, while the Nullifier table maintains the stealth addresses of the invalid notes, the legitimacy of the input notes can be verified by determining whether the stealth addresses T 1 and T 2 bound to the input notes note 1 and note 2 exist in the Nullifier table, as shown in Equation (18): 3.
Verify the legality of the transaction amounts (1) Bob publishes the commitments C b = [C 1 , C 2 , C 5 ] and the range proof π 5 to the verification network; (2) Alice publishes the commitment C a = [C 4 ], K and range proof π 4 to the verification network; (3) The verification nodes verify the balance of the transaction input-output amounts, as shown in Equation ( 19): (4) The verification nodes verify that the transaction output amounts are non-negative, as shown in Equation ( 20): 4.
The recipient verifies the correctness of the payment note (1) Bob encrypts note 4 using Alice's public key pk a to generate note enc 4 and sends it to Alice; (2) Alice decrypts note enc 4 using the private key sk a to obtain the payment note note 4 and verifies ownership of note 4 and the specific information of the note, completing the verification of the correctness of note 4 : (3) Alice calculates the hash value h 4 ′ = Hash(note 4 ) of the payment note note 4 and publishes h 4 ′ to the verification network; (4) The verification nodes verify the correctness of the commit value of the note, i.e., verifies that h 4 is equal to h 4 ′ .

5.
Update the world state of the note Each verification node updates the Note Commitments table to record the binding relationship between the hash values h out = [h 4 , h 5 ] of output notes (note 4 , note 5 ) and the corresponding stealth addresses T 4 and T 5 , indicating the output of this transaction, and updates the Nullifier table to record the invalid identifiers T 1 and T 2 of input notes (note 1 , note 2 ), indicating the input of this transaction.
The entire process of this transaction is now complete.The world state of the note after the transaction is completed is shown in Table 3.
Table 3.The world state of the note after the transaction.

Note Commitments
Nullifier Set

Performance Analysis
The security of the BTPP scheme is based on cryptographic techniques, including the discrete logarithm assumption, secure hash functions, and public-key cryptography.This section will analyze the BTPP scheme from the perspectives of security and privacy.

Transaction Information Privacy Analysis
The BTPP scheme ensures the privacy of transaction information, including the transaction relationship and transaction amount of the parties involved.Apart from the transaction participants, no one, including the transaction verification party, can know the specific details of the transaction.
In terms of transaction relationship, the sender uses the recipient's dual public key information to generate the stealth address T for the transaction.This address is bound to the corresponding note as the recipient's temporary address, effectively hiding the recipient's actual address.Only the corresponding recipient possesses the confirmation key for the stealth address, which proves their ownership of the note.This process severs the transaction relationship between the trading parties, achieving unlinkability of the transaction relationship.
In terms of transaction amounts, the BTPP scheme employs commitments for amounts.For example, the commitment form of an amount v, where r is a random blinding factor chosen by the proving party, relies on the elliptic curve discrete logarithm problem, making it difficult for an attacker to compute the amount v, even if they obtain r.This ensures the protection of the transaction amount.The Pedersen commitment for the amount hides the transaction amount while completing the verification of transaction legality.

Security of Ownership Verification of Notes
In the BTPP scheme, the transaction parties utilize the Diffie-Hellman key exchange protocol to compute the shared secret keys k 1 and k 2 based on their respective knowledge.Using this shared secret key, they calculate the stealth address T for the payment note.However, only the authorized recipient possesses the confirmation key t = c + b, where b represents the spend private key known only to the recipient, and c represents the transaction shared secret key known only to the transaction parties.As a result, only the legitimate recipient can prove ownership of the note by computing T = t•G.Therefore, the BTPP scheme ensures that only the true recipient of the transaction can provide proof of ownership for the note.

Security of Legitimacy Verification of Notes
The BTPP scheme has updated the maintenance of the Note Commitments table and the Nullfier table.It utilizes the uniqueness of the stealth address as the invalid identifier for note and binds the stealth address to the corresponding note.When verifying the legitimacy of an input note, it is only necessary to check the correctness of its invalid identifier, which is the stealth address, by verifying whether there is a binding relationship between the invalid identifier and the input note.No one can tamper with the data on the blockchain.Therefore, the BTPP scheme ensures the security of validating the legitimacy of input notes and prevents "double spend" issues.

Security of the Stealth Address
For the calculation of the stealth address T = c•G + B = Hash(r•S)•G + B, where S, B, and G are public information, but for the temporary private key r = Random(seed) of the transaction, the randomness seed of its calculation comes from the common knowledge known only to the two parties of the transaction, and only the two parties of the transaction know the temporary private key r to calculate the same stealth address T r , and only the corresponding recipient has the confirmation key t for the stealth address and can prove ownership of it.

Security of Legitimacy Verification of the Relevant Transaction Amounts
The BTPP scheme achieves concealment of the transaction amounts via the Pedersen commitments and range proofs based on Bulletproofs.Taking the previously described transaction as an example, for the sender's commitments C b = [C 1 , C 2 , C 5 ] for the amounts and the blind factor r b = r b 1 + r b 2 − r b 5 , the receiver verifies the correctness of the payment amount based on Equation ( 14), i.e., v 1 + v 2 = v 4 + v 5 , and only the sender's correctly generated commitments to the input amounts and the change amount can pass the receiver's verification of the payment amount.Meanwhile, for the sender's C b and the receiver's C a and K, the verification nodes verify the balance of transaction inputs and outputs as follows: Only when both transaction parties correctly generate commitments to the relevant amounts can the verification notes verify the balance of input and output amounts of the transaction.Additionally, the range proofs provided by both parties for the output amounts ensure that the output amounts are not negative.Therefore, the BTPP scheme can securely verify the legality of transaction amounts.

Integrity of Blockchain Transaction
The stealth address protects the recipient's identity by generating the temporary address for each transaction, meaning outside observers cannot trace the recipient's identity or transaction history through the address.Although the BTPP protocol uses the temporary address, the integrity of the transaction is still verified through the public ledger of the blockchain, ensuring the non-tamperability and integrity of the transaction.In addition, the BTPP protocol utilizes the Pedersen commitment combined with the Bulletproofs range proof to ensure the legitimacy of the transaction amount without revealing any specific information.Although the transaction amount is hidden, through the generated commitments and range proofs, network participants (such as miners or validators) can still verify the validity of the transaction.This means that the transaction still follows the basic rules of the blockchain, such as not exceeding the account balance and maintaining the integrity of the transaction.At the same time, through the note mechanism, the blockchain network can perform necessary compliance and integrity checks, such as preventing doublespending, without revealing the privacy details of the transaction.

Experiment Environment
The experiments in this section are all implemented by VMware, a virtual machine with 4 GB of memory, based on the Javascript language, using the secp256k1 curve y 2 = x 3 + 7 provided by the noble-secp256k1 library; utlizing the libsecp256k1 library and the elliptic library to implement the related scalar operations, modulo, power and other operations on the elliptic curve secp256k1; and providing the source of randomness based on the bigint-crypto-utils library.The experimental hardware environment configuration is shown in Table 4.

Experiment Purpose
The experimental design is based on the key processes involved in the proposed BTPP scheme, including specific implementation details such as the construction of the transaction output note, the generation of the Pedersen commitments and range proofs, and the legitimacy verification of the transaction so as to verify and evaluate the efficiency and feasibility of the BTPP scheme, and the experimental purposes can be divided into the following points: • To verify the correctness of the BTPP scheme.One of the purposes is to verify the feasibility and correctness of the key steps of the BTPP scheme and thus verify that the BTPP scheme is correct.• To test the efficiency improvements brought by the relevant designs in the BTPP scheme and verify its efficiency and feasibility.The BTPP scheme is able to achieve efficient note ownership transfer and verification operations by improving the generation of stealth addresses and the note mechanism.One of the purposes is to verify the efficiency of the relevant operations, thus verifying the efficiency and feasibility of the BTPP scheme.

Initialization of the receiver's dual key pair
The receiver Alice initializes the dual key pair, i.e., the scan key pair (s, S) and the spend key pair (b, B), where the information of the generation element G and the associated key pair parameters are shown in Figure 4.

Construction of the output notes
The sender Bob needs to construct the payment note by first calculating the stealth address T for this transaction, which is shown in Figure 5, including the calculation of the randomness seed, the temporary key pair (r, R), and the shared key c.Taking the above transaction as an example, the information of the final payment note is shown in Figure 5.

Construction of the output notes
The sender Bob needs to construct the payment note by first calculating the stealth address T for this transaction, which is shown in Figure 5, including the calculation of the randomness seed, the temporary key pair (r, R), and the shared key c.Taking the above transaction as an example, the information of the final payment note is shown in Figure 5.After testing, the time consumed for initialization of dual public key pairs, calculation of stealth address and construction of output note for transaction users are 133.096ms, 9.779 ms and 12.162 ms respectively, all in milliseconds.

Generation of Pedersen Commitments and Range Proofs
Taking the previously described transaction as an example, in order to achieve the hiding of the transaction amount, both parties of the transaction generate the Pedersen commitments for the relevant amounts and the range proofs for the output amounts based on Bulletproofs, respectively.The specific process is as follows.

Parameter initialization
The initialization information for generating elements G, H, and the reasonable range of amounts [2 , 2 ] is shown in Figure 6.After testing, the time consumed for initialization of dual public key pairs, calculation of stealth address and construction of output note for transaction users are 133.096ms, 9.779 ms and 12.162 ms respectively, all in milliseconds.

Generation of Pedersen Commitments and Range Proofs
Taking the previously described transaction as an example, in order to achieve the hiding of the transaction amount, both parties of the transaction generate the Pedersen commitments for the relevant amounts and the range proofs for the output amounts based on Bulletproofs, respectively.The specific process is as follows.

Parameter initialization
The initialization information for generating elements G, H, and the reasonable range of amounts [2 lower , 2 upper ] is shown in Figure 6.The sender Bob needs to construct the payment note by first calculating the stealth address T for this transaction, which is shown in Figure 5, including the calculation of the randomness seed, the temporary key pair (r, R), and the shared key c.Taking the above transaction as an example, the information of the final payment note is shown in Figure 5.After testing, the time consumed for initialization of dual public key pairs, calculation of stealth address and construction of output note for transaction users are 133.096ms, 9.779 ms and 12.162 ms respectively, all in milliseconds.

Generation of Pedersen Commitments and Range Proofs
Taking the previously described transaction as an example, in order to achieve the hiding of the transaction amount, both parties of the transaction generate the Pedersen commitments for the relevant amounts and the range proofs for the output amounts based on Bulletproofs, respectively.The specific process is as follows.

Parameter initialization
The initialization information for generating elements G, H, and the reasonable range of amounts [2 , 2 ] is shown in Figure 6.

The sender generates the Pedersen commitments for the relevant amounts and range proofs based on Bulletproofs
The sender Bob first generates the Pedersen commitments C 1 , C 2 , and C 5 for input amounts v 1 , v 2 , and change amount v 5 .The generation process is shown in Figure 7, while the range proof π 5 for output amount v 5 is generated through the global reasonable range [2 lower , 2 upper ] of output amounts.The whole process is shown in Figure 8. ] of output amounts.The whole process is shown in Figure 8.

The recipient generates the Pedersen commitments for the relevant amounts and range proofs based on Bulletproofs
The receiver Alice generates the Pedersen commitment  for the payment amount  (the information related to its calculation results is shown in Figure 9) and generates the range proof  for the output amount  .The calculation results are shown in Figure 10.] of output amounts.The whole process is shown in Figure 8.

The recipient generates the Pedersen commitments for the relevant amounts and range proofs based on Bulletproofs
The receiver Alice generates the Pedersen commitment  for the payment amount  (the information related to its calculation results is shown in Figure 9) and generates the range proof  for the output amount  .The calculation results are shown in Figure 10.

3.
The recipient generates the Pedersen commitments for the relevant amounts and range proofs based on Bulletproofs The receiver Alice generates the Pedersen commitment C 4 for the payment amount v 4 (the information related to its calculation results is shown in Figure 9) and generates the range proof π 4 for the output amount v 4 .The calculation results are shown in Figure 10.
The time consumed by both the sender and the receiver to generate Pedersen commitments for the relevant amounts based on the algorithm Commit is about 16 ms, and the time consumed by the algorithm RangeProof to generate range proofs for the output amounts is about 640 ms.The time consumed for the relevant operations is in the millisecond range, and the size of the range proof is only about 2.8 kb, which is efficient in proving the legitimacy of the transaction amounts.
57.The recipient generates the Pedersen commitments for the relevant amounts and range proofs based on Bulletproofs The receiver Alice generates the Pedersen commitment  for the payment amount  (the information related to its calculation results is shown in Figure 9) and generates the range proof  for the output amount  .The calculation results are shown in Figure 10.The time consumed by both the sender and the receiver to generate Pedersen commitments for the relevant amounts based on the algorithm Commit is about 16 ms, and the time consumed by the algorithm RangeProof to generate range proofs for the output amounts is about 640 ms.The time consumed for the relevant operations is in the millisecond range, and the size of the range proof is only about 2.8 kb, which is efficient in proving the legitimacy of the transaction amounts.

Legality Verification of Transactions
The verification of transaction legitimacy includes the verification of ownership of the input notes, the legitimacy of the transaction amounts, and the verification of the correctness of the payment note by the receiver, etc.The specific verification process and performance are described below.

Verification of the ownership of the input notes
The sender Bob proves ownership of the input notes  and  by means of the ownership keys  and  corresponding to the stealth addresses  and  , and the related information and verification process are shown in Figure 11.

Legality Verification of Transactions
The verification of transaction legitimacy includes the verification of ownership of the input notes, the legitimacy of the transaction amounts, and the verification of the correctness of the payment note by the receiver, etc.The specific verification process and performance are described below.

1.
Verification of the ownership of the input notes The sender Bob proves ownership of the input notes note 1 and note 2 by means of the ownership keys t 1 and t 2 corresponding to the stealth addresses T 1 and T 2 , and the related information and verification process are shown in Figure 11.The time consumed by both the sender and the receiver to generate Pedersen commitments for the relevant amounts based on the algorithm Commit is about 16 ms, and the time consumed by the algorithm RangeProof to generate range proofs for the output amounts is about 640 ms.The time consumed for the relevant operations is in the millisecond range, and the size of the range proof is only about 2.8 kb, which is efficient in proving the legitimacy of the transaction amounts.

Legality Verification of Transactions
The verification of transaction legitimacy includes the verification of ownership of the input notes, the legitimacy of the transaction amounts, and the verification of the correctness of the payment note by the receiver, etc.The specific verification process and performance are described below.

Verification of the ownership of the input notes
The sender Bob proves ownership of the input notes  and  by means of the ownership keys  and  corresponding to the stealth addresses  and  , and the related information and verification process are shown in Figure 11.The legitimacy of the transaction amounts consists of two aspects: (1) the balance between the input and output amounts; (2) the range of the output amounts is reasonable.The balance of the input and output amounts is verified by the transaction receiver and the verification nodes through Equation ( 14) and Equation (19), respectively.Whether the range of the output amounts is reasonable is verified by the range proofs π 4 and π 5 generated by both parties, and then the verification of the proofs is completed by the verification nodes, as shown in Figure 12.As can be seen in Figure 12, when the sender correctly generates the commitments to the input amounts and the change amounts, the receiver is able to correctly complete the verification of the correctness of the payment amount by calculating the commitment to the payment amount.Equations ( 14) and ( 19) can only hold when both parties correctly generate Pedersen commitments for the relevant amounts, thus completing the balanced verification of the input and output of the transaction.The time consumed for verification is approximately 16.732 ms for Equation ( 14) and 0.346 ms for the other case, where Equation ( 14) includes one Commit operation in the verification process, and it is known from the previous section that the Commit operation consumes about 16 ms.When the output amounts v 4 and v 5 both satisfy the specified reasonable range [2 lower , 2 upper ], the corresponding range proofs can pass the legitimacy verification by the network.The time consumption of the verification algorithm RangeVerify for range proofs is only 12.025 ms on average.The legitimacy of the transaction amounts consists of two aspects: (1) the balance between the input and output amounts; (2) the range of the output amounts is reasonable.The balance of the input and output amounts is verified by the transaction receiver and the verification nodes through Equation ( 14) and Equation (19), respectively.Whether the range of the output amounts is reasonable is verified by the range proofs  and  generated by both parties, and then the verification of the proofs is completed by the verification nodes, as shown in Figure 12.As can be seen in Figure 12, when the sender correctly generates the commitments to the input amounts and the change amounts, the receiver is able to correctly complete the verification of the correctness of the payment amount by calculating the commitment to the payment amount.Equations ( 14) and ( 19) can only hold when both parties correctly generate Pedersen commitments for the relevant amounts, thus completing the balanced verification of the input and output of the transaction.The time consumed for verification is approximately 16.732 ms for Equation ( 14) and 0.346 ms for the other case, where Equation ( 14) includes one Commit operation in the verification process, and it is known from the previous section that the Commit operation consumes about 16 ms.When the output amounts  and  both satisfy the specified reasonable range [2 , 2 ], the corresponding range proofs can pass the legitimacy verification by the network.The time consumption of the verification algorithm RangeVerify for range proofs is only 12.025 ms on average.

Verification of the correctness of payment note by the recipient
The verification process of the correctness of the payment note by the receiver is shown in Figure 13.First, the receiver verifies whether the relevant note information is correct by decrypting the payment note  and then calculates the temporary key pair ( ′ ,  ′ ) of the note  using the shared knowledge of both parties.They further calculate the shared key  ′ and the confirmation key  , which can calculate the same stealth address using the confirmation key  .Finally, the receiver verifies the ownership of the payment note and completes the verification of the correctness of the payment note.

3.
Verification of the correctness of payment note by the recipient The verification process of the correctness of the payment note by the receiver is shown in Figure 13.First, the receiver verifies whether the relevant note information is correct by decrypting the payment note note 4 and then calculates the temporary key pair r 4 ′ , R 4 ′ of the note note 4 using the shared knowledge of both parties.They further calculate the shared key c 4 ′ and the confirmation key t 4 , which can calculate the same stealth address using the confirmation key t 4 .Finally, the receiver verifies the ownership of the payment note and completes the verification of the correctness of the payment note.The verification operations of transaction legitimacy in the BTPP scheme, including ownership verification of input notes, balance verification of transaction input and output, verification of the range proofs, the output amounts, and verification of correctness of payment notes.These operations are all performed in milliseconds and are highly efficient.At the same time, a series of verifications of transaction legitimacy can be passed only when the relevant proofs are correct.In summary, the BTPP scheme has correctness, feasibility, and efficiency.

Method Comparison
The previous sections provide a detailed analysis of the performance of the BTPP method and verify that the BTPP scheme has correctness, feasibility, and efficiency through relevant implementations and tests.This subsection will compare the BTPP scheme with its composition-related privacy protection methods to highlight the advantages of the BTPP scheme and its research significance.

Compare with the DKSAP Protocol
The DKSAP protocol is the privacy protection technology based on address hiding, which has been landed in many blockchain projects since its announcement.The BTPP scheme is proposed based on the DKSAP protocol, and the performance comparison results with the DKSAP protocol are shown in Table 5.The DKSAP protocol generates the temporary address for the receiver in each transaction and uses it as the receiver's address for this transaction, obscuring the transaction relationship between the two parties.The receiver verifies itself as the authorized receiver of this transaction by calculating the confirmation key of the transaction and thus cannot link the transaction relationship between the two parties.The BTPP method combines the stealth address and the note mechanism to conceal both transaction relationships and transaction amounts.The transaction sender in the DKSAP protocol needs to generate the temporary key pair (r, R) when calculating the stealth address and send the public key R together with the transaction.The temporary public key R identifies the transaction as a stealth transaction, resulting in the loss of some key privacy information.Additionally, the receiver needs to continuously retrieve transaction data from the blockchain and The verification operations of transaction legitimacy in the BTPP scheme, including ownership verification of input notes, balance verification of transaction input and output, verification of the range proofs, the output amounts, and verification of correctness of payment notes.These operations are all performed in milliseconds and are highly efficient.At the same time, a series of verifications of transaction legitimacy can be passed only when the relevant proofs are correct.In summary, the BTPP scheme has correctness, feasibility, and efficiency.

Method Comparison
The previous sections provide a detailed analysis of the performance of the BTPP method and verify that the BTPP scheme has correctness, feasibility, and efficiency through relevant implementations and tests.This subsection will compare the BTPP scheme with its composition-related privacy protection methods to highlight the advantages of the BTPP scheme and its research significance.

Compare with the DKSAP Protocol
The DKSAP protocol is the privacy protection technology based on address hiding, which has been landed in many blockchain projects since its announcement.The BTPP scheme is proposed based on the DKSAP protocol, and the performance comparison results with the DKSAP protocol are shown in Table 5.The DKSAP protocol generates the temporary address for the receiver in each transaction and uses it as the receiver's address for this transaction, obscuring the transaction relationship between the two parties.The receiver verifies itself as the authorized receiver of this transaction by calculating the confirmation key of the transaction and thus cannot link the transaction relationship between the two parties.The BTPP method combines the stealth address and the note mechanism to conceal both transaction relationships and transaction amounts.The transaction sender in the DKSAP protocol needs to generate the temporary key pair (r, R) when calculating the stealth address and send the public key R together with the transaction.The temporary public key R identifies the transaction as a stealth transaction, resulting in the loss of some key privacy information.Additionally, the receiver needs to continuously retrieve transaction data from the blockchain and perform elliptic curve scalar multiplication operations based on R to determine whether he is the authorized receiver, which is computationally intensive and inefficient.The BTPP method uses the Diffie-Hellman key exchange protocol to generate a random seed known only to both parties when generating the temporary key pair.From this, both parties to the transaction can calculate the temporary address of this transaction by themselves, avoiding the risk of exposure of the temporary public key.At the same time, the receiver no longer needs to continuously scan the block data and repeatedly perform relevant calculations to verify whether it is the recipient of the transaction.The receiver only needs to compare the temporary address of the transaction with the calculated temporary address, thereby reducing the demand for node computing resources and improving computing efficiency.The BTPP method ensures transaction privacy while maintaining trading efficiency.

Compare with the Zerocash
Zcash is a cryptocurrency designed to provide enhanced privacy, while the BTPP scheme incorporates the UTXO-based note mechanism in Zerocash.The comparison of the BTPP scheme with the Zerocash system is shown in Table 6.The Zerocash system improves transaction privacy using the zk-SNARKs, achieving protection for both transaction relationships and amounts.However, it relies on the zk-SNARKs for proof of note ownership and requires trusted setup involving the third party, resulting in lower transaction efficiency.Essentially, the Zerocash system is a weakly centralized system.In contrast, the BTPP method embeds the transaction's stealth address into the payment note.The mapping between the note and its corresponding stealth address is maintained on the blockchain through the Note Commitments table.This binding between the note and the stealth address enables efficient transfer of note ownership.The receiver can independently compute the confirmation key for the stealth address based on common knowledge.By leveraging the binding relationship between the stealth address and the note, efficient proof of note ownership is achieved.Additionally, the integration of the stealth address and note mechanism enhances transaction privacy.As mentioned earlier, the time consumption for relevant operations is milliseconds, demonstrating high efficiency.Compared to the Zerocash system, the advantage of the BTPP method is that it is completely decentralized, and the whole process does not require the participation of third parties.

Conclusions
This paper focuses on the problem of transaction privacy leakage risk in the public environment of blockchain.This paper first elaborates on the contradictory problem of the open and transparent nature of blockchain and the risk of transaction privacy leakage and analyzes and summarizes the current research status and progress, as well as the challenges and problems in the field of blockchain transaction privacy protection.To this end, this paper proposes the blockchain transaction privacy protection method that integrates the stealth address and the note mechanism, whose implementation does not depend on any third party and guarantees the privacy of transaction relationships and transaction amounts on the blockchain.
In order to verify and evaluate the feasibility, security, and efficiency of the proposed scheme in this paper, this paper concludes with a detailed analysis of the scheme in terms of both privacy and security.From the analysis results, it can be seen that the method proposed in this article can prevent fraudulent behavior by transaction senders, transaction receivers, and verifiers, ensure security, and also ensure the privacy and integrity of transaction information.Then, this paper evaluates and analyzes the BTPP scheme by designing relevant experiments based on different experimental purposes.Through the experimental results, it can be concluded that the proposed method consumes milliseconds in key processes, and the related commitments and proofs are also very small, which is crucial for controlling transaction costs.At the same time, it also verifies that only honest transaction participants can complete transactions.In addition, the BTTP method is compared with recent related works.The BTPP method can address the shortcomings of the original stealth address scheme, such as the inability to protect the privacy of transaction amounts, privacy loss caused by temporary key leakage, and the need for the receiver to calculate repeatedly.The BTPP method can also address the issues of requiring zk-SNARKs for relevant proving and third-party trusted settings in the Zerocash privacy trading system, achieving a completely decentralized privacy trading solution.
The findings of this article bear significant implications not only for enhancing the privacy capabilities of existing blockchain systems but also for the broader development of the digital security domain.For instance, these privacy protection methods can be applied in areas such as digital identity verification, secure data exchange, and enhancing the anonymity of financial transactions.Blockchain developers should consider integrating these privacy protection mechanisms to enhance user privacy and overall system security.Additionally, this article encourages subsequent research to build upon this foundation to make these privacy protection methods more applicable to a wide range of blockchain scenarios.Further studies are also needed to assess the feasibility and effectiveness of these methods in different blockchain architectures and their resilience in the face of advanced security threats.Through these practical applications and continuous research, the research results of this article will have a lasting and positive impact on the progress of blockchain technology and the development of digital security.
The BTPP method uses the Diffie-Hellman key exchange protocol to generate the randomness seed known only to both parties when generating the temporary key pair, which requires multiple interactions between the two parties.Although the interaction information does not affect the overall security even if it is listened to by an attacker, reducing the number of interactions between the two parties and simplifying the process of the whole scheme, or even achieving zero interaction, are still directions for future work to improve the scheme in this paper further.With the development of blockchain, its network scale will also expand, resulting in the current privacy protection solution having scalability problems in larger blockchain networks.This is also one of the studies that this article will focus on in the future.

Figure 2 .
Figure 2. Process of the BTPP method.

Figure 2 .
Figure 2. Process of the BTPP method.

25 Figure 3 .
Figure 3. BTPP timing diagram.18. Bob decrypts the notes by the private key  to obtain the values and other information; 19. Bob finds the notes that matche the transfer amount v as the input notes for this transaction, i.e.,  = [ ,  ], satisfying  =  +  ≥ , and the whole process is shown as Equation (3):

( 8 )
Bob randomly selects the random number r 5 of the change note note 5 transaction to generate the public-private key pair (r 5 , R 5 ); (9) Bob computes the shared keys c 4 = H(r 4 •S a ), c 5 = H(r 5 •S b ) for notes note 4 and note 5 , respectively; (10) Bob calculates the stealth addresses T 4 = c 4 •G + B a and T 5 = c 5 •G + B b of note 4 and note 5 , respectively, and the corresponding receiver Alice is also able to calculate the same shared key c 4 of the payment note note 4 based on the randomness seed seed, thus calculating the corresponding stealth address T 4 .The whole process is shown in Equation (11): NoteCreate(v 4 , r 4 , S a , B a ) → note 4 NoteCreate(v 5 , r 5 , S b , B b ) → note 5 (11) 3.4.3.Generation Phase of Pedersen Commitment and Bulletproofs Range Proof for Relevant Amounts

5. 3 .
Experimental Process and Result Analysis 5.3.1.Construction of the Output Notes 53.Initialization of the receiver's dual key pairThe receiver Alice initializes the dual key pair, i.e., the scan key pair (s, S) and the spend key pair (b, B), where the information of the generation element G and the associated key pair parameters are shown in Figure4.

Figure 4 .
Figure 4. Initialization of the receiver's dual key pair.

Figure 4 .
Figure 4. Initialization of the receiver's dual key pair.

Figure 5 .
Figure 5. Construction of the payment note.

Figure 6 .
Figure 6.Initialization of parameters related to the generation of Pedersen commitments and range proofs.56.The sender generates the Pedersen commitments for the relevant amounts and range proofs based on Bulletproofs The sender Bob first generates the Pedersen commitments  ,  , and  for input amounts  ,  , and change amount  .The generation process is shown in Figure 7,

Figure 5 .
Figure 5. Construction of the payment note.
Appl.Sci.2024, 14, x FOR PEER REVIEW 17 of 25 54.Construction of the output notes

Figure 5 .
Figure 5. Construction of the payment note.

Figure 6 .
Figure 6.Initialization of parameters related to the generation of Pedersen commitments and range proofs.56.The sender generates the Pedersen commitments for the relevant amounts and range proofs based on Bulletproofs The sender Bob first generates the Pedersen commitments  ,  , and  for input

Figure 6 .
Figure 6.Initialization of parameters related to the generation of Pedersen commitments and range proofs.
Appl.Sci.2024, 14, x FOR PEER REVIEW 18 of 25 while the range proof  for output amount  is generated through the global reasonable range [2 , 2

Figure 7 .
Figure 7.The sender generates the Pedersen commitments for the relevant amounts.

Figure 8 .
Figure 8.The sender generates the Bulletproofs-based range proof for the output amount  .

Figure 9 .
Figure 9.The recipient generates the Pedersen commitments for the relevant amounts.

Figure 7 .
Figure 7.The sender generates the Pedersen commitments for the relevant amounts.
Appl.Sci.2024, 14, x FOR PEER REVIEW 18 of 25 while the range proof  for output amount  is generated through the global reasonable range [2 , 2

Figure 7 .
Figure 7.The sender generates the Pedersen commitments for the relevant amounts.

Figure 8 .
Figure 8.The sender generates the Bulletproofs-based range proof for the output amount  .

Figure 9 .
Figure 9.The recipient generates the Pedersen commitments for the relevant amounts.

Figure 8 .
Figure 8.The sender generates the Bulletproofs-based range proof for the output amount v 5 .

Figure 9 .
Figure 9.The recipient generates the Pedersen commitments for the relevant amounts.Figure 9.The recipient generates the Pedersen commitments for the relevant amounts.

Figure 9 .
Figure 9.The recipient generates the Pedersen commitments for the relevant amounts.Figure 9.The recipient generates the Pedersen commitments for the relevant amounts.

25 Figure 10 .
Figure 10.The receiver generates the range proof of the output amount  based on Bulletproofs.

25 Figure 10 .
Figure 10.The receiver generates the range proof of the output amount  based on Bulletproofs.

Figure 11 .
Figure 11.Ownership verification of input notes.According to Figure 11, it can be observed that the stealth addresses  ′ and  ′ , calculated by the sender Bob using the confirmation keys  and  of the input notes, successfully complete the ownership proving and verification of the input notes.By comparing  with  ′ , the ownership of  by the sender Bob can be verified.Similarly, by comparing  with  ′ , the ownership of  by the sender Bob can be verified.The ownership verification operation OVerify consumes only approximately 0.37 ms.The

Figure 11 .
Figure 11.Ownership verification of input notes.According to Figure11, it can be observed that the stealth addresses T 1 ′ and T 2 ′ , calculated by the sender Bob using the confirmation keys t 1 and t of the input notes, Appl.Sci.2024, 14, x FOR PEER REVIEW 20 of 25 BTPP scheme demonstrates correctness and efficiency in verifying the ownership of input notes.59.Verification of the legitimacy of the transaction amounts

Figure 12 .
Figure 12.Verification of the legality of transaction amounts.

Figure 12 .
Figure 12.Verification of the legality of transaction amounts.

Figure 13 .
Figure 13.The receiver verifies ownership of the payment note.

Figure 13 .
Figure 13.The receiver verifies ownership of the payment note.

Table 1 .
Meaning of each symbol.

Table 1 .
Meaning of each symbol.

Table 2 .
The world state of the note before the transaction.
by the confirmation keys t 1 and t 2 and find the stealth addresses T 1 and T 2 corresponding to the note hash values h 1 and h 2 through the Note Commitments table, then determines Bob's ownership of note 1 by whether T 1 ′ and T 1 are equal.Bob's ownership of note 2 is determined by whether T 2 ′ and T 2 are equal.The whole verification process is shown in Equation (17):

Table 4 .
Hardware environment of the experiment.

Table 5 .
Comparison of DKSAP protocol and BTPP method.

Table 5 .
Comparison of DKSAP protocol and BTPP method.

Table 6 .
Comparison of Zerocash and BTPP method.