开发者

Encrypt Cookie in browser

开发者 https://www.devze.com 2023-02-14 01:42 出处:网络
I want to encrypt cookie in browser Please tell me the different ways to do this Thanks开发者_运维百科Your question isn\'t very clear. You should use HTTPS for the connection and set the secure flag

I want to encrypt cookie in browser

Please tell me the different ways to do this

Thanks开发者_运维百科


Your question isn't very clear. You should use HTTPS for the connection and set the secure flag to make sure that the cookie is always sent encrypted. I assume that is what you want to do.

If you're thinking about doing your own encryption in JavaScript then don't do it because you won't get the level of neither security nor performance anywhere near that of SSL/TLS that the browser has already built in.

If you're serious about cookies security then I recommend reading the Secure Cookie Protocol paper by Liu, Kovacs, Huang and Gouda (PDF).


You never encrypt cookies. If you have to then your security model is flawed. You should tell more about the problem you are trying to solve for us to help you better.

EDIT: Why the downvote? Explain when you disagree.

0

精彩评论

暂无评论...
验证码 换一张
取 消