Hacker News new | ask | show | jobs
by areed 3653 days ago
Because you can set Secure and HttpOnly flags on cookies? This merely brings them up to the same level of security you get with Local Storage. http://blog.portswigger.net/2016/05/web-storage-lesser-evil-...
1 comments

What is a "level" of security? If I'm able to inject arbitrary code into your page, with it I can access your local storage data, but I can't access your "http only" cookies - so there's at least some "level" of difference.
If you're at the point where someone can inject random code into your site, you've already lost and have so many more problems than access to localStorage.