Understand OAuth 2.0 in 2 Minutes

Understand OAuth 2.0 in 2 Minutes

Understand OAuth 2.0 in 2 minutes. After reading this article, you will understand how OAuth works and know if you need it in your next project. Fingerprint representing OAuth 2.0 - May 20 · 3 min read. How OAuth works? In this example, the passport is your authentication, and the access key your authorization (which room or rooms of the hotel you can access).

After reading this article, you will understand how OAuth works and know if you need it in your next project.

Prerequisites:

Before we go further, you need to understand the difference between Authentication and Authorization.

  • Authentication is who you are.
  • Authorization is what you can do.

How OAuth works?

In the case of a hotel, you need to go to the front desk to get your access card for your room. In order to do that, you will need to present your passport.

In this example, the passport is your authentication, and the access key your authorization (which room or rooms of the hotel you can access).

Hotel example for OAuth 2.0

Hotel example for OAuth 2.0

Your personal information never leaves the front desk, this is OAuth where the front desk plays the role of the authorization server. In that case, the access key represents the access token that will make you access your room (the resource).

OAuth is an authorization framework as we saw in the example above.

Why would I need OAuth?

OAuth allows services to access each other on behalf of the user. For example, if you do log in with OAuth, you might give access to a service to read your google drive account or access to your google email account and your profile picture.

In short, you need OAuth when you want to access some information from an external service like Facebook, Google, Twitter, LinkedIn,….

oauth javascript authentication serverless

What is Geek Coin

What is GeekCash, Geek Token

Best Visual Studio Code Themes of 2021

Bootstrap 5 Tutorial - Bootstrap 5 Crash Course for Beginners

Nest.JS Tutorial for Beginners

Hello Vue 3: A First Look at Vue 3 and the Composition API

How To Set Up Two-Factor Authentication in cPanel

What is 2FA Two-Factor Authentication (or 2FA as it often referred to) is an extra layer of security that is used to provide users an additional level of protection when securing access to an account.

Serverless Functions in JavaScript | Build Netlify Serverless Functions with JavaScript

Build Serverless Functions in JavaScript with this Netlify Serverless Functions tutorial. Serverless Functions can be written in JavaScript and set up for deployment with GitHub and Netlify.

Hire Dedicated JavaScript Developers -Hire JavaScript Developers

Hire dedicated JavaScript Developers who are proficient in AngularJS, ReactJS, NodeJS, & VueJS frameworks. Get flexible hiring models as per your business requirements.

What is JavaScript - Stackfindover - Blog

What is PHP: - Who invented PHP, how it works, answers to all such questions about PHP, and much other information, you are going to

JavaScript Shopping Cart - Javascript Project for Beginners

JavaScript Shopping Cart - javascript shopping cart tutorial for beginnersBuy me a coffee 🍺 https://www.paypal.com/paypalme/ziddahSource Code: https://bit....