Message202996
| Author |
vstinner |
| Recipients |
lemburg, ncoghlan, serhiy.storchaka, vstinner |
| Date |
2013年11月16日.00:47:09 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1384562829.72.0.617857672471.issue19619@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
I propose to add new input_type and output_type to CodecInfo. These attributes would only be defined for base64, hex, ... codecs which are not the classic encode: str=>bytes, decode: bytes=>str codecs.
I also propose to modify str.encode() and bytes.encode() to only accept codecs using the right types. If the type doesn't match, the codec raises a LookupError.
This issue should avoid the denial of service attack when a compression codec is used, see:
https://mail.python.org/pipermail/python-dev/2013-November/130188.html |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2013年11月16日 00:47:09 | vstinner | set | recipients:
+ vstinner, lemburg, ncoghlan, serhiy.storchaka |
| 2013年11月16日 00:47:09 | vstinner | set | messageid: <1384562829.72.0.617857672471.issue19619@psf.upfronthosting.co.za> |
| 2013年11月16日 00:47:09 | vstinner | link | issue19619 messages |
| 2013年11月16日 00:47:09 | vstinner | create |
|