Популярное

Музыка Кино и Анимация Автомобили Животные Спорт Путешествия Игры Юмор

Интересные видео

2025 Сериалы Трейлеры Новости Как сделать Видеоуроки Diy своими руками

Топ запросов

смотреть а4 schoolboy runaway турецкий сериал смотреть мультфильмы эдисон
dTub
Скачать

Difference between cookies, session and tokens

difference between session and cookies

what is session

jwt authentication

authentication

security

sessions

cookies

localstorage

web storage

redis

token

Автор: Valentin Despa

Загружено: 2 сент. 2021 г.

Просмотров: 716 406 просмотров

Описание:

What are cookies, sessions, and tokens? Most web servers use cookies to send the session-ID after you log in.
🔻 Click on SHOW MORE 🔻

So the server will store the session information in the database while you will only have the session id in a cookie, which is stored in the filesystem of your computer.

Next time you request another page, your browser will automatically send a cookie containing your sessionId, which the server will check to see if it is valid.

The session-ID is randomly generated and should be hard to guess. If you log out, the session will be deleted on the server, but also the server will instruct the browser to delete the cookie containing the session-ID.

An alternative to this is to store information on the client and sign it. In this scenario, anyone holding the signature can quickly check if the data was manipulated or not. One way to do this is to use JSON Web Tokens (JWT tokens).

Let's now assume that you want to install an app on your phone, which can help you with your finances and keep track of your spendings. What you don't want to do is to give your username and password to this app, which was not created by your bank. This is when access tokens are being used to grant access to your data.

Technologies mentioned in this video:

JWT Tokens: https://jwt.io/
OAuth, OAuth2: https://oauth.net/
OpenId: https://openid.net/

#cookies #sessions #tokens
--

⭐️ Additional explanation ⭐️


[1] In the example shown, the user transitioned from a not-logged-in state (one session id) to a logged-in state (new session id). This is why you see two cookies. Make sure you check the HTTP requests for the Set-Cookie and Cookie headers.

[2] While both the Cookie/Set-Cookie and Authorization are headers, a browser will always treat the Cookie/Set-Cookie differently.


If this was helpful and you want to support me create more videos like this one, please consider subscribing.
👉    / @vdespa  

--

⭐️ Video contents ⭐️

⌨️ 00:00 - Login example with cookies
⌨️ 05:26 - Recap: cookies and sessions
⌨️ 06:06 - Token-based authentication
⌨️ 09:20 - Difference between tokens vs session cookie
⌨️ 11:00 - Conclusion

--

⭐️ 💬 I have a question. ⭐️

I do my best to answer all comments here on YouTube but I cannot make any guarantees.

Please do not email me or contact me on other channels as I might not be able to answer. Sorry!

--

⭐️ 💡 I have a video idea ⭐️

Do you want me to create a video on a specific topic? Just fill out the form below:

https://forms.gle/uWEzXFQ2viJtZtvZ7

--

⭐️ 📩 Contact & Imprint ⭐️

👉 Follow me on Twitter:
  / vdespa  

👉 Follow me on Medium:
  / vdespa  

👉 Follow me on Facebook:
  / valentin-despa-113038143438826  

👉 Let's connect on LinkedIn:
  / vdespa  

http://vdespa.com/imprint

Difference between cookies, session and tokens

Поделиться в:

Доступные форматы для скачивания:

Скачать видео mp4

  • Информация по загрузке:

Скачать аудио mp3

Похожие видео

🍪 What are cookies and how to get rid of cookie banners?

🍪 What are cookies and how to get rid of cookie banners?

What is JWT? JSON Web Tokens Explained (Java Brains)

What is JWT? JSON Web Tokens Explained (Java Brains)

Difference between cookies, session and tokens (re-upload, no music)

Difference between cookies, session and tokens (re-upload, no music)

Что такое REST API? HTTP, Клиент-Сервер, Проектирование, Разработка, Документация, Swagger и OpenApi

Что такое REST API? HTTP, Клиент-Сервер, Проектирование, Разработка, Документация, Swagger и OpenApi

Kerberos Authentication Explained | A deep dive

Kerberos Authentication Explained | A deep dive

Что такое Rest API (

Что такое Rest API (

An Illustrated Guide to OAuth and OpenID Connect

An Illustrated Guide to OAuth and OpenID Connect

Backend web development - a complete overview

Backend web development - a complete overview

Cookies: The Hidden Tech That Keeps the Internet Running

Cookies: The Hidden Tech That Keeps the Internet Running

The Complete Web Development Roadmap

The Complete Web Development Roadmap

© 2025 dtub. Все права защищены.



  • Контакты
  • О нас
  • Политика конфиденциальности



Контакты для правообладателей: [email protected]