Class Cookie


  • public class Cookie
    extends java.lang.Object

    Cookie header parser based on RFC6265

    The parsing of cookies using RFC6265 is more relaxed that the specification in the following ways:

    • Values 0x80 to 0xFF are permitted in cookie-octet to support the use of UTF-8 in cookie values as used by HTML 5.
    • For cookies without a value, the '=' is not required after the name as some browsers do not sent it.

    Implementation note:
    This class has been carefully tuned. Before committing any changes, ensure that the TesterCookiePerformance unit test continues to give results within 1% for the old and new parsers.

    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void parseCookie​(byte[] bytes, int offset, int len, ServerCookies serverCookies)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • parseCookie

        public static void parseCookie​(byte[] bytes,
                                       int offset,
                                       int len,
                                       ServerCookies serverCookies)