Skip to content

gh-161707: Refuse ; in all cookie attributes except Comment - #161711

Merged
sethmlarson merged 8 commits into
python:mainfrom
brettcs:reject-semicolon-attribute-values
Nov 12, 2026
Merged

sethmlarson merged 8 commits into
python:mainfrom
brettcs:reject-semicolon-attribute-values

Conversation

@brettcs

@brettcs brettcs commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

@read-the-docs-community

read-the-docs-community Bot commented Nov 9, 2026 •

Copy link
Copy Markdown

Documentation build overview

📚 cpython-previews | 🛠️ Build #35814070 | 📁 Comparing 1937b34 against main (78407da)

  🔍 Preview build  

46 files changed · ± 46 modified

± Modified

This makes the API easier to use well: the caller and the validator don't both
have to call `key.lower()`.

@sethmlarson sethmlarson left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Implementation LGTM, one comment on the documentation.

Comment thread Doc/library/http.cookies.rst Resolved
Comment thread Doc/library/http.cookies.rst Resolved
@sethmlarson

Copy link
Copy Markdown
Contributor

@vstinner You reviewed my previous change in this area, could I ask for a second-set of eyes?

@brettcs
brettcs requested a review from orsenthil as a code owner November 10, 2026 20:56

@vstinner vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Mostly LGTM, I have a few minor suggestions.

Comment thread Lib/test/test_http_cookies.py Resolved
Comment thread Lib/test/test_http_cookies.py Resolved
Comment thread Lib/http/cookies.py Resolved
Co-authored-by: Victor Stinner <vstinner@python.org>
@brettcs

brettcs commented Nov 11, 2026

Copy link
Copy Markdown
Contributor Author

All those changes sound good to me, thanks. I've updated the branch.

@orsenthil orsenthil left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM.

Rebase against the main will get CI to green here.

@sethmlarson sethmlarson added the type-security A security issue label Nov 12, 2026

@sethmlarson sethmlarson left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM, thanks! Will merge once CI is all green.

@brettcs

brettcs commented Nov 12, 2026

Copy link
Copy Markdown
Contributor Author

readthedocs CI appears to be stuck. GitHub is waiting for status but the details say it was aborted early for inactivity (?).

@StanFromIreland

Copy link
Copy Markdown
Member

It’s fine to merge, RTD can be flakey like this, but the docs CI passed.

@sethmlarson
sethmlarson merged commit 2702684 into python:main Nov 12, 2026
54 of 55 checks passed

@vstinner vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Post-merge review: LGTM!

@sethmlarson sethmlarson added needs backport to 3.11 only security fixes needs backport to 3.12 only security fixes needs backport to 3.13 only security fixes needs backport to 3.14 bugs and security fixes labels Nov 12, 2026
@sethmlarson sethmlarson added the needs backport to 3.15 bugs and security fixes label Nov 12, 2026
@miss-islington-app

Copy link
Copy Markdown

Thanks @brettcs for the PR, and @sethmlarson for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Thanks @brettcs for the PR, and @sethmlarson for merging it 🌮🎉.. I'm working now to backport this PR to: 3.14.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Thanks @brettcs for the PR, and @sethmlarson for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Thanks @brettcs for the PR, and @sethmlarson for merging it 🌮🎉.. I'm working now to backport this PR to: 3.12.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Thanks @brettcs for the PR, and @sethmlarson for merging it 🌮🎉.. I'm working now to backport this PR to: 3.15.
🐍🍒⛏🤖

@miss-islington-app

Copy link
Copy Markdown

Sorry, @brettcs and @sethmlarson, I could not cleanly backport this to 3.11 due to a conflict.

Please backport manually with cherry_picker, see the devguide for more information.

cherry_picker 27026842f6774c167295f4b59972589f12ec5987 3.11

@miss-islington-app

Copy link
Copy Markdown

Sorry, @brettcs and @sethmlarson, I could not cleanly backport this to 3.12 due to a conflict.

Please backport manually with cherry_picker, see the devguide for more information.

cherry_picker 27026842f6774c167295f4b59972589f12ec5987 3.12

@miss-islington-app

Copy link
Copy Markdown

Sorry, @brettcs and @sethmlarson, I could not cleanly backport this to 3.13 due to a conflict.

Please backport manually with cherry_picker, see the devguide for more information.

cherry_picker 27026842f6774c167295f4b59972589f12ec5987 3.13

@bedevere-app

bedevere-app Bot commented Nov 15, 2026

Copy link
Copy Markdown

GH-161894 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label Nov 15, 2026
@bedevere-app

bedevere-app Bot commented Nov 15, 2026

Copy link
Copy Markdown

GH-161893 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Nov 15, 2026
@bedevere-app

bedevere-app Bot commented Nov 15, 2026

Copy link
Copy Markdown

GH-161901 is a backport of this pull request to the 3.13 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.13 only security fixes label Nov 15, 2026
@bedevere-app

bedevere-app Bot commented Nov 15, 2026

Copy link
Copy Markdown

GH-161902 is a backport of this pull request to the 3.12 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.12 only security fixes label Nov 15, 2026
@bedevere-app

bedevere-app Bot commented Nov 15, 2026

Copy link
Copy Markdown

GH-161903 is a backport of this pull request to the 3.11 branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type-security A security issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants