A cookie header was received that contained an invalid cookie. : <p>I am <strong>migrating</strong> my Server from <strong>Tomcat-6</strong> to <strong>Tomcat-9</strong>. My website is designed for the protocol of HTTP/1.1 . The server.xml file contains the Connector Protocol of <strong>org.apache.coyote.http11.Http11NioProtocol</strong> . The server starts up normally without generating any errors. However, when I try to access my website using localhost, I get the following error :-</p>

<p>INFO [https-nio-8445-exec-3] <strong>org.apache.tomcat.util.http.parser.Cookie.logInvalidHeader</strong> A cookie header was received [ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 21, 22, 23]; userId=53136] that contained an invalid cookie. That cookie will be ignored.Note: further occurrences of this error will be logged at DEBUG level.  </p>

<p>Can anyone please tell me the reason for this error?
What causes an invalid cookie?
Can this error be avoided if I use a different connector?</p>
