[New-bugs-announce] [issue8737] ssl.RAND_add() should only accept bytes (not str)

STINNER Victor report at bugs.python.org
Sun May 16 23:31:24 CEST 2010


New submission from STINNER Victor <victor.stinner at haypocalc.com>:

PySSL_RAND_add() uses PyArg_ParseTuple(args, "s#d:RAND_add", ...) and so converts implicitly str to bytes using UTF-8. I would prefer that this function only accepts bytes: the user will have to encode str to bytes *explicitly*.

Attached patch replace s# format by y# format.

----------
components: Library (Lib)
files: ssl_rand_add_bytes.patch
keywords: patch
messages: 105879
nosy: haypo
priority: normal
severity: normal
status: open
title: ssl.RAND_add() should only accept bytes (not str)
versions: Python 3.2
Added file: http://bugs.python.org/file17371/ssl_rand_add_bytes.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue8737>
_______________________________________


More information about the New-bugs-announce mailing list