Home > database >  What is the difference between cookie authentication and accept cookie
What is the difference between cookie authentication and accept cookie

Time:05-30

Hello I have a question that I can't seem to find an answer. In web development.

So what is the difference between cookie authentication system when you register/login, your credentials to be stored in a cookie and the pop up box that says - Wants you to accept its cookies. Are these two separated cookies? I am confused.

CodePudding user response:

A server can send a Set-Cookie response header to ask the browser to store some data in a cookie.

This is often a token (such as a session ID or a JWT) which marks the user as being logged into the site.

It can also be a tracking token which is used to track your activity across different sites for, for example, marketing purposes.

(Or it can be various other things, but those are the most common).


Some browsers can be configured to prompt the user before a cookie is stored. This might cause a browser

Some countries have regulations which require the user grant permission before they are tracked. Sites will therefore often display a notice asking the user to accept the cookies. They very frequently use dark patterns to make it annoying to refuse and easy to accept by accident.

CodePudding user response:

Credentials are not stored in cookies. Cookie store a session id that is used to retrieve session id.

But cookies can also be used for many others purposes.

But in fact that is the same.

  • Related