New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cookie duplication #104
Comments
Thanks for the report. I'll see what I can do. |
FYI -- I'm working on this right now. On Mon, Apr 1, 2013 at 10:16 PM, Jason Kay notifications@github.com wrote:
|
Thank you, Patrick 😎 |
Hi,
browsermob-proxy (with the latest git revision) is presently duplicating cookies in some cases.
You can test this like so:
After much digging around I found that the RequestAddCookies Interceptor was adding cookies from the CookieStore to the request headers even though the Cookies header for those cookies existed. It also decides that the cookies are of version 0 and thus it adds a Cookies2 version header even though Cookies2 was obsoleted by RFC-6265.
I didn't bother to look around to see if the Cookies header was supposed to have been removed at some point, I just disabled the RequestAddCookies interceptor by adding
to the BrowserMobHttpClient constructor. This ruins the cookie parsing that RequestCookiesInterceptor is attempting to do, but I'd rather have unparsed cookies in my hars than be duplicating cookie headers. This issue was rather hard to track down because it only affected one client who has a .NET backend which deals with duplicate cookies by joining them with a comma. 😣
The text was updated successfully, but these errors were encountered: