Re: [Python-Dev] surrogatepass - she's a witch, burn 'er! [was: Cleaning up ...]

2014-08-29 Thread M.-A. Lemburg
On 29.08.2014 02:41, Stephen J. Turnbull wrote: In the process of booking up for my other post in this thread, I noticed the 'surrogatepass' handler. Is there a real use case for the 'surrogatepass' error handler? It seems like a horrible break in the abstraction. IMHO, if there's a need,

Re: [Python-Dev] Bytes path related questions for Guido

2014-08-29 Thread Walter Dörwald
On 28 Aug 2014, at 19:54, Glenn Linderman wrote: On 8/28/2014 10:41 AM, R. David Murray wrote: On Thu, 28 Aug 2014 10:15:40 -0700, Glenn Linderman v+pyt...@g.nevcal.com wrote: [...] Also for cases where the data stream is *supposed* to be in a given encoding, but contains undecodable bytes.

Re: [Python-Dev] surrogatepass - she's a witch, burn 'er! [was: Cleaning up ...]

2014-08-29 Thread M.-A. Lemburg
On 29.08.2014 13:22, Isaac Morland wrote: On Fri, 29 Aug 2014, M.-A. Lemburg wrote: On 29.08.2014 02:41, Stephen J. Turnbull wrote: Since Python allows working with lone surrogates in Unicode (they are valid code points) and we're using UTF-8 for marshal, we needed a way to make sure that

Re: [Python-Dev] surrogatepass - she's a witch, burn 'er! [was: Cleaning up ...]

2014-08-29 Thread Isaac Morland
On Fri, 29 Aug 2014, M.-A. Lemburg wrote: On 29.08.2014 02:41, Stephen J. Turnbull wrote: Since Python allows working with lone surrogates in Unicode (they are valid code points) and we're using UTF-8 for marshal, we needed a way to make sure that Python 3 also optionally supports working with

[Python-Dev] Summary of Python tracker Issues

2014-08-29 Thread Python tracker
ACTIVITY SUMMARY (2014-08-22 - 2014-08-29) Python tracker at http://bugs.python.org/ To view or respond to any of the issues listed below, click on the issue. Do NOT respond to this message. Issues counts and deltas: open4638 (+17) closed 29431 (+32) total 34069 (+49) Open issues

[Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Alex Gaynor
Hi all, I've just submitted PEP 476, on enabling certificate validation by default for HTTPS clients in Python. Please have a look and let me know what you think. PEP text follows. Alex --- PEP: 476 Title: Enabling certificate verification by default for stdlib http clients Version:

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread M.-A. Lemburg
On 29.08.2014 21:47, Alex Gaynor wrote: Hi all, I've just submitted PEP 476, on enabling certificate validation by default for HTTPS clients in Python. Please have a look and let me know what you think. PEP text follows. Thanks for the PEP. I think this is generally a good idea, but some

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread David Reid
Alex Gaynor alex.gaynor at gmail.com writes: Hi all, I've just submitted PEP 476, on enabling certificate validation by default for HTTPS clients in Python. Please have a look and let me know what you think. Yes please. The two most commons answers I get to Why did you switch to go? are

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Ethan Furman
On 08/29/2014 01:00 PM, M.-A. Lemburg wrote: On 29.08.2014 21:47, Alex Gaynor wrote: I've just submitted PEP 476, on enabling certificate validation by default for HTTPS clients in Python. Please have a look and let me know what you think. Thanks for the PEP. I think this is generally a good

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Donald Stufft
On Aug 29, 2014, at 4:00 PM, M.-A. Lemburg m...@egenix.com wrote: * choice of trusted certificate: Instead of hard wiring using the system CA roots into Python it would be good to just make this default and permit the user to point Python to a different set of CA roots.

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Donald Stufft
Sorry I was on my phone and didn’t get to fully reply to this. On Aug 29, 2014, at 4:00 PM, M.-A. Lemburg m...@egenix.com wrote: On 29.08.2014 21:47, Alex Gaynor wrote: Hi all, I've just submitted PEP 476, on enabling certificate validation by default for HTTPS clients in Python.

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread R. David Murray
On Fri, 29 Aug 2014 17:11:35 -0400, Donald Stufft don...@stufft.io wrote: Sorry I was on my phone and didn’t get to fully reply to this. On Aug 29, 2014, at 4:00 PM, M.-A. Lemburg m...@egenix.com wrote: * configuration: It would be good to be able to switch this on or off

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Antoine Pitrou
On Fri, 29 Aug 2014 17:11:35 -0400 Donald Stufft don...@stufft.io wrote: Another problem with this is that I don’t think it’s actually possible to do. Python itself isn’t validating the TLS certificates, OpenSSL is doing that. To my knowledge OpenSSL doesn’t have a way to say “please

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread M.-A. Lemburg
On 29.08.2014 23:11, Donald Stufft wrote: Sorry I was on my phone and didn’t get to fully reply to this. On Aug 29, 2014, at 4:00 PM, M.-A. Lemburg m...@egenix.com wrote: On 29.08.2014 21:47, Alex Gaynor wrote: Hi all, I've just submitted PEP 476, on enabling certificate validation by

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Antoine Pitrou
On Fri, 29 Aug 2014 17:42:34 -0400 R. David Murray rdmur...@bitdance.com wrote: Especially if you want an accelerated change, there must be a way to *easily* get back to the previous behavior, or we are going to catch a lot of flack. There may be only 7% of public certs that are problematic,

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Donald Stufft
On Aug 29, 2014, at 5:42 PM, R. David Murray rdmur...@bitdance.com wrote: On Fri, 29 Aug 2014 17:11:35 -0400, Donald Stufft don...@stufft.io wrote: Sorry I was on my phone and didn’t get to fully reply to this. On Aug 29, 2014, at 4:00 PM, M.-A. Lemburg m...@egenix.com wrote: *

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Donald Stufft
On Aug 29, 2014, at 5:58 PM, M.-A. Lemburg m...@egenix.com wrote: On 29.08.2014 23:11, Donald Stufft wrote: Sorry I was on my phone and didn’t get to fully reply to this. On Aug 29, 2014, at 4:00 PM, M.-A. Lemburg m...@egenix.com wrote: On 29.08.2014 21:47, Alex Gaynor wrote: Hi

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Antoine Pitrou
On Fri, 29 Aug 2014 18:08:19 -0400 Donald Stufft don...@stufft.io wrote: Are you sure that's possible ? Python doesn't load the openssl.cnf file and the SSL_CERT_FILE, SSL_CERT_DIR env vars only work for the openssl command line binary, AFAIK. I’m not 100% sure on that. I know they are

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread R. David Murray
On Fri, 29 Aug 2014 18:00:50 -0400, Donald Stufft don...@stufft.io wrote: On Aug 29, 2014, at 5:42 PM, R. David Murray rdmur...@bitdance.com wrote: Especially if you want an accelerated change, there must be a way to *easily* get back to the previous behavior, or we are going to catch a

Re: [Python-Dev] surrogatepass - she's a witch, burn 'er! [was: Cleaning up ...]

2014-08-29 Thread Greg Ewing
M.-A. Lemburg wrote: we needed a way to make sure that Python 3 also optionally supports working with lone surrogates in such UTF-8 streams (nowadays called CESU-8: http://en.wikipedia.org/wiki/CESU-8). I don't think CESU-8 is the same thing. According to the wiki page, CESU-8 *requires* all

Re: [Python-Dev] PEP 476: Enabling certificate validation by default!

2014-08-29 Thread Alex Gaynor
Thanks for the rapid feedback everyone! I want to summarize the action items and discussion points that have come up so far: To add to the PEP: * Emit a warning in 3.4.next for cases that would raise a Exception in 3.5 * Clearly state that the existing OpenSSL environment variables will be

Re: [Python-Dev] surrogatepass - she's a witch, burn 'er!

2014-08-29 Thread Stephen J. Turnbull
Greg Ewing writes: M.-A. Lemburg wrote: we needed a way to make sure that Python 3 also optionally supports working with lone surrogates in such UTF-8 streams (nowadays called CESU-8: http://en.wikipedia.org/wiki/CESU-8). Besides what Greg says, CESU-8 is an UTF, and therefore