Pricing  Get Quote
 
 

What is OAuth?

OAuth is an authorization protocol that allows authenticated access to server and service resources without sharing any logon credentials. OpenID Connect is an identity layer on top of OAuth's framework.

In simpler terms, OAuth helps you access a resource without having to prove your identity after you have already been authenticated.

While OAuth provides the basic framework to achieve this and leaves the detailing up to you, OpenID Connect attempts to standardize such customizable areas in OAuth.

 

SAML vs. OAuth

If you are using any application that requires authentication, there is a good chance you are using Security Access Markup Language (SAML) to access the application. SAML 2.0 is the widely used, industry-standard authentication protocol today.

Both SAML and OAuth can be used to implement single sign-on (SSO). Instead of comparing these two protocols, it is better to understand how they can work together to give you the best of both worlds. SAML is an authentication protocol, while OAuth is an authorization protocol. You can use SAML wherever a login is required and use OAuth to provide access to other protected resources like applications and files.

Components in OAuth and OpenID Connect

 
Authorization server

Verifies the user's credentials and provides the key that allows them to log in. As the authorization server owns all the user details, it has control over the scope and duration for which clients can access these details.

 
Client application

Contains the resources the user wants to access. The client application communicates with the server to get information that can verify a user's identity before granting access.

 
User

Attempts to log in to the client application. The user information is stored in the server to verify and provide access to the right users.

How OAuth works

This is how OAuth provides SSO:

  1. A user tries to log in to an application. The application sends an authorization request to the authorization server. The user is redirected to the server login page.
  2. The user enters their logon credentials on the server login page. After successful verification, an authorization code is sent to the application from the server.
  3. The application sends the authorization code back to the server to receive the access token and refresh token. The access token acts as a time-bound key for the user to access the application's protected resources. The refresh token is a permanent key that can be used to request a new access token after the old one expires.
  4. The application sends a user info request along with the access token to the server as proof of identity. The response to this request returns the user profile details required to complete the login process.
  5. After successful verification of user details at the application's end, the user is logged in to the application.
what-is-oauth-and-how-does-oauth-work-screen-shot-1

How OpenID works

OpenID Connect is similar to OAuth SSO, but an ID token is used here. The ID token contains the signature of the server and the user details. There are two possible scenarios here: application-initiated login and server-initiated login. Let's understand the workflow in both these cases.

Application-initiated login

  1. A user tries to log in to an application. The application sends an authorization request to the server. The user is redirected to the server login page.
  2. The user enters their logon credentials on the server login page. After successful verification, an authorization code is sent to the application from the server.
  3. The application sends the authorization code back to the server to receive the ID token. This token contains the user details required to complete the login process.
  4. After verifying the signature of the server in the ID token, the application retrieves the user details from the ID token.
  5. After the successful verification of user details on the application's end, the user is logged in to the application.
what-is-oauth-and-how-does-oauth-work-how-open-id-works

Server-initiated login

  1. A user logs in to the authorization server successfully. The user then tries to log in to another SSO-enabled application.
  2. In this case, the server sends an ID token to the application directly.
  3. After verifying the signature of the server in the ID token, the application retrieves the user details from the ID token.
  4. After the successful verification of user details on the application's end, the user is logged in to the application.
 

Why use OAuth?

The most important feature of OAuth is the tokenization of data. Tokens ensure that the actual credentials and other sensitive information of a user account are not exposed to data hacks and other attacks. Also, if any suspicious activity is detected, a token can be easily revoked by the server.

OAuth relies on SSL, which uses cryptography, to ensure that the data transferred between the server and the client remains private, rendering even the tokens secure.

Users are given limited access since the tokens are time-bound. This prevents risks caused due to prolonged availability of protected resources.

Implement OAuth and OpenID Connect SSO with ADSelfService Plus

ManageEngine ADSelfService Plus is an identity security solution offering MFA, SSO, and self-service password management. It provides enterprise SSO for applications using SAML, OAuth, and OpenID Connect protocols. Here are some benefits of using ADSelfService Plus to implement SSO:

  •  

    Custom SSO configurations

    Supports SSO for hundreds of established enterprise applications and SSO for custom cloud and on-premises SAML-, OAuth-, and OpenID Connect-based applications.

  •  

    Granular SSO policies

    Ensures users have access to only the necessary applications through SSO based on the Active Directory OUs and groups they belong to.

Secure and streamline enterprise application access with SSO using ADSelfService Plus

Start a free trial

ADSelfService Plus trusted by

Embark on a journey towards identity security and Zero Trust
Email Download Link