In our Network Extension we're trying to use URLSession for setting up a connection using a series of HTTP exchanges.
I see an HTTP response in Wireshark which has multiple
headers, but only the last one shows up in the HTTPURLReponse.
Traffic on the wire:
Value in HTTPURLResponse.allHeaderFields:
No sign of the other cookie values. I've seen comments on the web that the cookies in multiple Set-Cookie headers will be concatenated into a single header, but that's not at all what I'm seeing.
Is there a way to access the other cookie values? If not, how can we use URLSession with an endpoint that will return multiple Set-Cookie headers?
I see an HTTP response in Wireshark which has multiple
Code Block Set-Cookie
headers, but only the last one shows up in the HTTPURLReponse.
Traffic on the wire:
Code Block Set-Cookie: ABC_COOKIE=2000;Path=/;Secure Set-Cookie: XYZ_COOKIE=tuv;Path=/;expires=<somedate>;Secure Set-Cookie: foo=bar;Secure;Path=/;expires=<somedate>
Value in HTTPURLResponse.allHeaderFields:
Code Block "Set-Cookie" = "foo=bar;Secure;Path=/;expires=<somedate>"
No sign of the other cookie values. I've seen comments on the web that the cookies in multiple Set-Cookie headers will be concatenated into a single header, but that's not at all what I'm seeing.
Is there a way to access the other cookie values? If not, how can we use URLSession with an endpoint that will return multiple Set-Cookie headers?