vanitygen icon indicating copy to clipboard operation
vanitygen copied to clipboard

Compressed address support

Open salfter opened this issue 12 years ago • 2 comments

This contains some changes to find compressed vanity addresses. CPU-only as I know nothing about OpenCL, but it's generated valid Bitcoin, Litecoin, and Yacoin compressed addresses.

I've also added a flag for Litecoin addresses, so you can use -L instead of -X 48.

(Use -X 77 to get Yacoin addresses.)

salfter avatar May 22 '13 18:05 salfter

I gave OpenCL support a try at https://github.com/scintill/vanitygen/tree/compressed_opencl (includes salfter's commit.) It seems to be working for me, but I also knew nothing about OpenCL, so beware.

It's a bit faster since it doesn't have to hash a second SHA-256 block. I am wondering if I could do further optimization, since the full Y coordinate is not needed for a compressed pubkey, just the low bit (even or odd.) I don't understand the EC math or Montgomery reduction well enough to reason about it, and haven't taken the time to trace through all the multiplication code to try to understand it that way. I looked through some EC implementations' serialization routines and didn't see them taking any shortcuts for deriving a compressed public key from the secret, but then again there aren't many use cases where squeezing every last clock cycle out is as useful as it is here.

scintill avatar May 26 '13 03:05 scintill

Samr7 hasn't been active with this repo. I merged this into my fork at https://github.com/WyseNynja/vanitygen. It's easy to install with my brew tap at https://github.com/WyseNynja/homebrew-bitcoin and has various other fixes

BlinkyStitt avatar Jan 26 '14 22:01 BlinkyStitt