Bitcoin Forum
May 06, 2024, 11:23:17 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: [RFC] Short Block and Address Reference  (Read 1142 times)
da2ce7 (OP)
Legendary
*
Offline Offline

Activity: 1222
Merit: 1016


Live and Let Live


View Profile
March 21, 2011, 01:00:29 AM
 #1

This is a draft specification for a short bitcoin block and bitcoin address lookup system.

This system will allow the reference of any of the addresses in the block chain with 100% accuracy.

Format:

2 xxxx Yyyy

Prefix: '2'
This is to signify that it is NOT a bitcoin address, as bitcoin addresses start with a '1'

xxxx
Base 58 encoded block number.  such as 1112  (for Block #1) or 1zzz (for Block #195111).  4 characters should last us for at least 150years.

Yyyy
the start of the bitcoin address, until it is the only address that fits, with the '1' removed.
for the bitcoin address: 12c6DSiU4Rq3P4ZxziKxzrL5LmMBrzjrJX (picked randomly from the block explorer) it would be '2' as no other address in that particular block starts with '12'
for example the address on block 1 will would have the code: 211122

Address 1NA4tpWBG4RZGeTj9RjaUhDQd6QsrCz4Si  would be 21Zz8N

This would be much easier to quote over the phone or write or type by hand!

Edit!  I hope I have the maths right now!

One off NP-Hard.
1714994597
Hero Member
*
Offline Offline

Posts: 1714994597

View Profile Personal Message (Offline)

Ignore
1714994597
Reply with quote  #2

1714994597
Report to moderator
1714994597
Hero Member
*
Offline Offline

Posts: 1714994597

View Profile Personal Message (Offline)

Ignore
1714994597
Reply with quote  #2

1714994597
Report to moderator
Once a transaction has 6 confirmations, it is extremely unlikely that an attacker without at least 50% of the network's computation power would be able to reverse it.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
theymos
Administrator
Legendary
*
Offline Offline

Activity: 5194
Merit: 12972


View Profile
March 21, 2011, 01:16:06 AM
 #2

The block at a certain number can change, which might cause you to point to the wrong address.

1NXYoJ5xU91Jp83XfVMHwwTUyZFK64BoAD
Gavin Andresen
Legendary
*
qt
Offline Offline

Activity: 1652
Merit: 2216


Chief Scientist


View Profile WWW
March 21, 2011, 01:19:21 AM
 #3

Neat idea!

As theymos says, this will only work 100% reliably for addresses buried "deep enough" in the block chain that the likelihood of a block-chain-re-org is vanishingly small.

How often do you get the chance to work on a potentially world-changing project?
Pieter Wuille
Legendary
*
qt
Offline Offline

Activity: 1072
Merit: 1174


View Profile WWW
March 21, 2011, 01:24:48 AM
 #4

I believe this is a useful idea, but I would define it on the level below the base58 encoding.

So, an address currently is a base58-transformed sequence of bytes:
  • A version byte (0)
  • The pubkey hash (160 bit, 20 bytes)
  • A 32-bit (4 byte) checksum

It's not that hard to define a similar format for shortened addresses, but I would suggest not requiring lookup code to parse full blocks when looking for an address - they could become quite big in the future. Rather, what about this:

A base58-transformation of:
  • A version byte (1)
  • A BER-encoded block number
  • A BER-encoded tx number
  • A BER-encoded txout number
  • A 8-bit (1 byte) checksum
(BER encoding: in every byte, bits 0-6 contain data, bit 7 signifies if another data byte follows, like UTF-8 for unicode)

Up to block number 2113663, and as long as less than 128 transactions and less than 128 outputs per txout are used, this results in 7 bytes, or 10 base58-encoded characters. An alternative (if it's meant for typing over, instead of automated handling), would be to use base36 (case-insensitive alphanumeric) resulting in 11 characters.


I do Bitcoin stuff.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!