forge
forge copied to clipboard
encoding for random string to store in db
What encoding must be used for a string generated using
forge.random.getBytesSync(32)
to be saved to the db?
I have to retrieve it to the same string after fetching it from DB.
I'm learning to use forge too. Have you tried .toHex()
and forge.util.hexToBytes(hexstring)
?