For some websites I'd like to include the functionality to generate Bitcoin private keys & addresses client-side, just like bitaddress.org.
In fact, I don't even need to generate them randomly, just converting 256 bit hex keys (e.g. from brainwallets or deterministic key generators or other pseudo-random sources) to private keys and addresses.
For testing purposes, I actually saved bitaddress.org, stripped all HTML, and just called the relevant functions myself. Works great, but I guess that isn't the most 'clean' way to do this. And it's not trivial to keep up to date either. I know bitaddress.org is in github (
https://github.com/pointbiz/bitaddress.org) but is the library that bitaddress.org uses, and especially the hex key to private key / address conversion, also available separately? Or is just a matter of cherry-picking the right files from github?