Skip to content

Fix Multiple Cookie Issue: Properly Handle Multiple Set-Cookie Headers in ZitiUrlProtocol #283

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Dicky019
Copy link

This PR addresses an issue where multiple Set-Cookie headers in HTTP responses were not handled correctly by ZitiUrlProtocol. Previously, only one cookie would be processed, causing potential loss of additional cookies set by the server.

Key improvements:

  • Correctly parses and collects all Set-Cookie headers from HTTP responses.
  • Merges all cookie values into a single entry in the resulting dictionary, ensuring no cookies are missed.
  • Resolves issues with authentication, session management, or any functionality relying on multiple cookies.

This fix improves compatibility with servers that set multiple cookies and ensures more reliable client behavior.
Please review and let me know if further changes are needed. Thank you!

Copy link
Member

@scareything scareything left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi and thanks for the PR! It looks good to me. Can you please sign a contributor license agreement if you haven't already?

@Dicky019
Copy link
Author

Hi and thanks for the PR! It looks good to me. Can you please sign a contributor license agreement if you haven't already?

Hi! Thanks a lot for checking it out 😊
Sure, I’ll go ahead and sign the CLA — will send it over shortly!

Let me know if there’s anything else I should do 🙌

@Dicky019
Copy link
Author

Dicky019 commented Jul 14, 2025

Hi and thanks for the PR! It looks good to me. Can you please sign a contributor license agreement if you haven't already?

Hey, thanks for the reminder!
I’ve just sent the signed Individual Contributor License Agreement over to  [email protected]

Let me know if there’s anything else you need!

@scareything
Copy link
Member

Thanks for the cla. We have it. I just noticed that your commit on this PR is not signed, and we require signed commits. Could you please set up commit signing described here and amend your existing commit, then force-push?

@Dicky019
Copy link
Author

Thanks for the cla. We have it. I just noticed that your commit on this PR is not signed, and we require signed commits. Could you please set up commit signing described here and amend your existing commit, then force-push?

Hi there, thanks for the heads‑up! I’ll configure commit signing as described, amend the existing commit with a GPG signature, and force‑push the branch shortly. Let me know if you need anything else!

@Dicky019 Dicky019 force-pushed the fix/header-set-cookie branch from 1f798c7 to a7bf075 Compare July 18, 2025 07:34
…o handle multiple Set-Cookie headers. Collect all Set-Cookie values into a single entry in the resulting dictionary.
@Dicky019 Dicky019 force-pushed the fix/header-set-cookie branch from a7bf075 to ba7d970 Compare July 18, 2025 12:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants