Jump to content
Larry Ullman's Book Forums

Possible Errata , or improvement. + a question


Recommended Posts

Chapter 7 page 240.  The salt nacl is saved like VARBINARY(64)  but its dimension is always 64 byte thereby could be better BINARY(64).

Furthermore    nacl=UNHEX(SHA2(RAND(),512)  uses RAND() that has low entropy, you could use RANDOM_BYTES(len)    with len>16 namely

nacl=UNHEX(SHA2(RANDOM_BYTES(20),512)

Furthermore I didn't undestand one thing:

RAND() return a FLOAT and SHA2() function need as first parameter a String thus how does it work? Is there in MySQL an automatic conversion from float to String?

 

Best regards

Nick

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...