Sign-in links valid multiple times #3604
-
When using passwordless authentication, it seems that links are only valid once (even during the This is a problem with certain email firewalls that programmatically check links that are present in emails, making the link invalid when the actual user clicks the link. It would be useful for the link to be valid for login during the whole Note: I'm using the Prisma Adapter to store sessions in my DB. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
There is currently no way of doing this (and I don't see it changing). You have to make sure that the link won't be used up by firewalls. There are related discussions of this, try searching. You can also utilize https://next-auth.js.org/configuration/initialization#advanced-initialization to check if a request comes from a bot or an actual user. |
Beta Was this translation helpful? Give feedback.
-
@benjamintd you can create custom adapter by extending the Prisma Adapter here is some workaround that . you also have an option to write your own custom logic for token management.
|
Beta Was this translation helpful? Give feedback.
There is currently no way of doing this (and I don't see it changing). You have to make sure that the link won't be used up by firewalls. There are related discussions of this, try searching.
You can also utilize https://next-auth.js.org/configuration/initialization#advanced-initialization to check if a request comes from a bot or an actual user.