# Workstream 38: boundary keys and off-by-one search errors **No solution found.** Executed 8,339 compressed-key comparisons for distinct in-range scalars and four additional uncompressed-key comparisons; none matched Puzzle #71. This was not exhaustive. ## 1. Question and assumptions Can endpoint, chunk, resume, or integer conversion errors hide a solution? Test target boundaries and demonstrate failure detection on small generated puzzles. No inference from address prefixes is used: a prefix is not evidence of numerical proximity to the scalar. Verified bounds: `L = 0x400000000000000000 = 2^70`, `U = 0x7fffffffffffffffff = 2^71-1`, inclusive. Thus `N = U-L+1 = 1180591620717411303424`, with 71-bit scalars but only 70 unknown bits. The address-to-range association agrees with the independent puzzle implementation [S1]. This interval is a challenge convention; it cannot be proven from a P2PKH output alone. Assume the conventional compressed SEC public-key serialization. Four closest endpoints were additionally checked with uncompressed serialization. The oracle decodes Base58Check and compares all 20 HASH160 bytes, not a visual prefix. Derived target HASH160: `f6f5431d25bbf7b12e8add9af5e3475c44a0a5b8`. ## 2. Target, invitation, recipient, sources and dates All source retrievals and experiments occurred **2026-11-23 UTC**. The December 28, 2015 public thread advertises the puzzle reward and links the original funding transaction [S2]. Its author Bulista explicitly describes discovering the transaction, not creating it. The April 27, 2017 06:41:08 forum post by self-described creator saatoshi_rising explains the difficulty masking and supports the public cracking experiment [S3]. Creator identity and an earlier signed invitation were not verified. At **07:33:53–07:33:55 UTC**, Blockstream reported tip **977165**, 73 confirmed funded/unspent outputs totaling **710196696 sat = 7.10196696 BTC**, zero spent outputs, and all-zero mempool statistics [S4,S6]. At **07:34:20 UTC**, mempool.space independently returned the same address statistics and tip [S5]. Block 977165 hash was `000000000000000000014641e7b8d308b6a5eaec5772d150ceed4a4f3720e600` [S7]. These are sequential public API observations, not an atomic historical node snapshot. A second UTXO read at **07:35:58 UTC** still returned 73 confirmed outputs with the same total; the following tip read returned **977166**. UTXO confirmation heights span **339085–976128**. Three principal unspent outputs [S6]: | Transaction ID : output index | Height | Satoshis | |---|---:|---:| | `08389f34c98c606322740c0be6a7125d9860bb8d5cb182c02f98461e5fa6cd15:70` | 339085 | 7100000 | | `5d45587cfd1d5b0fb826805541da7d94c61fe432259e68ee26f4a04544384164:19` | 475240 | 63900000 | | `12f34b58b04dfb0233ce889f674781c0e0c7ba95482cca469125af41a78d13b3:5` | 785620 | 639000000 | The other 70 outputs sum to 196696 sat. The entire observed UTXO array, sorted by `(txid,vout)` and serialized with Python `json.dumps(...,sort_keys=True,separators=(',',':'))`, had SHA256 `25c7b0f81b8620370f6aeb5d5d3b5da8b4824dea13598c6b651cd1416e190bfe`. The live API can change; this is not an archival proof. Full live list: [S6]. **Status: unclaimed on the observed chain, consistent with unsolved; private knowledge cannot be ruled out.** No conflicting target parameters or spend were verified. Designated recipient, kept distinct from the target: `bc1pg6luxm9s4qq65lge4l6ual7xwdw5v85eh675cmrl5we0ht3vpfhswxu0cx`. Local validation against BIP350 [S8] passed: lowercase mainnet HRP `bc`, witness version 1, Bech32m polymod `0x2bc830a3`, canonical padding, 32-byte program `46bfc36cb0a801aa7d19aff5ceffc6735d461e99bebd4c6c7fa3b2fbae2c0a6f`. All 58 single-symbol cyclic mutations of the program/checksum section were rejected. Encoding does not prove ownership. No transactions or fund movements were made. ## 3. Method and actual results The complete code below uses integer affine secp256k1 arithmetic; contiguous scans initialize `aG` then add `G`. Thirty-two independent OpenSSL derivations (four endpoints plus 28 seeded random in-range scalars) matched compressed SEC bytes exactly. A known generator HASH160 is also asserted. Single-process CPU execution: **x86_64, Python 3.12.3, OpenSSL 3.0.13 (30 Jan 2024)**; no GPU, installs, or paid services. CPU model/count could not be determined: `lscpu` failed because `/sys/devices/system/cpu/possible` was unavailable. Total experiment wall time **12.113823 s**; timed target phase **1.545352 s**, including 8,192 incremental endpoint checks and 147 separately multiplied shard-edge checks. Measured mixed throughput: approximately **5,396 compressed comparisons/s**, not a GPU or optimized-search benchmark. Recipient checks, synthetic tests, differential checks and four uncompressed checks are outside that target-phase timing. Target candidate set (all inside `[L,U]`): first 4,096 and last 4,096 scalars, plus `c-1,c,c+1` at each of 49 internal boundaries `c=L+floor(N*i/50)`. **8,339 unique scalars, zero matches.** No outside-interval wallet candidates were searched. | Executed correctness test | Outcome | |---|---| | Synthetic interval `[256,511]` | All 256 HASH160 values distinct; recovered four endpoint/near-endpoint and 32 seeded interior targets exactly | | Resume after each possible cut | 257/257 prefix-plus-resumed streams equal uninterrupted stream | | Integer partition properties | 1,000/1,000 seeded cases pass, including one-key ranges, excess workers, non-divisible sizes and 32/64/70-bit vicinity | | Full-width 50-way partition, symbolic endpoints only | Adjacent half-open intervals, total N, lengths 23611832414348226068 or 23611832414348226069 | | Wrong upper-exclusive loop on inclusive bound | Detected one missing scalar | | Skipped lower endpoint | Detected one missing scalar | | Upper bound plus one too far | Detected one extra scalar | | Seven chunks each omit final scalar | Detected seven missing scalars | | Inclusive loop over seven half-open chunks | Detected six duplicates and one extra scalar | | Integer hazard assertions | 64-bit truncation, binary64 precision loss, limb carry and reversed byte order exposed | These are injected mutation tests, **not bugs found in another team's code**. Seed 38 supplies development cases; seed 3801 supplies 500 separate held-out partition cases using the same oracle. ## 4. Interpretation, limits and next experiment Use exactly `[L,U+1)` internally. For worker `i` of `w`, use `[L+floor(N*i/w), L+floor(N*(i+1)/w))`; retain empty shards when workers exceed candidates. Persist the **next untested** scalar. If persisting last-tested instead, explicitly add one on restart. Use arbitrary precision or 128-bit arithmetic here; 64-bit offsets cannot span this interval. Binary64 maps `L+1` to `L` and rounds `U` up to `U+1`, so floating-point progress arithmetic must never generate search bounds. Encode private scalars as 32-byte big-endian values; leading zero bytes must not be dropped by a fixed-size crypto API. Rejected hypotheses are limited: none of the selected edges is the target, and a full-width integer implementation avoids the demonstrated mistakes. No evidence was produced that boundary candidates are more likely than interior candidates. **Analysis-only random baseline:** under a uniform scalar prior, any 8,339 distinct candidates have success probability `8339/2^70 ≈ 7.0634e-18`. Boundary selection has the same probability as a random subset of equal size. No pattern significance or p-values are claimed. A future pattern claim would need held-out keys, random baselines and a correction for every tested pattern. Extrapolation only: maintaining this mixed measured rate over the whole interval would take roughly **6.93 billion years** (365.25 days/year), half that on average under uniform placement and no repeats. This is not a prediction for optimized hardware. The interval supplies the bounds and address hash for enumeration, but no verified target curve point was obtained. Pollard kangaroo/BSGS require that public point; they cannot be applied directly to HASH160. We did not claim an exhaustive search for every possible off-chain public-key disclosure. The next useful experiment is to run this same endpoint, resume, remainder, and 64-bit carry suite against the actual production scanner's parser, checkpoint format and worker scheduler. Inject synthetic target points immediately before/at/after shard boundaries, compare emitted scalar streams with the integer oracle, and require no gaps or overlaps after simulated interruption. Extending endpoint scanning without a new justified hypothesis is ordinary brute force, not an improved algorithm. ## 5. Offline reproduction Save this fenced block as `test/scratch/boundary.py` and run `python3 test/scratch/boundary.py` (do not use `-O`, which disables assertions). Requires existing Python 3.8+ with RIPEMD160 in hashlib and OpenSSL supporting secp256k1; no network, pip packages, external data or secret inputs. Output is aggregate only. Refresh target status before rerunning; timing varies. ```python import hashlib as H, json, random, time, platform, subprocess P=2**256-2**32-977 G=(int('79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798',16),int('483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8',16)) L,U=2**70,2**71-1 TARGET='1PWo3JeB9jrGwfHDNpdGK54CRas7fsVzXU' RECIPIENT='bc1pg6luxm9s4qq65lge4l6ual7xwdw5v85eh675cmrl5we0ht3vpfhswxu0cx' B58='123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz' B32='qpzry9x8gf2tvdw0s3jn54khce6mua7l' def sha(b): return H.sha256(b).digest() def decode58(s): n=0 for c in s: n=n*58+B58.index(c) b=b'\0'*(len(s)-len(s.lstrip('1')))+n.to_bytes((n.bit_length()+7)//8,'big') assert len(b)==25 and b[0]==0 and sha(sha(b[:-4]))[:4]==b[-4:] return b[1:21] def recipient(s): assert s==s.lower() and len(s)<=90 hrp,ds=s.rsplit('1',1); assert hrp=='bc' d=[B32.index(c) for c in ds]; chk=1 for v in [ord(c)>>5 for c in hrp]+[0]+[ord(c)&31 for c in hrp]+d: top=chk>>25; chk=((chk&0x1ffffff)<<5)^v for i,g in enumerate([0x3b6a57b2,0x26508e6d,0x1ea119fa,0x3d4233dd,0x2a1462b3]): if (top>>i)&1: chk^=g assert chk==0x2bc830a3 and d[0]==1 acc=bits=0; out=[] for v in d[1:-6]: acc=(acc<<5)|v; bits+=5 if bits>=8: bits-=8; out.append((acc>>bits)&255) assert bits<5 and ((acc<<(8-bits))&255)==0 and len(out)==32 return bytes(out) def add(a,b): if a is None: return b if b is None: return a x,y=a; z,w=b if x==z and (y+w)%P==0: return None m=((3*x*x)*pow(2*y,-1,P) if a==b else (w-y)*pow(z-x,-1,P))%P v=(m*m-x-z)%P return v,(m*(x-v)-y)%P def mul(k): a=None; b=G while k: if k&1: a=add(a,b) b=add(b,b); k>>=1 return a def sec(q,compressed=True): x,y=q return (bytes([2+(y&1)])+x.to_bytes(32,'big') if compressed else b'\x04'+x.to_bytes(32,'big')+y.to_bytes(32,'big')) def h160(b): return H.new('ripemd160',sha(b)).digest() def chunks(a,b,w): assert a<=b and w>0 n=b-a+1 return [(a+n*i//w,a+n*(i+1)//w) for i in range(w)] def scan(a,b): q=mul(a) for k in range(a,b): yield k,h160(sec(q)) q=add(q,G) def main(): t=time.perf_counter(); out={}; target=decode58(TARGET) assert target.hex()=='f6f5431d25bbf7b12e8add9af5e3475c44a0a5b8' out['recipient_program']=recipient(RECIPIENT).hex() bad=0 for i in range(4,len(RECIPIENT)): c=B32[(B32.index(RECIPIENT[i])+1)%32] try: recipient(RECIPIENT[:i]+c+RECIPIENT[i+1:]) except (AssertionError,ValueError): bad+=1 assert bad==len(RECIPIENT)-4 out['recipient_mutations_rejected']=bad assert h160(sec(G)).hex()=='751e76e8199196d454941c45d1b3a323f1433bd6' # Independent OpenSSL SEC1 derivation; private scalars are piped, not printed. rng=random.Random(38) check=[L,L+1,U-1,U]+[L+rng.randrange(U-L+1) for _ in range(28)] for k in check: der=bytes.fromhex('302e0201010420')+k.to_bytes(32,'big')+bytes.fromhex('a00706052b8104000a') r=subprocess.run(['openssl','ec','-inform','DER','-pubout','-outform','DER','-conv_form','compressed'],input=der,capture_output=True,check=True) assert r.stdout[-33:]==sec(mul(k)) out['openssl_differential']=len(check) # Small generated puzzles: exhaustive endpoint recovery and mutations. a,b=256,511; rows=list(scan(a,b+1)); lookup=dict(rows) assert len(set(lookup.values()))==256 mutants={'omit_upper':list(range(a,b)), 'omit_lower':list(range(a+1,b+1)), 'extra_upper':list(range(a,b+2)), 'chunk_gap':[k for x,y in chunks(a,b,7) for k in range(x,max(x,y-1))], 'chunk_overlap':[k for x,y in chunks(a,b,7) for k in range(x,y+1)]} out['mutants']={n:{'missing':len(set(range(a,b+1))-set(v)), 'extra':len(set(v)-set(range(a,b+1))), 'duplicates':len(v)-len(set(v))} for n,v in mutants.items()} for n,v in out['mutants'].items(): assert any(v.values()) for k in [a,a+1,b-1,b]+rng.sample(range(a+2,b-1),32): assert [j for j,h in rows if h==h160(sec(mul(k)))]==[k] out['synthetic_recoveries']=36 # Every checkpoint denotes the NEXT untested scalar. for cut in range(257): assert rows[:cut]+list(scan(a+cut,b+1))==rows out['resume_positions']=257 cases=0 for seed in [38,3801]: r=random.Random(seed) for _ in range(500): start=r.choice([1,2**32-20,2**64-20,L,U-500])+r.randrange(20) n=r.randrange(1,258); workers=r.randrange(1,300) parts=chunks(start,start+n-1,workers) flat=[k for x,y in parts for k in range(x,y)] assert flat==list(range(start,start+n)); cases+=1 out['partition_cases']=cases full=chunks(L,U,50) assert full[0][0]==L and full[-1][1]==U+1 assert all(full[i][1]==full[i+1][0] for i in range(49)) assert sum(y-x for x,y in full)==2**70 out['full_partition_sizes']=sorted(set(y-x for x,y in full)) # Integer hazards: wrap, float loss, and carry across a 64-bit limb. assert L&((1<<64)-1)==0 and U&((1<<64)-1)==2**64-1 assert float(L+1)==float(L) and int(float(U))==U+1 assert (L+2**64-1)+1==L+2**64 for k in [L,L+1,U-1,U]: assert int.from_bytes(k.to_bytes(32,'big'),'big')==k assert int.from_bytes(k.to_bytes(32,'big'),'little')!=k out['integer_hazards_detected']=True # Target candidates are strictly inside the verified interval. # 4096 at each end, plus +/-1 about each internal 1/50 shard boundary. candidates=set(range(L,L+4096))|set(range(U-4095,U+1)) for x,y in full[1:]: candidates.update([x-1,x,x+1]) start=time.perf_counter(); matches=0; compressed_checks=0; uncompressed_checks=0 for a,b in [(L,L+4096),(U-4095,U+1)]: for k,h in scan(a,b): matches+=h==target; compressed_checks+=1 edges=candidates-set(range(L,L+4096))-set(range(U-4095,U+1)) for k in sorted(edges): matches+=h160(sec(mul(k)))==target; compressed_checks+=1 elapsed=time.perf_counter()-start # Also check alternative SEC serialization at the four closest endpoints. for k in [L,L+1,U-1,U]: matches+=h160(sec(mul(k),False))==target; uncompressed_checks+=1 out.update(target_unique_scalars=len(candidates),compressed_checks=compressed_checks, uncompressed_checks=uncompressed_checks,target_matches=matches, target_seconds=elapsed,total_seconds=time.perf_counter()-t, python=platform.python_version(),architecture=platform.machine()) print(json.dumps(out,indent=2)) if __name__=='__main__': main() ``` Source links (exact supporting excerpts are in `sources.json`): - [S1](https://coinables.github.io/puzzle/) - [S2](https://bitcointalk.org/index.php?topic=1306983.0) - [S3](https://bitcointalk.org/index.php?topic=1306983.msg18765941) - [S4](https://blockstream.info/api/address/1PWo3JeB9jrGwfHDNpdGK54CRas7fsVzXU) - [S5](https://mempool.space/api/address/1PWo3JeB9jrGwfHDNpdGK54CRas7fsVzXU) - [S6](https://blockstream.info/api/address/1PWo3JeB9jrGwfHDNpdGK54CRas7fsVzXU/utxo) - [S7](https://blockstream.info/api/block-height/977165) - [S8](https://raw.githubusercontent.com/bitcoin/bips/master/bip-0350.mediawiki)