Should the cookie secure flag be set on websites which are served only through HTTPS?
The Secure attribute tells the browser to only send the cookie if the request is being sent over a secure channel such as HTTPS
Let's say the victim connect to https://example.com and there is no http://example.com.
How can an attacker have access to the cookie? I mean if he intercepts the traffic the cookie will be encrypted.
- server misconfiguration like?
- In the sub.example.com case, should the attacker buy the domain first or in your example you suppose that another application is accessible at sub.example.com?
- I read that to run a sslstrip attack the attacker acts as a proxy between the victim and the server, changing from HTTPS to HTTP. Doesn't this mean that the original website should support also HTTP ?
– Maicake Sep 18 '20 at 12:27