Setting cookies with the HttpOnly attribute

To set cookies with HttpOnly attribute:

  1. Locate Web.config from [IIS install drive]\wwwroot.
  2. Add the <httpCookies httpOnlyCookies="true" /> tag within <configuration><system.web>.