Commit 5f8f8e5
authored
fix(cookies): allow more characters in cookie names, as defined by more recent RFCs (#490)
Python's http.cookies library is very strict, and throws an
exception when a cookie-name violates older RFC definitions of
the name. This is reflected back as a 500. But the user has no
indication that he was the cause of it.
More recent RFCs seem to allow for more characters, which is also
reflected in the http.cookies library, but not used. So switch to
that more relaxed definition of valid cookie name.
Still, illegal names should not return 500 in aiohttp, but that
is a problem for another time.1 parent 5943a8f commit 5f8f8e5
1 file changed
+15
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
| 9 | + | |
8 | 10 | | |
9 | 11 | | |
10 | 12 | | |
| |||
58 | 60 | | |
59 | 61 | | |
60 | 62 | | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
61 | 76 | | |
62 | 77 | | |
63 | 78 | | |
| |||
0 commit comments