Bitcoin Forum
May 26, 2024, 06:09:28 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Generate short address with vanitygen  (Read 700 times)
brunokim (OP)
Newbie
*
Offline Offline

Activity: 1
Merit: 0


View Profile
September 17, 2013, 05:32:23 PM
 #1

I guess this is more a regex question than a Bitcoin question. I'm trying to generate short addresses (https://en.bitcoin.it/wiki/Address#What.27s_in_an_address) using vanitygen, calling the following regex from bash:

Code:
./vanitygen -r "^1[1-9A-HJ-Za-km-z]{27,32}\$"

Generating a 33- or 32-char address is fast, but it tries indefinitely if I try with fewer chars. According to the wiki, shorter addresses are those that happen to have zeroes at the start, so shouldn't I expect that a 30-char address be equivalent to find a 4-char prefix?
wtfvanity
Hero Member
*****
Offline Offline

Activity: 504
Merit: 500


WTF???


View Profile
September 17, 2013, 05:45:48 PM
 #2

I guess this is more a regex question than a Bitcoin question. I'm trying to generate short addresses (https://en.bitcoin.it/wiki/Address#What.27s_in_an_address) using vanitygen, calling the following regex from bash:

Code:
./vanitygen -r "^1[1-9A-HJ-Za-km-z]{27,32}\$"

Generating a 33- or 32-char address is fast, but it tries indefinitely if I try with fewer chars. According to the wiki, shorter addresses are those that happen to have zeroes at the start, so shouldn't I expect that a 30-char address be equivalent to find a 4-char prefix?

The actual address itself will not start with zeros. It's the address that is encoded that starts with the zeros. I know of no way unfortunately to improve your query to find the shorter addresses inside of vanity gen.

          WTF!     Don't Click Here              
          .      .            .            .        .            .            .          .        .     .               .            .             .            .            .           .            .     .               .         .              .           .            .            .            .     .      .     .    .     .          .            .          .            .            .           .              .     .            .            .           .            .               .         .            .     .            .            .             .            .              .            .            .      .            .            .            .            .            .            .             .          .
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!