How to generate a zcash vanity address? Is the main network address version for zcash already known? Is it possible to generate a mainnet address already?

This could allow miners to start from minute 0 to mine on a anonymous pool. The addresses can exist without the network as they are just a cryptographic keypair.

I checked the chain params at the source repository.

It looks like t-type addresses start with t1, and multisig with t3.

// guarantees the first 2 characters, when base58 encoded, are "t1"
base58Prefixes[PUBKEY_ADDRESS]     = {0x1C,0xB8};
// guarantees the first 2 characters, when base58 encoded, are "t3"
base58Prefixes[SCRIPT_ADDRESS]     = {0x1C,0xBD};


And from the protocol:


  In Bitcoin a single byte is used for the version field identifying the address type. In Zcash two bytes are used. For addresses on the production network, this and the encoded length cause the first two characters of the Base58Check encoding to be fixed as “ t3 ” for P2SH addresses, and as “ t1 ” for P2PKH addresses. (This does not imply that a transparent Zcash address can be parsed identically to a Bitcoin address just by removing the “ t ”.)


But how to generate them? Never seen dual prefixes berfore. Also, what's the address version? My vanitygen is unable to cope.
To simply generate a new main network address, you can use the official zcash-cli like that:

$ zcash-cli getnewaddress
t1fMAAnYrpwt1HQ8ZqxeFqVSSi6PQjwTLUm


Or: 

$ zcash-cli z_getnewaddress
zcHTYUQRA54WGdcNtLRx1yRyvEJjLD8NAK4S7FbEGoqB1s5En4syEStMnJPRMAD8XmF9xgeKnCEuZ7g35LcNpMhRDZX4PDw


Vanity is a bit tricky, but there is an offline wallet generator available here (forum, gitub).

It can be installed via go:

$ export GOPATH="$GOPATH;/home/user/.go"
$ go get -u github.com/btcsuite/btcutil
$ go get -u github.com/blackkeyboard/mneumonic
$ go get -u github.com/blackkeyboard/zgenerate
$ go install github.com/blackkeyboard/zgenerate


After that it can generate valid (?) zcash addresses.

$ ~/.go/bin/zgenerate 
2016/10/28 10:42:09 Wallet generated!
2016/10/28 10:42:09 Passphrase: afraid master w...
2016/10/28 10:42:09 Address                                Private key
2016/10/28 10:42:09 t1eTNgQHp7ei42ZtVRJ8jmUrsfu3rQqpXKt    cQM...


Now, generating vanity needs some bash tricks for now. And a lot of disk space, as long as nobody codes a proper vanity generator.

First, generate a lot of addresses and pipe the output to a file:

$ while true; do ~/.go/bin/zgenerate -n 99 &gt;&gt; keypairs.txt 2&gt;&amp;1; done


And in another shell, look for the results

$ grep -i t1 keypairs.txt | awk '{print $3}' | grep -i 5chd
t1MniMQux3755CHdMdVEtk71GzDkrLjmMbL
t1QMERYYnhCTdpreFwp5chdhqejr7NxRJvK
t1euq6Yg5chDcdEd9LCmwDPizqAU6uBF5Lt
t1PqrCEUW5ChDcaxe9qsQjPiCVt5qd727qH
t1h5ouE263Ccuo5ChDwWRn9HJCMrT3DR7gN
t1Qo5cHDbNBaoaFTKJLrWHBFPoqBZjRRLAS
t1W5cHDhrAnHERt9Tv3r6cgRh9hKybRbn7q
t1dViyc3SQatNZXnoMwcFLB1ELTHNwT5chD
t1e7D5qgdpbxNLoi5ChdTpLFauz8VrQJ2He
t1Va5cHdqLWmnHeAycS9y3qoP3rDAyPJubD
t1UszZECKVPgFpjkYKubyC5chduhSTQscPz
t1LjhytxXj9YLzeBikShm2kj78N5chdkJkm
t1MyW2vggvzHKjPCZDcd5cHdDPsvYMXCp8F
t1UMn4PpwnvPBH6hiunhoXbXRqBoJz5CHDo
t1aohPrSU7bFsC5CHDEPi5Ed7mVxvnNjeuq
t1cMAXhkVSaPcGmzVwN15cHduRKpbLtFJ1H
t1NZRXnKdACxU9xYH9P5chdTcNZfFQ6mT5L
t1QXXyYidirdW4KQz5ChDtYGestzDJ9FyiS
t1cHMeeWtGqnduj5chDFXka8krJMLtDoiJb
t1Pv4zxf5ChDXsCiKkajeJ1qpkQyv1MbSTd
t1KftUZAas3mAyKL5chd97nbDz8S2iF8PQF
t1WQYSvAWPLFHh9gyg6m635CHD3A49C9AvH
t1cuG5ChdTvE864hCKbM9tpToYNU4u8QWA6
t1bTuRMnbJMG1z2tRySoz5cHD1VB6mNFKAX
t1MX7GuYdMcKH9nWgc5chDj99qgd9H1186i
t1VvKMh2LRiTeUY3B5p5oa5CHDWhzK5ZMxB
t1Z34PDzF5CHDfnvJdRFUsQQCWTys2Wv4FE


Stop if you are satisfied.