Setting the secure attribute of the cookie when using HTTPS