0

There's a project that I would like to implement that would require me to implement a simple Ethereum wallet client for Android. I would like to know the basic building blocks for making such an application. I know about Trust Wallet and Lunary Wallet as open source examples, if you will, of an android wallet. But I was more or less looking for something more barebones..specifically, an application that can generate ethereum private keys in plain text so I can further understand the direction I want to take the project in. I would also, if possible, not like the project to be routed through a web service like myetherwallet. I want it to be fully functional as a native application. Thank you Etheropians!

  • An Ethereum private key is pretty much just a random number. (It has to be greater than 0 and less than 0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141.) So you just need to learn how to generate cryptographic random numbers on your platform. – smarx Mar 8 '18 at 3:22
  • Doesn't 0x signify a public key? I'm confused. I thought in order to create a private key I would need to interact with the ethereum blockchain – Stephen Mar 8 '18 at 3:58
  • 0x is a prefix that indicates a hexadecimal-encoded number. E.g. 0xa means the decimal number 10. Both private and public keys are often expressed in hexadecimal. No, you don't need to interact with any node in the blockchain to generate a new account. This can be done purely offline. – smarx Mar 8 '18 at 4:03
  • I understand. Thank you so much. So a few more questions if you don't mind I'm a newb. What would I need other than the key generator to create a full "wallet". I'm assuming when I create the private key then I can create the public key from that private key as well? – Stephen Mar 8 '18 at 4:20
  • Yeah, then there's just math to be done to go from a private key to a public key and then an Ethereum address. Look for a library that does "elliptic curve cryptography." Specifically, Ethereum uses the secp256k1 curve and then the keccak-256 hash function to get to the address. – smarx Mar 8 '18 at 4:25

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.