5 posts · rss

Authentication and Authorization

Getting a token and keeping it safe: MSAL and Nested App Auth, PnP.Framework and Graph SDK auth, Easy Auth, and keeping third-party keys out of the browser.

Getting a token is the part of every integration that looks like it will take an hour and takes a day. This topic collects the auth problems I have actually hit rather than a tour of the protocol.

That includes the two client libraries you end up choosing between when talking to SharePoint from C#, and why the choice matters. Nested App Auth in an Outlook add-in, which exists because there is no popup on a phone. Easy Auth on a Function, which will happily reject the very events you configured it to receive. And keeping third-party keys server-side, because hiding a control in the UI is not the same thing as authorising the call behind it.

The through line: the hard part is rarely the token itself. It is where the token is allowed to live.