[KongchangAI]
Concept

HttpOnly

A cookie security attribute that, when set, prevents JavaScript from accessing the cookie. It is used to mitigate the theft of session tokens through XSS attacks.

Timeline (last 90 days)

Nov 2

Combined with Cookie attributes such as HttpOnly, Secure, and SameSite, this can further reduce the risk of tokens being stolen via XSS or leaked across sites.

Unverified50%
Nov 2

Session tokens usually exist in the form of a Session ID in a Cookie or a JWT, and subsequent requests use them to identify the user; if the Cookie is not set with HttpOnly, XSS scripts can read it directly; if not set with Secure, the token may leak over plaintext HTTP; if not set with SameSite, it is vulnerable to CSRF attacks.

Unverified50%
Oct 13

HttpOnly cookies can prevent JavaScript from reading session tokens, and are an effective measure against XSS session theft.

Unverified50%

All Facts (3)

Source Articles