Fingerprint For State

8 views
Skip to first unread message

Paul Tiseo

unread,
Oct 29, 2015, 5:04:30 PM10/29/15
to actionHero.js

When doing third-party oAuth2 authentication, you really should supply the state parameter to prevent forgery attacks. Usually, you hash something known, but variable to each authentication attempt, say clientID or timestamp.

I was considering hashing data.connection.fingerprint, which would mean one can avoid having to store the value used (before hashing) to the DB, but still allow easy comparison/verification.

Does anyone see any potential issue with this approach?

Evan Tahler

unread,
Oct 29, 2015, 5:12:17 PM10/29/15
to actionHero.js
Seems fine to me!  

For HTTP clients (which I assume you are using due to oAuth), the fingerprint is stored in a cookie, and is sufficiently random enough.  Just do the normal cookie protection stuff (HTTP-only, SSL, etc), and you sould be fine.  
Reply all
Reply to author
Forward
0 new messages