Finally Made My Decred Address!

Discussion in 'Addresses' started by 418Sec, Jan 5, 2016.

  1. 2017/12/15 - Decred v1.1.2 released! → Release Notes  → Downloads
  1. Karman

    Karman New Member

    Dec 28, 2015
    18
    5
    Male
    Sr. System Administrator
    Spain
    #21 Karman, Jan 7, 2016
    Last edited: Jan 7, 2016
    The longuer the name...

    Made mine from a single command line with file checking:

    COUNTER=0; STAY=1; while [ $STAY -eq 1 ]; do rm vanity; dcraddrgen -noseed vanity >/dev/null; grep karman vanity >/dev/null;STAY=$?;COUNTER=$[$COUNTER+1];echo -ne "\r$COUNTER"; done
    Bold is the name to search for :)

    EDIT: Trying to run this on a rPI is just wrong. ie. too slow..
     
    diegox104 likes this.
  2. Karman

    Karman New Member

    Dec 28, 2015
    18
    5
    Male
    Sr. System Administrator
    Spain
    If you prefer a bash script file (ie. vanitygen.sh):

    Code:
    #!/bin/bash
    
    TEXT=karman
    
    COUNTER=0
    STAY=1
    TMPFILE=vanity
    
    while [ $STAY -eq 1 ]; do
    	rm $TMPFILE
    	dcraddrgen -noseed $TMPFILE >/dev/null
    	grep $TEXT $TMPFILE >/dev/null
    	STAY=$?
    	COUNTER=$[$COUNTER+1]
    	echo -ne "\rSearching: $COUNTER"
    done
    
     
  3. Maicol792

    Maicol792 New Member
    Advocate (BitcoinTalk)

    Jan 5, 2016
    40
    22
    Male
    I'm at 300k address generated and not finded my req... How i can disable the dos Windows visualization for each addr generated? Thanks
     
  4. Karman

    Karman New Member

    Dec 28, 2015
    18
    5
    Male
    Sr. System Administrator
    Spain
    I wonder who will be the least lucky one who needs more than 1M to find a personal address..
     
  5. walkeralencar

    walkeralencar New Member
    Translator (Português)

    Dec 29, 2015
    57
    24
    Male
    CTO and PHP Consultant
    Brasília-DF, Brazil
    Well i got 1.4k generated last night, so i got near 2kk now.
     
  6. Karman

    Karman New Member

    Dec 28, 2015
    18
    5
    Male
    Sr. System Administrator
    Spain
    Did you generate 1.4K in one night? I got more than 230k in 3 hours... are you on a rPI?
     
  7. walkeralencar

    walkeralencar New Member
    Translator (Português)

    Dec 29, 2015
    57
    24
    Male
    CTO and PHP Consultant
    Brasília-DF, Brazil
    sorry, 1.4kk

    speed is limited by drcaddrgen
     
  8. davecgh

    davecgh Hero Member
    Developer Organizer

    Dec 31, 2015
    642
    788
    Male
    United States
    #28 davecgh, Jan 7, 2016
    Last edited: Jan 7, 2016
    I don't think so because that would mean a 3rd party has your private key and can then steal your funds with ease. Also, it's a really bad practice* to only use a single address.

    In reality, you will want to use a unique address per transaction. That is why this tool generates a seed of an HD keychain which will ultimately be importable into the copay-based wallet once it is released. The only reason a single address (which as I've mentioned previously is actually just the first address of the first account in the HD keychain derived from the generated seed) is generated by this tool is in order to facilitate the initial distribution of coins via the airdrop prior to release of the wallet.

    Perhaps a good way to think about it is treating an address like a unique invoice ID. Every time you invoice somebody for payment (i.e pay X decred in exchange for Y services/goods), it should be to a new unique address.

    * This is currently true, though at some point there might be other possibilities such as winterwitz one-time use signatures that have different properties in this regard.
     
  9. diegox104

    diegox104 New Member

    Jan 4, 2016
    11
    5
    Male
    This should also make the job, ensuring that the string is at the line start:
    i=1 ; while ! grep "^.........MyName" vanity >/dev/null 2>&1 ; do rm -f vanity ; ./dcraddrgen -noseed vanity >/dev/null ; i=$[i+1] ; echo -ne "\r$i" ; done​
     
  10. Karman

    Karman New Member

    Dec 28, 2015
    18
    5
    Male
    Sr. System Administrator
    Spain
    Mmmh.. shouldn't be 'egrep -e ... '?
     
  11. diegox104

    diegox104 New Member

    Jan 4, 2016
    11
    5
    Male
    Is it an extended expression? To me it works in ubuntu...
     
  12. walkeralencar

    walkeralencar New Member
    Translator (Português)

    Dec 29, 2015
    57
    24
    Male
    CTO and PHP Consultant
    Brasília-DF, Brazil
  13. diegox104

    diegox104 New Member

    Jan 4, 2016
    11
    5
    Male
    While experimenting on the vanity address i had a stupid doubt: can't figure out why it often starts whith "Ds"? :confused::oops:
     
  14. davecgh

    davecgh Hero Member
    Developer Organizer

    Dec 31, 2015
    642
    788
    Male
    United States
    #34 davecgh, Jan 7, 2016
    Last edited: Jan 7, 2016

    Decred uses two bytes for the address prefix.

    Currently the following are defined, but obviously it is not difficult to expand upon these in the future as needed:

    First Byte: D = mainnet, T = testnet, S = simnet, R = regtest net
    Second Byte: k = secp256k1 pubkey, s = secp256k1 pubkey hash, e = edwards (ed25519) pubkey hash, S = schnorr pubkey hash, c = script hash

    Thus Ds????????????????????????????????? = mainnet secp256k1 pubkey hash
     
    eshriek, colt05 and diegox104 like this.
  15. jimmy16

    jimmy16 Jr. Member

    Jan 8, 2016
    143
    33
    Male
  16. diegox104

    diegox104 New Member

    Jan 4, 2016
    11
    5
    Male
    Thanks Dave, you are very kind :)
     
  17. Dyrk

    Dyrk Sr. Member
    Developer

    Jan 7, 2016
    518
    376
    Male
    Wonderland
    Why not to use 1 address always?
     
  18. davecgh

    davecgh Hero Member
    Developer Organizer

    Dec 31, 2015
    642
    788
    Male
    United States
    #38 davecgh, Jan 8, 2016
    Last edited: Jan 8, 2016
    @Dyrk: There are several reasons, but here are some of the most common ones:

    1. Holding all of your funds in a single address means you could lose everything if the private key for that address is compromised (a.k.a don't put all your eggs in one basket)
    2. Using a single address harms your privacy and everyone else who is either directly or indirectly involved with a transaction that includes your address. In some instances and jurisdictions this can even have legal ramifications.
    3. You can't easily differentiate who sent what amounts in order to properly track who has paid you in full and who hasn't. In some rare circumstances, you can't differentiate at all.
    4. When you sign a transaction using the same private key multiple times (which is what happens you reuse an address) you are increasing the chances your private key can be calculated as has happened previously in Bitcoin. While it's true that deterministic signatures are used in the Decred wallet software that will be available at launch and there are no known cases of being able to find private keys from said signatures at the current time, it is much safer to assume there are unknown attacks and simply use good security hygiene to avoid the potential altogether.
    5. It can potentially lead to higher transaction fees depending on how the particular wallet software calculates fees and the size of the transactions involved (for example, a lot of small inputs lead to larger transactions)
     
    Rune S, ClokworkGremlin and tacotime like this.
  19. Dyrk

    Dyrk Sr. Member
    Developer

    Jan 7, 2016
    518
    376
    Male
    Wonderland
    Thanks for the reply @davecgh
    It seems reasonable, but usually people want to keep everything in one place, that's why millions use Steam, iTunes, Netflix etc.
    So idea to have hundreds of addresses seems to be a little annoying :)
     
  20. nat

    nat New Member

    Jan 4, 2016
    6
    4
    sysadmin
    NYC
    Thanks for this! I've modified the script a bit, as yours will match that string anywhere within the public or private key. Here is one that should only match the string starting from the third character of the address:

    Code:
    #!/bin/bash
    
    TEXT=nat
    
    COUNTER=0
    STAY=1
    TMPFILE=vanity
    
    while [ $STAY -eq 1 ]; do
    rm $TMPFILE
    dcraddrgen -noseed $TMPFILE >/dev/null
    grep $TEXT $TMPFILE >/dev/null
    grep Addr $TMPFILE| awk '{print $2}' | xargs grep ^..$TEXT >/dev/null
    STAY=$?
    COUNTER=$[$COUNTER+1]
    echo -ne "\rSearching: $COUNTER"
    done
    
     

Share This Page