saml vs oauth : which one should i use?

32
SAML vs OAuth Anil Saldhana [email protected] http://anil-identity.blogspot.com Reference: http://architects.dzone.com/articles/saml-versus-oauth -which-one

Upload: anil-saldhana

Post on 08-May-2015

8.861 views

Category:

Technology


6 download

TRANSCRIPT

Page 1: Saml vs Oauth : Which one should I use?

SAML vs OAuth

Anil [email protected]

http://anil-identity.blogspot.com

Reference: http://architects.dzone.com/articles/saml-versus-oauth-which-one

Page 2: Saml vs Oauth : Which one should I use?

Informal Definitions

Page 3: Saml vs Oauth : Which one should I use?

Informal Definitions

• SAML (Security Assertion Markup Language) is an umbrella standard that encompasses profiles, bindings and constructs to achieve– Single Sign On (SSO),– Federation and– Identity Management.

Page 4: Saml vs Oauth : Which one should I use?

Informal Definitions

• OAuth (Open Authorization) is a standard for authorization of resources.

• It does not deal with authentication.– Look for OpenID Connect for Authentication.

Page 5: Saml vs Oauth : Which one should I use?

Formal Definitions

Page 6: Saml vs Oauth : Which one should I use?

Formal Definitions

• Security Assertion Markup Language is an XML-based open standard data format for exchanging authentication and authorization data between parties, in particular, between an identity provider and a service provider.

• From Wikipedia Page on SAML

Page 7: Saml vs Oauth : Which one should I use?

Formal Definitions

• OAuth : An open protocol to allow secure authorization in a simple and standard method from web, mobile and desktop applications.

• From OAuth.net

Page 8: Saml vs Oauth : Which one should I use?

Differences

Page 9: Saml vs Oauth : Which one should I use?

Token or Message Format

Page 10: Saml vs Oauth : Which one should I use?

Token Or Message Format

• SAML deals with XML as the data construct or token format.

• OAuth tokens can be binary, JSON or SAML as explained in OAuth Bearer Tokens (https://docs.jboss.org/author/display/PLINK/OAuth+Bearer+Tokens).

Page 11: Saml vs Oauth : Which one should I use?

Transport

Page 12: Saml vs Oauth : Which one should I use?

Transport

• SAML has Bindings that use HTTP such as HTTP POST Binding, HTTP REDIRECT Binding etc.– But there is no restriction on the transport format.

You can use SOAP or JMS or any transport you want to use to send SAML tokens or messages.

Page 13: Saml vs Oauth : Which one should I use?

Transport

• OAuth uses HTTP exclusively.

Page 14: Saml vs Oauth : Which one should I use?

Scope

Page 15: Saml vs Oauth : Which one should I use?

Scope

• Even though SAML was designed to be applicable openly, it is typically used in Enterprise SSO scenarios – within an enterprise or – enterprise to partner or – enterprise to cloud scenarios.

Page 16: Saml vs Oauth : Which one should I use?

Scope

• OAuth has been designed for use with applications on the internet, – primarily for delegated authorization of internet

resources. • OAuth is designed for Internet Scale.

Page 17: Saml vs Oauth : Which one should I use?

Which Versions Should Be Used?

Page 18: Saml vs Oauth : Which one should I use?

Versions

• SAML v2.0• OAuth v2.0

Page 19: Saml vs Oauth : Which one should I use?

Use Cases

Page 20: Saml vs Oauth : Which one should I use?

Use Cases

• If your use case involves SSO (when at least one actor or partner is an enterprise) – then use SAML.

Page 21: Saml vs Oauth : Which one should I use?

Use Cases

• If your use case involves providing access (temporarily or permanent) to resources (such as accounts, pictures, files etc.) – then use OAuth.

Page 22: Saml vs Oauth : Which one should I use?

Use Cases

• If your use case involves providing access to a partner or customer application to your portal– then use SAML.

Page 23: Saml vs Oauth : Which one should I use?

Use Cases

• If your use case requires a centralized identity source– then use SAML.

You can also use an Open ID Provider as a central Identity Provider under the OpenID Connect Specification (under development).

Page 24: Saml vs Oauth : Which one should I use?

Use Cases

• If your use case involves mobile devices– then use OAuth (with some form of bearer

tokens).

Page 25: Saml vs Oauth : Which one should I use?

Using SAML with OAuth

Page 26: Saml vs Oauth : Which one should I use?

SAML With OAuth

• Use SAML for authentication. • Use SAML token/assertion as the OAuth

bearer token in the HTTP bearer header to access protected resources.

Page 27: Saml vs Oauth : Which one should I use?

Replace SAML with OAuth

Page 28: Saml vs Oauth : Which one should I use?

Replace SAML With OAuth

• Use JWT for authentication. • Use JWT as the OAuth bearer token in the

HTTP bearer header to access protected resources.

Page 29: Saml vs Oauth : Which one should I use?

References

Page 30: Saml vs Oauth : Which one should I use?

References

• PicketLink : http://www.picketlink.org• IETF OAuth2 (

http://datatracker.ietf.org/doc/rfc6749/)• OpenID Connect

http://openid.net/specs/openid-connect-basic-1_0-22.html

Page 31: Saml vs Oauth : Which one should I use?

Full Article

http://architects.dzone.com/articles/saml-versus-oauth-which-one

Page 32: Saml vs Oauth : Which one should I use?

Contact Me

[email protected]