Sleepyhead.
Sleepyhead.

Reputation: 71

What ID can I use for the signed in user using passport-azure-ad?

I am adding Microsoft Account authentication to my web application. We need to store extra information about the signed in user to a DB. What id can I use for the user to associate this data with? I am assuming it is either the oid, tid, or sub.

Upvotes: 0

Views: 193

Answers (1)

WannabeCoder
WannabeCoder

Reputation: 71

You should use the user account OID or a combination of that and another property as its OID is globally unique.

Upvotes: 1

Related Questions