austbot
2/16/2018 - 4:26 AM

rbnacl store private key

rbnacl store private key

#option 1
key = RbNaCl::Random.random_bytes(RbNaCl::SecretBox.key_bytes) # bunch of bytes
[key].pack('m') # outputs a base64 encoded string

#option 2
Base64.encode64(key)