title: Set cookie version of incoming httpServletRequest
body: <p>I have a client that is sending to me a version 1 cookie with a comma delimite value. This should be ok in version 1 of cookies but not allowed in version 0.</p>
  
  <p>So this it the cookie</p>
  
  <pre><code>test.cookie=1,1
  </code></pre>
  
  <p>Now when I read Cookie[] cookies = request.getCookies[] I am returned 2 cookies like this:</p>
  
  <pre><code>test.cookie=1
  1=
  </code></pre>
  
  <p>So it is seeing the value of the cookie as a delimiter for the next cookie, which you would expect in version 0 of cookies. 
  So the question is can I set the cookie version of the incoming HttpServletRequest before reading the cookies from it.</p>
  
  <p>I know that there is a Cookie.setVersion(int) method but that is no use to me as I am not setting the cookie the container is. <em>(which might be a clue actually to set the cookie version in the container which I will go and look at now)</em></p>
  
  <p><strong>Edit</strong>
  The way I have worked around this is to just read the headers and then read the value of the Cookie header which comes as a semi-colon delimited list and then parse each cookie name value pair myself thus the comma in the value of the cookie is then preserved correctly and I get just the one cookie.  Be nice to know if there is a way of doing this with HttpServleRequest.getCookies() though.</p>