-
Hello @jmikrut, @DanRibbens and fellow devs, I wanted to know what secret key is being used to sign the JWT token during the login operation? I tried to debug the value which is being used here https://github.com/payloadcms/payload/blob/master/src/auth/operations/login.ts#L132. I have passed the secret as Can someone provide me more insight on what secret is being used to sign the JWT? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hey @rishi-afk — yep, you got it. Our secret keys need to be 32 characters exactly, so Payload takes in the secret key from the You can take a look at the Does this answer your question? |
Beta Was this translation helpful? Give feedback.
Hey @rishi-afk — yep, you got it. Our secret keys need to be 32 characters exactly, so Payload takes in the secret key from the
init
options, creates a hash from the incoming random string, and then saves the first 32 characters.You can take a look at the
init
method to see exactly what happens.Does this answer your question?