Blockchain r-puzzle verification for secure payment redirection

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Conventional hash puzzles in blockchain transactions are vulnerable to malicious miners who can observe the unlocking script and redirect payments to themselves, and existing solutions like pay-to-public key hash (P2PKH) restrict the payment to a specific identity, limiting flexibility in designating signatory authority.

Innovation Solution

Implementing an 'r-puzzle' based on the r-part of an ECDSA signature, which allows anyone to prove knowledge of a secret value without revealing it, by using a challenge that verifies the r-part of the signature, ensuring the payment goes to the intended recipient.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Ease of operation

If conventional hash puzzles are used in blockchain transactions, then payment verification is simplified, but malicious miners can observe the unlocking script and redirect payments to themselves

Engineering Contradiction:
Improvepayment verificationVSAvoidpayment security
Core Design Contradiction:
Ease of operationVSReliability

Solution Approach 1:

The patent extracts the ephemeral key from the unlocking script, keeping only the r-part visible. This removes the vulnerability where malicious miners could observe the complete unlocking script and redirect payments, while maintaining the ability to verify payments through the r-puzzle challenge.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The r-puzzle challenge acts as an intermediary verification mechanism. Instead of directly verifying the complete unlocking script, the system uses the r-puzzle as an intermediate step that confirms payment authenticity without exposing sensitive key material that could be exploited for redirection.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Reliability

If pay-to-public key hash (P2PKH) is used to prevent malicious redirections, then payment security is improved, but the payment is restricted to a specific identity, limiting flexibility in designating signatory authority

Engineering Contradiction:
Improvepayment securityVSAvoidsignatory authority flexibility
Core Design Contradiction:
ReliabilityVSAdaptability or versatility

Solution Approach 1:

The patent implements a dynamic system where signatory authority can be flexibly designated and changed. Unlike static P2PKH that binds payments to a specific identity, the r-puzzle system allows the unlocking conditions to be dynamically configured through the challenge-response mechanism, enabling versatile signatory authority designation.

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

The r-puzzle mechanism serves multiple functions: it prevents malicious redirections like P2PKH, but also enables flexible signatory authority designation. The same mechanism can accommodate various authorization models including multi-signature requirements, time-locked conditions, and hierarchical authority structures.

Inventive Principle:
Principle #6Universality (Multi-functionality)

3Ease of operation

If the complete unlocking script is revealed in transactions, then payment verification is straightforward, but the ephemeral key is exposed, enabling malicious redirections

Engineering Contradiction:
Improvepayment verificationVSAvoidkey exposure vulnerability
Core Design Contradiction:
Ease of operationVSObject-generated harmful factors

Solution Approach 1:

The patent extracts only the necessary r-part of the ephemeral key for verification purposes, removing the harmful exposure of the complete unlocking script. This selective extraction maintains payment verification capability while eliminating the vulnerability that enables malicious redirections.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

Different parts of the cryptographic material serve different functions: the r-part is made visible for verification, while the s-part and other sensitive components remain hidden. This local differentiation of visibility and accessibility optimizes both verification ease and security.

Inventive Principle:
Principle #3Local quality

Data Source

PatentEP3966995B1Blockchain transaction comprising runnable code for HASH-based verification
Publication Date: 2025.06.25 NCHAIN LICENSING AG
  • EP3966995B1 patent drawingFigure 1
  • EP3966995B1 patent drawingFigure 2
  • EP3966995B1 patent drawingFigure 3~4

AI summary

A computer-implemented method comprising, at a verifying nodes of a blockchain network: obtaining a first transaction which comprises runnable code; receiving a second transaction which includes information comprising at least a submitted instance of an r-part and an s- part of a first ECDSA signature, and further comprising a nonce; and running the code from the first transaction. The code is configured to verify that H PoW (f(r, d)) meets a predetermined condition defined in the code, and to return a result of true on condition thereof, where r is the submitted instance of the r-part, d is the nonce, H PoW is a hash function, and f is a function combining q and d.