Open calebmer opened 5 years ago
Our tokens are kinda encrypted anyway, does this really matter? Access tokens are signed with a secret only the server knows. Refresh tokens are a UUID generated by the server.
So attacker can’t spoof access tokens since you’d need to know the server only secret.
An attacker could brute force guess a refresh token UUID tho. This would not be a targeted attack, this would give an attacker random access to a session. We should think about how to prevent this.
This is a takeaway from the thoughtbot Application Security guide.
We use cookies to hold user authentication tokens. Think about the lifecycle of a cookie and how to secure them.