← All posts

OIDC vs SAML: What Single Sign-On Is Really Doing Under the Hood

If you've ever clicked "Sign in with your work account" and landed inside an app without typing a password, you've used single sign-on. And behind that button, one of two protocols was doing the work: SAML or OIDC. Most owners never see the difference. They sure feel it when it breaks, though.

Let's pull back the curtain, because the OIDC vs SAML question is simpler than it sounds, and it's one of the better places to start understanding how identity really works.

SSO is a badge, not a pile of keys

Here's how I think about it. Imagine your company has offices all over the world. You could hand every employee a separate key for each office. Forty offices, forty keys, forty things to lose, copy, or forget to take back when someone leaves.

Or you could give each person one badge. The badge gets them into every office they're allowed in, and when they leave, you turn off one badge and every door locks behind them.

That's single sign-on. One front door instead of forty. Your people sign in once, with one strong login and MFA, and your identity provider (Microsoft Entra, Okta, whoever you use) vouches for them to every app on the list.

What's actually happening underneath

Here's the thing most people don't realize: it's nothing more than fancy web redirects with a security layer underneath that ties it all together so it feels like one seamless technology.

You click on an app. The app says, "I don't know you, go ask the identity provider." Your browser gets bounced over to the identity provider, you prove who you are, and your browser gets bounced back to the app carrying a signed note that says, "Yep, this is them." The app checks the signature on that note and lets you in.

What "Sign in with your work account" does. It's redirects with a security layer underneath. What "Sign in with your work account" does 1Open the appThe app doesn'tknow who youare2Redirect toidentityproviderYou sign in andcomplete MFA3Signed notecomes backYour browsercarries it to theapp4App checksthe signature5You're in It's redirects with a security layer underneath. What "Sign in with your work account" does. It's redirects with a security layer underneath. What "Sign in with your workaccount" does 1Open the appThe app doesn't know who you are2Redirect to identity providerYou sign in and complete MFA3Signed note comes backYour browser carries it to the app4App checks the signature5You're in It's redirects with a security layer underneath.

SAML and OIDC are two different ways of writing and checking that signed note. SAML is the older one, built on XML. OIDC (OpenID Connect) is the newer one, built on OAuth 2.0 and JSON. Same idea, different paperwork.

What most people miss

Both are secure. Please don't walk away thinking SAML is "the insecure one." It isn't. The difference is in how much babysitting each one needs.

With SAML, the signature on that note depends on a certificate, and a certificate has an expiration date. Somebody has to renew it, and somebody has to swap the new one into the app at the right time. If nobody does, the app stops trusting the note, and everyone gets locked out at once.

I've seen this more than once. A SAML certificate expired and took down an application for tens of thousands of users. It seems like such a simple thing, but one expired certificate can cause havoc and a P1 emergency when a business-critical app is suddenly out of reach. Nothing was hacked. Nobody did anything wrong that day. A date just rolled over on a file nobody was watching.

OIDC is built to take that chore off your plate. The app can look up the identity provider's settings and signing keys on its own, and the keys can rotate without a person remembering to do it. Fewer hands, fewer calendar reminders, fewer 2 a.m. phone calls.

So which one should you pick?

When you get the choice, I'd go OIDC. Honestly, we used to prefer SAML where we could, mostly because it was easier to configure. Lately I've decided OIDC is the better way forward for the work we do. I also feel like the writing's on the wall: most large organizations are starting to move toward OIDC, along with phishing-resistant authentication.

That said, plenty of older apps only speak SAML, and sometimes a vendor or a customer requires it. That's fine. The real answer is "OIDC when you get to choose, SAML when you don't, and know which apps are which." If you do run SAML, put its certificate expiration dates on a calendar with an owner's name next to each one.

If you're curious how this fits into the bigger picture, our identity management work is built around exactly this: one front door, managed on purpose. And if you want a look at what happens when the system guarding that door has a rough month, I wrote about that in Okta's 19-CVE month.

Check this yourself

You can do this in an afternoon, no specialist required:

  1. Make a list of your business apps. Everything people log into, including the ones nobody remembers buying.
  2. Mark which ones use single sign-on, and which still have their own separate username and password. The ones off the list are usually your riskiest.
  3. For each SSO app, note whether it's SAML or OIDC. Your admin console will usually tell you.
  4. For every SAML app, write down the certificate expiration date and who's responsible for renewing it. Put a reminder on the calendar well ahead of it.
  5. Ask each vendor whether SSO costs extra. Some lock it behind a pricier plan, and it's much better to learn that before you sign than after.

The one thing I'd do first

If you only have time for one thing this week, make sure your apps are requiring MFA, and make sure your users are actually setting it up. That's the biggest bang for your buck, even if you can't do SSO yet. It's so much better with SSO and MFA together, but MFA by itself is a huge step up.

No pressure, but if you'd like a hand sorting out which of your apps are on which side of the line, I'm here if you need me.

Have a project like this?

Let's talk about what you're trying to solve.

Schedule a Consultation