Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
814 views
in Technique[技术] by (71.8m points)

chrome cookie size limit

I'm writing into a session cookie from my plugin in chrome. The browser seems to have a strict limit of 4kb for cookie size. It doesnt seem the case in firefox. Is there anyway i can increase the cookie size limit in chrome?

Thanks

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

According to RFC 1012 cookie size must not be limited by user agent. But the minimum capabilities of a browser or user agent should be at least 4096 bytes per cookie. This limit is applied to the name=value portion of the cookie only.

So some browsers can support longer cookies as well. List :

  1. Internet Explorer 8 allowed cookies up to 4095 bytes
  2. Chrome 9 allowed cookies up to 4096 bytes
  3. Opera 11 allowed cookies up to 4096 bytes
  4. Safari 5 allowed coookies up to 4097 bytes
  5. Firefox 3.6.3 allowed cookies up to 4097 bytes

Source of Answer : http://webdesign.about.com/od/cookies/f/web-cookies-size-limit.htm


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...