Home » Php » javascript – How to covert unit8array to chars to use it with bcrypt?

javascript – How to covert unit8array to chars to use it with bcrypt?

Posted by: admin February 25, 2020 Leave a comment

Questions:

I am using this library to derive long 32 bytes key which only part of it 16 bytes will be used for authentication in Laravel and I do not know how to deal with unit8array that is produced by the library scrypt function which will be passed to the server because I need to hash using bcrypt and all I know is bcrypt accepts characters.
Please advice should I convert it to something like base64 then use the output as input for bcrypt? or is there any better method?

How to&Answers: