[issue18233] SSLSocket.getpeercertchain()

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
versions:  -Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28165] The 'subprocess' module leaks roughly 4 KiB of memory per call

2016-09-15 Thread Xavion

Changes by Xavion :


Removed file: http://bugs.python.org/file44671/Output.log

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28165] The 'subprocess' module leaks roughly 4 KiB of memory per call

2016-09-15 Thread Xavion

Xavion added the comment:

It's easier to reproduce the issue if you use a timer (rather than a loop).  
The newly attached logfile was generated with the following code fragment.

def fTest() :
check_output("true")
threading.Timer(1, fTest, ()).start()

--
Added file: http://bugs.python.org/file44672/Output.log

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9334] argparse does not accept options taking arguments beginning with dash (regression from optparse)

2016-09-15 Thread Clint Olsen

Clint Olsen added the comment:

Thanks for the suggestion!

It seems to be extremely limited, unfortunately. I don't want option processing 
to cease once I hit this switch.

p=argparse.ArgumentParser()
p.add_argument('--subscipt_args', nargs='...')
#p.add_argument('pos',nargs='*')
p.add_argument('--verbose', action='store_true')

args = p.parse_args('--subscipt_args --foo --bar --baz -- --verbose '.split())

print(args)

usage: test.py [-h] [--subscipt_args ...] [--verbose]
test.py: error: unrecognized arguments: -- --verbose

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28124] Rework SSL module documentation

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17128] OS X system openssl deprecated - installer should build local libssl

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28022] SSL releated deprecation for 3.6

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19500] Add client-side SSL session resumption

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28085] SSL: Add client and server protocols for SSLContext

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18233] SSLSocket.getpeercertchain()

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25852] smtplib's SMTP.connect() should store the server name in ._host for .starttls()

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27629] Cannot create ssl.SSLSocket without existing socket

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16487] Allow ssl certificates to be specified from memory rather than files.

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue23239] SSL match_hostname does not accept IP Address

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue12197] non-blocking SSL write fails if a partial write was issued

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +paul.moore, steve.dower, tim.golden, zach.ware

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20762] SSLSocket.read() not documented

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue12378] smtplib.SMTP_SSL leaks socket connections on SSL error

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue21541] Provide configure option --with-ssl for compilation with custom openssl

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26471] load_verify_locations(cadata) should load AUX ASN.1 to supported trusted certs

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25404] ssl.SSLcontext.load_dh_params() does not handle unicode filenames properly

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20994] Disable TLS Compression

2016-09-15 Thread Christian Heimes

Christian Heimes added the comment:

For 3.6 and 3.7, _ssl__SSLContext_impl() now sets NO_COMPRESSION.

--
assignee:  -> christian.heimes
components: +SSL
versions:  -Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15464] ssl: add set_msg_callback function

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
versions:  -Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18369] X509 cert class for ssl module

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27906] Socket accept exhaustion during high TCP traffic

2016-09-15 Thread STINNER Victor

STINNER Victor added the comment:

> On the asyncio side, with debug turned on, we see nothing.

Hum, I'm concerned by this issue. I would expect that in debug log, a log would 
be emitted. Maybe something like "accept queue saturated! we may probably loose 
incoming connections".

Does someone see a way to log a message in such case? Maybe only in debug mode?

I spent time to make sure that asyncio logs events related to network to try to 
understand what is happening. It's hard to decide which events should be 
logged, because logging everything is likely to flood logs.

For example, _SelectorSocketTransport._read_ready() logs an event for

* "EOF" (when recv() returns an empty string).
* transport pauses reading
* transport resumes reading

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25674] test_ssl (test_algorithms) failures on bolen-ubuntu slaves: sha256.tbs-internet.com unknown host

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27850] Remove 3DES from cipher list (sweet32 CVE-2016-2183)

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25115] SSL_set_verify_depth not exposed by the ssl module

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19084] No way to use TLS-PSK from python ssl

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24516] SSL create_default_socket purpose insufficiently documented

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24334] SSLSocket extra level of indirection

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue23588] Errno conflicts in ssl.SSLError

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue11943] Add TLS-SRP (RFC 5054) support to ssl, _ssl, http, and urllib

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue23033] Disallow support for a*.example.net, *a.example.net, and a*b.example.net in certificate wildcard handling.

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
versions:  -Python 3.5, Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17123] Add OCSP support to ssl module

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27766] Add ChaCha20 Poly1305 to SSL ciphers

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26970] Replace OpenSSL's CPRNG with system entropy source

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue21649] Mention "Recommendations for Secure Use of TLS and DTLS"

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22365] SSLContext.load_verify_locations(cadata) does not accept CRLs

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27876] Add SSLContext.set_version_range(minver, maxver=None)

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27768] ssl: get CPU cap flags for AESNI and PCLMULQDQ

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18617] TLS and Intermediate Certificates

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL
versions:  -Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18880] ssl.SSLSocket shutdown doesn't behave like socket.shutdown

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27995] Upgrade Python 3.4 to OpenSSL 1.0.2h on Windows

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13403] Option for XMLPRC Server to support HTTPS

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27815] Make SSL suppress_ragged_eofs default more secure

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15670] PEP 3121, 384 Refactoring applied to ssl module

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
versions:  -Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26867] test_ssl test_options fails on ubuntu 16.04

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27391] server_hostname should only be required when checking host names

2016-09-15 Thread Christian Heimes

Christian Heimes added the comment:

server_hostname is also required for SNI (server name indicator). Virtual 
hosting depends on the feature. Without SNI TLS extension you'll end up on the 
wrong vhost or the web server sends you the wrong certificate.

The feature is pretty much required these days.

--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes
versions: +Python 3.7 -Python 3.3, Python 3.4

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue23749] asyncio missing wrap_socket (starttls)

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes
versions: +Python 3.6, Python 3.7 -Python 3.4

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27354] SSLContext.load_verify_locations cannot handle paths on Windows which cannot be encoded using mbcs

2016-09-15 Thread Christian Heimes

Christian Heimes added the comment:

Is this still an issue?

--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes
stage:  -> needs patch
type:  -> behavior
versions: +Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20916] ssl.enum_certificates() will not return all certificates trusted by Windows

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes
versions: +Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27340] bytes-like objects with socket.sendall(), SSL, and http.client

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
components: +SSL
stage:  -> needs patch
type:  -> behavior
versions: +Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18546] ssl.get_server_certificate like addition for cert chain

2016-09-15 Thread Christian Heimes

Christian Heimes added the comment:

I'm closing the ticket as duplicate of #18233

--
assignee:  -> christian.heimes
components: +SSL
resolution:  -> duplicate
stage: needs patch -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28166] WindowsConsoleIO misbehavior when Ctrl+C is ignored

2016-09-15 Thread Eryk Sun

New submission from Eryk Sun:

_PyOS_WindowsConsoleReadline should continue to read when interrupted by Ctrl+C 
if SIGINT is ignored or the handler doesn't raise an exception. Currently it 
breaks out of the read loop, which looks like an EOF:

>>> import signal
>>> signal.signal(signal.SIGINT, signal.SIG_IGN)

>>> input()
Traceback (most recent call last):
  File "", line 1, in 
EOFError 

Also, in this case Ctrl+C quits the REPL. 

Similarly sys.stdin.buffer.raw should retry a read. Instead a read(1) returns 
an empty string and readall() raises an exception:

>>> sys.stdin.buffer.raw.read(1)
b''

>>> sys.stdin.buffer.raw.read()
Traceback (most recent call last):
  File "", line 1, in 
OSError: [WinError 87] The parameter is incorrect

--
components: IO, Library (Lib), Windows
messages: 276530
nosy: eryksun, paul.moore, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
stage: test needed
status: open
title: WindowsConsoleIO misbehavior when Ctrl+C is ignored
type: behavior
versions: Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18293] ssl.wrap_socket (cert_reqs=...), getpeercert, and unvalidated certificates

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
versions: +Python 3.7 -Python 3.5

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26612] test_ssl: use context manager (with) to fix ResourceWarning

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26815] SIGBUS in test_ssl.test_dealloc_warn() on "AMD64 FreeBSD 10.0 3.x" buildbot

2016-09-15 Thread Christian Heimes

Christian Heimes added the comment:

Does the test still crash? I haven't seen a crasher for a while.

--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes
status: open -> pending
versions: +Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25292] ssl socket gets into broken state when client exits during handshake

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes
type:  -> behavior
versions: +Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26254] ssl should raise an exception when trying to load an unusable key (ECC key not using a named curve)

2016-09-15 Thread Christian Heimes

Christian Heimes added the comment:

The SSL module uses SSL_CTX_check_private_key() to verify the private key. 
Further validations are up to OpenSSL or you.

--
assignee:  -> christian.heimes
components: +SSL
nosy: +christian.heimes
resolution:  -> rejected
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22559] [backport] ssl.MemoryBIO

2016-09-15 Thread Christian Heimes

Changes by Christian Heimes :


--
assignee:  -> christian.heimes
components: +Extension Modules, SSL
type:  -> enhancement

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15670] PEP 3121, 384 Refactoring applied to ssl module

2016-09-15 Thread Giampaolo Rodola'

Changes by Giampaolo Rodola' :


--
nosy:  -giampaolo.rodola

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27768] ssl: get CPU cap flags for AESNI and PCLMULQDQ

2016-09-15 Thread Giampaolo Rodola'

Changes by Giampaolo Rodola' :


--
nosy:  -giampaolo.rodola

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27876] Add SSLContext.set_version_range(minver, maxver=None)

2016-09-15 Thread Giampaolo Rodola'

Changes by Giampaolo Rodola' :


--
nosy:  -giampaolo.rodola

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28123] _PyDict_GetItem_KnownHash ignores DKIX_ERROR return

2016-09-15 Thread STINNER Victor

STINNER Victor added the comment:

If __eq__() raise an exception, _PyDict_GetItem_KnownHash() currently returns 
NULL and pass through the exception. To me, it looks like the correct behaviour.

With your patch, it looks like the _PyDict_GetItem_KnownHash() clears the 
__eq__() exception: return NULL with no exception set, as if the key is simply 
missing.

PyDict_GetItem() ignores *almost* all exceptions, but for bad reasons:

/* Note that, for historical reasons, PyDict_GetItem() suppresses all errors
 * that may occur (originally dicts supported only string keys, and exceptions
 * weren't possible).  (...) */

I would prefer to not ignore __eq__ exceptions, but pass them through.

To be clear: this is a behaviour change compared to Python 3.5 which works as 
PyDict_GetItem(), ignore *all* exceptions:

ep = (mp->ma_keys->dk_lookup)(mp, key, hash, &value_addr);
if (ep == NULL) {
PyErr_Clear();
return NULL;
}

I consider that it's ok to change _PyDict_GetItem_KnownHash() behaviour because 
this function is private and only used 4 times in 250k lines of C code.

Would you be interested to write a different patch to pass through the 
exception?

Note: It seems like _count_elements() (Modules/_collectionsmodule.c) doesn't 
handle correctly such error.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28165] The 'subprocess' module leaks roughly 4 KiB of memory per call

2016-09-15 Thread Florian Bruhin

Changes by Florian Bruhin :


--
nosy: +The Compiler

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13403] Option for XMLPRC Server to support HTTPS

2016-09-15 Thread Petri Lehtinen

Changes by Petri Lehtinen :


--
nosy:  -petri.lehtinen

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27354] SSLContext.load_verify_locations cannot handle paths on Windows which cannot be encoded using mbcs

2016-09-15 Thread STINNER Victor

STINNER Victor added the comment:

> Is this still an issue?

I'm not 100% sure that SSL_CTX_load_verify_locations() accepts a path encoded 
to UTF-8 on Windows.


To be 100% sure, it's "simple": try a filename not encoded to the ANSI code 
page on Windows.

The best would be to have an unit test for that. You use use 
test.support.TESTFN_UNENCODABLE for example.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26815] SIGBUS in test_ssl.test_dealloc_warn() on "AMD64 FreeBSD 10.0 3.x" buildbot

2016-09-15 Thread STINNER Victor

STINNER Victor added the comment:

Maybe the bug was fixed indirectly, maybe we missed a recent failure. Anyway, 
since this issue doesn't contain any useful information and I didn't see the 
failure recently, I decide to close it.

--
resolution:  -> out of date
status: pending -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15369] pybench and test.pystone poorly documented

2016-09-15 Thread Marc-Andre Lemburg

Marc-Andre Lemburg added the comment:

On 14.09.2016 15:20, STINNER Victor wrote:
> 
> STINNER Victor added the comment:
> 
>> I'd also like to request that you reword this dismissive line in the 
>> performance package's readme: (...)
> 
> Please report issues of the performance module on its own bug tracker:
> https://github.com/python/performance
> 
> Can you please propose a new description? You might even create a pull
> request ;-)

I'll send a PR.

> Note: I'm not sure that we should keep pybench, this benchmark really
> looks unreliable. But I should still try at least to use the same
> number of iterations for all worker child processes. Currently the
> calibration is done in each child process.

Well, pybench is not just one benchmark, it's a whole collection of
benchmarks for various different aspects of the CPython VM and per
concept it tries to calibrate itself per benchmark, since each
benchmark has different overhead.

The number of iterations per benchmark will not change between
runs, since this number is fixed in each benchmark. These numbers
do need an update, though, since at the time of writing pybench
CPUs were a lot less powerful compare to today.

Here's the comment with the guideline for the number of rounds
to use per benchmark:

# Number of rounds to execute per test run. This should be
# adjusted to a figure that results in a test run-time of between
# 1-2 seconds.
rounds = 10

BTW: Why would you want to run benchmarks in child processes
and in parallel ? This will usually dramatically effect the
results of the benchmark runs. Ideally, the pybench process
should be the only CPU intense work load on the entire CPU
to get reasonable results.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15369] pybench and test.pystone poorly documented

2016-09-15 Thread STINNER Victor

STINNER Victor added the comment:

Hum, since the discussion restarted, I reopen the issue ...

"Well, pybench is not just one benchmark, it's a whole collection of benchmarks 
for various different aspects of the CPython VM and per concept it tries to 
calibrate itself per benchmark, since each benchmark has different overhead."

In the performance module, you now get individual timing for each pybench 
benchmark, instead of an overall total which was less useful.


"The number of iterations per benchmark will not change between runs, since 
this number is fixed in each benchmark."

Please take a look at the new performance module, it has a different design. 
Calibration is based on minimum time per sample, no more on hardcoded things. I 
modified all benchmarks, not only pybench.


"BTW: Why would you want to run benchmarks in child processes and in parallel ?"

Child processes are run sequentially.

Running benchmarks in multiple processes help to get more reliable benchmarks. 
Read my article if you want to learn more about the design of my perf module:
http://haypo-notes.readthedocs.io/microbenchmark.html#my-articles


"Ideally, the pybench process should be the only CPU intense work load on the 
entire CPU to get reasonable results."

The perf module automatically uses isolated CPU. It strongly suggests to use 
this amazing Linux feature to run benchmarks!
https://haypo.github.io/journey-to-stable-benchmark-system.html

I started to write advices to get stable benchmarks:
https://github.com/python/performance#how-to-get-stable-benchmarks

Note: See also the https://mail.python.org/mailman/listinfo/speed mailing list 
;-)

--
resolution: fixed -> 
status: closed -> open

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



Re: [issue15369] pybench and test.pystone poorly documented

2016-09-15 Thread M.-A. Lemburg
On 15.09.2016 11:11, STINNER Victor wrote:
> 
> STINNER Victor added the comment:
> 
> Hum, since the discussion restarted, I reopen the issue ...
> 
> "Well, pybench is not just one benchmark, it's a whole collection of 
> benchmarks for various different aspects of the CPython VM and per concept it 
> tries to calibrate itself per benchmark, since each benchmark has different 
> overhead."
> 
> In the performance module, you now get individual timing for each pybench 
> benchmark, instead of an overall total which was less useful.

pybench had the same intention. It was a design mistake to add an
overall timing to each suite run. The original intention was to
compare each benchmark individually.

Perhaps it would make sense to try to port the individual benchmark
tests in pybench to performance.

> "The number of iterations per benchmark will not change between runs, since 
> this number is fixed in each benchmark."
> 
> Please take a look at the new performance module, it has a different design. 
> Calibration is based on minimum time per sample, no more on hardcoded things. 
> I modified all benchmarks, not only pybench.

I think we are talking about different things here: calibration is
pybench means that you try to determine the overhead of the
outer loop and possible setup code that is needed to run the
the test.

pybench runs a calibration method which has the same
code as the main test, but without the actual operations that you
want to test, in order to determine the timing of the overhead.

It then takes the minimum timing from overhead runs and uses
this as base line for the actual test runs (it subtracts the
overhead timing from the test run results).

This may not be ideal in all cases, but it's the closest
I could get to timing of the test operations at the time.

I'll have a look at what performance does.

> "BTW: Why would you want to run benchmarks in child processes and in parallel 
> ?"
> 
> Child processes are run sequentially.

Ah, ok.

> Running benchmarks in multiple processes help to get more reliable 
> benchmarks. Read my article if you want to learn more about the design of my 
> perf module:
> http://haypo-notes.readthedocs.io/microbenchmark.html#my-articles

Will do, thanks.

> "Ideally, the pybench process should be the only CPU intense work load on the 
> entire CPU to get reasonable results."
> 
> The perf module automatically uses isolated CPU. It strongly suggests to use 
> this amazing Linux feature to run benchmarks!
> https://haypo.github.io/journey-to-stable-benchmark-system.html
> 
> I started to write advices to get stable benchmarks:
> https://github.com/python/performance#how-to-get-stable-benchmarks
> 
> Note: See also the https://mail.python.org/mailman/listinfo/speed mailing 
> list ;-)

I've read some of your blog posts and articles on the subject
and your journey. Interesting stuff, definitely. Benchmarking
these days appears to have gotten harder not simpler compared to
the days of pybench some 19 years ago.

-- 
Marc-Andre Lemburg
eGenix.com

___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28165] The 'subprocess' module leaks roughly 4 KiB of memory per call

2016-09-15 Thread Antti Haapala

Antti Haapala added the comment:

Ahhah, the title should say: subprocess module leaks 4kiB memory **per thread**.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15369] pybench and test.pystone poorly documented

2016-09-15 Thread STINNER Victor

STINNER Victor added the comment:

2016-09-15 11:21 GMT+02:00 Marc-Andre Lemburg :
> I think we are talking about different things here: calibration is
> pybench means that you try to determine the overhead of the
> outer loop and possible setup code that is needed to run the
> the test.
> (...)
> It then takes the minimum timing from overhead runs and uses
> this as base line for the actual test runs (it subtracts the
> overhead timing from the test run results).

Calibration in perf means computing automatically the number of
outer-loops to get a sample of at least 100 ms (default min time).

I simply removed the code to estimate the overhead of the outer loop
in pybench. The reason is this line:

# Get calibration
min_overhead = min(self.overhead_times)

This is no such "minimum timing", it doesn't exist :-) In benchmarks,
you have to work on statistics: use average, standard deviation, etc.

If you badly estimate the minimum overhead, you might get negative
timings, which is not allowed in perf (even zero is an hard error in
perf).

It's not possible to compute *exactly* the "minimum overhead".

Moreover, removing the code to estimate the overhead simplified the code.

> Benchmarking these days appears to have gotten harder not simpler compared to 
> the days of pybench some 19 years ago.

Benchmarking was always a hard problem. Modern hardware (Out of order
CPU, variable CPU frequency, power saving, etc.) problably didn't help
:-)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28167] remove platform.linux_distribution()

2016-09-15 Thread Matthias Klose

New submission from Matthias Klose:

platform.linux_distribution() was deprecated in 3.5, and should be removed.

Can't be kept up to date, see #18872, #19213, #20454, #1180267, plus uncounted 
issues closed as won't fix.

I'm surprised that #26041 removed the removal warnings again after such a long 
discussion.

--
messages: 276541
nosy: berker.peksag, doko, ned.deily
priority: normal
severity: normal
status: open
title: remove platform.linux_distribution()

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28167] remove platform.linux_distribution()

2016-09-15 Thread Chi Hsuan Yen

Changes by Chi Hsuan Yen :


--
nosy: +Chi Hsuan Yen

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28167] remove platform.linux_distribution()

2016-09-15 Thread STINNER Victor

STINNER Victor added the comment:

> platform.linux_distribution() was deprecated in 3.5, and should be removed.

Is it replaced with the distro package?

FYI I reported the issue to pip and it seems like pip now embeds and uses 
distro:

* https://github.com/pypa/pip/issues/3823
* https://github.com/pypa/pip/pull/3906

--
nosy: +haypo

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28167] remove platform.linux_distribution()

2016-09-15 Thread Berker Peksag

Berker Peksag added the comment:

I think the current consensus is to keep old APIs around to make porting from 
Python 2 easier. That's why I opened issue 26041.

See also msg256111 and "Deprecation policy PEP" proposed at 
https://mail.python.org/pipermail/python-committers/2016-January/003706.html

If Marc-Andre (platform module maintainer) and Ned give their +1s, I don't have 
a strong objection against the removal of the function.

Also, it looks like I forgot to remove deprecated-removed directive in 
5d9f961edc30: 
https://docs.python.org/3.6/library/platform.html#platform.linux_distribution

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28168] Use _winapi.WaitForMultipleObjects in Popen.wait()

2016-09-15 Thread Eryk Sun

New submission from Eryk Sun:

On Unix, waiting on an instance of subprocess.Popen in the main thread is 
interruptible by Ctrl+C. On Windows, it currently calls 
_winapi.WaitForSingleObject, which isn't interruptible. It should instead call 
_winapi.WaitForMultipleObjects, which automatically adds the SIGINT event 
object from _PyOS_SigintEvent() when called from the main thread.

--
components: Library (Lib), Windows
messages: 276544
nosy: eryksun, paul.moore, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
stage: needs patch
status: open
title: Use _winapi.WaitForMultipleObjects in Popen.wait()
type: enhancement
versions: Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27973] urllib.urlretrieve() fails on second ftp transfer

2016-09-15 Thread Sohaib Ahmad

Sohaib Ahmad added the comment:

I didn't know that urllib.urlopen() retrieves complete object in case of FTP. 
When getresp() is called for big files (the one in issue26960), RETR command is 
initiated and server returns code 150 which means "standby for another reply" 
and there is where the control got stuck and issue26960 was reported.

This is the end of debug log with the file mentioned in issue26960, after which 
the control got stuck:

*cmd* 'TYPE I'
*put* 'TYPE I\r\n'
*get* '200 Type set to I\r\n'
*resp* '200 Type set to I'
*cmd* 'PASV'
*put* 'PASV\r\n'
*get* '227 Entering Passive Mode (130,133,3,130,207,26).\r\n'
*resp* '227 Entering Passive Mode (130,133,3,130,207,26).'
*cmd* 'RETR ratings.list.gz'
*put* 'RETR ratings.list.gz\r\n'
*get* '150 Opening BINARY mode data connection for ratings.list.gz (12643237 
bytes)\r\n'
*resp* '150 Opening BINARY mode data connection for ratings.list.gz (12643237 
bytes)'

And this is the end of debug log of a very small file transfer over FTP:

*cmd* 'PASV'
*put* 'PASV\r\n'
*get* '227 Entering Passive Mode (130,239,18,165,234,243).\r\n'
*resp* '227 Entering Passive Mode (130,239,18,165,234,243).'
*cmd* 'RETR Contents-udeb-ppc64el.gz'
*put* 'RETR Contents-udeb-ppc64el.gz\r\n'
*get* '150 Opening BINARY mode data connection for Contents-udeb-ppc64el.gz 
(26555 bytes).\r\n'
*resp* '150 Opening BINARY mode data connection for Contents-udeb-ppc64el.gz 
(26555 bytes).'
*get* '226 Transfer complete.\r\n'
*resp* '226 Transfer complete.'

The control returned successfully once FTP returned 2xx.

Please correct me if I am wrong but from the RETR command it looks like it is 
trying the retrieve the whole file in both cases. Is urlopen() supposed to 
retrieve files when called or just get the headers/information etc.?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28168] Use _winapi.WaitForMultipleObjects in Popen.wait()

2016-09-15 Thread Eryk Sun

Eryk Sun added the comment:

This patch makes the trivial change to the Popen.wait() method and also 
modifies _winapi.WaitForMultipleObjects to restart the wait if SIGINT is 
ignored or the handler didn't raise an exception.

--
keywords: +patch
stage: needs patch -> patch review
Added file: http://bugs.python.org/file44673/issue_28168_01.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27482] heap-buffer-overflow on address 0x6250000078ff

2016-09-15 Thread Francisco Couzo

Francisco Couzo added the comment:

I can confirm this bug is also present in 3.7

--
nosy: +franciscouzo
versions: +Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-09-15 Thread Emanuel Barry

Emanuel Barry added the comment:

Besides converting the DeprecationWarning to a Syntax{Error,Warning}, I don't 
see an easy way to include the offending line (or even file). The place in the 
code where the strings are created has no idea *where* they are being defined. 
AIUI, either we special-case this, or we resolve #28028 (but I don't think the 
latter can go in 3.6).

--
assignee: ebarry -> 

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27400] Datetime NoneType after calling Py_Finalize and Py_Initialize

2016-09-15 Thread Roman Evstifeev

Changes by Roman Evstifeev :


--
nosy: +Roman.Evstifeev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28169] shift exponent overflow

2016-09-15 Thread Francisco Couzo

New submission from Francisco Couzo:

Steps to reproduce:
make distclean
LDFLAGS="-lasan -lubsan" CFLAGS="-fsanitize=address -fsanitize=undefined" 
./configure
ASAN_OPTIONS="detect_leaks=0" make
UBSAN_OPTIONS=print_stacktrace=1 
ASAN_OPTIONS="allocator_may_return_null=1:detect_leaks=0" ./python -m 
test.test_ctypes

/home/fran/code/cpython/Modules/_ctypes/cfield.c:580:5: runtime error: shift 
exponent 18446744073709551614 is too large for 32-bit type 'int'
#0 0x7fb4b3d3f6f6 in h_get 
/home/fran/code/cpython/Modules/_ctypes/cfield.c:580
#1 0x6fc95b in _PyObject_GenericGetAttrWithDict Objects/object.c:1060
#2 0x6fc95b in PyObject_GenericGetAttr Objects/object.c:1121
#3 0x9330a0 in builtin_getattr Python/bltinmodule.c:985
#4 0x6e7d20 in _PyCFunction_FastCallDict Objects/methodobject.c:234
#5 0x6e7d20 in _PyCFunction_FastCallKeywords Objects/methodobject.c:295
#6 0x944cfc in call_function Python/ceval.c:4763
#7 0x95a0f4 in _PyEval_EvalFrameDefault Python/ceval.c:3250
#8 0x9407f0 in PyEval_EvalFrameEx Python/ceval.c:718
#9 0x9407f0 in _PyFunction_FastCall Python/ceval.c:4845
#10 0x945235 in fast_function Python/ceval.c:4880
#11 0x945235 in call_function Python/ceval.c:4784
#12 0x95a0f4 in _PyEval_EvalFrameDefault Python/ceval.c:3250
#13 0x94292f in PyEval_EvalFrameEx Python/ceval.c:718
#14 0x94292f in _PyEval_EvalCodeWithName Python/ceval.c:4094
#15 0x9780b8 in _PyFunction_FastCallDict Python/ceval.c:4996
#16 0x5132d7 in _PyObject_FastCallDict Objects/abstract.c:2297
#17 0x513904 in _PyObject_Call_Prepend Objects/abstract.c:2360
#18 0x5125ba in PyObject_Call Objects/abstract.c:2248
#19 0x957bb0 in do_call_core Python/ceval.c:5032
#20 0x957bb0 in _PyEval_EvalFrameDefault Python/ceval.c:3332
#21 0x94292f in PyEval_EvalFrameEx Python/ceval.c:718
#22 0x94292f in _PyEval_EvalCodeWithName Python/ceval.c:4094
#23 0x9780b8 in _PyFunction_FastCallDict Python/ceval.c:4996
#24 0x5132d7 in _PyObject_FastCallDict Objects/abstract.c:2297
#25 0x513904 in _PyObject_Call_Prepend Objects/abstract.c:2360
#26 0x5125ba in PyObject_Call Objects/abstract.c:2248
#27 0x766761 in slot_tp_call Objects/typeobject.c:6146
#28 0x5130b6 in _PyObject_FastCallDict Objects/abstract.c:2318
#29 0x944103 in call_function Python/ceval.c:4787
#30 0x95a0f4 in _PyEval_EvalFrameDefault Python/ceval.c:3250
#31 0x94292f in PyEval_EvalFrameEx Python/ceval.c:718
#32 0x94292f in _PyEval_EvalCodeWithName Python/ceval.c:4094
#33 0x9780b8 in _PyFunction_FastCallDict Python/ceval.c:4996
#34 0x5132d7 in _PyObject_FastCallDict Objects/abstract.c:2297
#35 0x513904 in _PyObject_Call_Prepend Objects/abstract.c:2360
#36 0x5125ba in PyObject_Call Objects/abstract.c:2248
#37 0x957bb0 in do_call_core Python/ceval.c:5032
#38 0x957bb0 in _PyEval_EvalFrameDefault Python/ceval.c:3332
#39 0x94292f in PyEval_EvalFrameEx Python/ceval.c:718
#40 0x94292f in _PyEval_EvalCodeWithName Python/ceval.c:4094
#41 0x9780b8 in _PyFunction_FastCallDict Python/ceval.c:4996
#42 0x5132d7 in _PyObject_FastCallDict Objects/abstract.c:2297
#43 0x513904 in _PyObject_Call_Prepend Objects/abstract.c:2360
#44 0x5125ba in PyObject_Call Objects/abstract.c:2248
#45 0x766761 in slot_tp_call Objects/typeobject.c:6146
#46 0x5130b6 in _PyObject_FastCallDict Objects/abstract.c:2318
#47 0x944103 in call_function Python/ceval.c:4787
#48 0x95a0f4 in _PyEval_EvalFrameDefault Python/ceval.c:3250
#49 0x94292f in PyEval_EvalFrameEx Python/ceval.c:718
#50 0x94292f in _PyEval_EvalCodeWithName Python/ceval.c:4094
#51 0x9780b8 in _PyFunction_FastCallDict Python/ceval.c:4996
#52 0x5132d7 in _PyObject_FastCallDict Objects/abstract.c:2297
#53 0x513904 in _PyObject_Call_Prepend Objects/abstract.c:2360
#54 0x5125ba in PyObject_Call Objects/abstract.c:2248
#55 0x957bb0 in do_call_core Python/ceval.c:5032
#56 0x957bb0 in _PyEval_EvalFrameDefault Python/ceval.c:3332
#57 0x94292f in PyEval_EvalFrameEx Python/ceval.c:718
#58 0x94292f in _PyEval_EvalCodeWithName Python/ceval.c:4094
#59 0x9780b8 in _PyFunction_FastCallDict Python/ceval.c:4996
#60 0x5132d7 in _PyObject_FastCallDict Objects/abstract.c:2297
#61 0x513904 in _PyObject_Call_Prepend Objects/abstract.c:2360
#62 0x5125ba in PyObject_Call Objects/abstract.c:2248
#63 0x766761 in slot_tp_call Objects/typeobject.c:6146
#64 0x5130b6 in _PyObject_FastCallDict Objects/abstract.c:2318
#65 0x944103 in call_function Python/ceval.c:4787
#66 0x95a0f4 in _PyEval_EvalFrameDefault Python/ceval.c:3250
#67 0x94292f in PyEval_EvalFrameEx Python/ceval.c:718
#68 0x94292f in _PyEval_EvalCodeWithName Python/ceval.c:4094
#69 0x9780b8 in _PyFunction_FastCallDict Python/ceval.c:4996
#70 0x5132d7 in _PyObject_FastCallDict Objects/abstract.c:2297
#71 0x513904 in _PyObject_Call_Prepend Objects/abstract.c:2360
#72

[issue28168] Use _winapi.WaitForMultipleObjects in Popen.wait()

2016-09-15 Thread Eryk Sun

Changes by Eryk Sun :


Added file: http://bugs.python.org/file44674/issue_28168_02.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28169] shift exponent overflow

2016-09-15 Thread Martin Panter

Martin Panter added the comment:

Perhaps this is a dupe of Issue 15119. When I was testing with the sanitizer, 
the only excessive shift error I got was explained by that bug.

--
nosy: +martin.panter

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28137] Windows sys.path file should be renamed

2016-09-15 Thread Wolfgang Langner

Wolfgang Langner added the comment:

If this is only for the use case of embedded distribution we are now only to 
steps away to provide a easy custom shipping of applications for Windows.

1. Take the file name of the executable to load a custom EXECUTABLENAME.path 
file
2. Allow to specify a main to be executed or a pyz zipapp to be run with the -m 
switch. Or simply use first line of the path file if it contains "-m myapp".

With this by only renaming the python.exe and having a simple text file with 
the information, custom applications distribution can be done.

Sorry, I know not directly related to this.

--
nosy: +tds333

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27354] SSLContext.load_verify_locations cannot handle paths on Windows which cannot be encoded using mbcs

2016-09-15 Thread Steve Dower

Steve Dower added the comment:

TESTFN_UNENCODABLE will be invalid utf8 now, as the name is chosen by 
attempting to encode a list of names and using the first one to fail.

No code pages have emoji in them AFAIK, so a test with one of those would do.

ISTR looking at this function though and finding that OpenSSL will decide utf8 
if that's what is passed, in which case we're fine now. Or maybe I'm thinking 
of Tcl...

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28137] Windows sys.path file should be renamed

2016-09-15 Thread Paul Moore

Paul Moore added the comment:

You can actually handle this already, with a simple wrapper program (based on 
the one in PC\WinMain.c):

/* Minimal main program -- everything is loaded from the library. */

#include "Python.h"

#define WIN32_LEAN_AND_MEAN
#include 

int wmain()
{
wchar_t **myargv = malloc((__argc + 3) * sizeof(wchar_t*));
int i;
myargv[0] = __wargv[0];
myargv[1] = L"myapp.zip";
for (i = 1; i < __argc; ++i) {
myargv[1+i] = __wargv[i];
}
myargv[1+i] = 0;
return Py_Main(__argc+1, myargv);
}

This injects your application name "myapp.zip" as the first argument and then 
calls the Python main interpreter. Run this with a conventional embedded 
Python, and you have a standalone application.

You can easily tidy the above sample up (it's just a quick hack) to make it 
generic by working out the name of the zipped Python application from the exe 
name.

But thanks for the idea - I hadn't really thought about doing something like 
this until you prompted me to investigate.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20160] broken ctypes calling convention on MSVC / 64-bit Windows (large structs)

2016-09-15 Thread Rafał Chłodnicki

Rafał Chłodnicki added the comment:

Only a part of this fix was backported to 3.3 branch (in 
http://bugs.python.org/issue20160#msg272059). The other important part was only 
backported to 3.4 and up in http://bugs.python.org/issue20160#msg230723 .

Should this still be fixed?

--
nosy: +Rafał Chłodnicki

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22733] MSVC ffi_prep_args doesn't handle 64-bit arguments properly

2016-09-15 Thread Rafał Chłodnicki

Rafał Chłodnicki added the comment:

Maybe worth backporting to 3.3 and up? Especially if #20160 is to be backported 
as they seem to be related.

--
nosy: +Rafał Chłodnicki

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20160] broken ctypes calling convention on MSVC / 64-bit Windows (large structs)

2016-09-15 Thread Christian Heimes

Christian Heimes added the comment:

3.3 no longer receives any updates, neither security nor feature updates. 3.3.7 
was the final release of 3.3.

--
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20160] broken ctypes calling convention on MSVC / 64-bit Windows (large structs)

2016-09-15 Thread Christian Heimes

Christian Heimes added the comment:

Small correction, 3.3 will get security updates until 2017. This bug is clearly 
not a security issue. The patch should not have landed in 3.3 in the first 
patch.

https://www.python.org/dev/peps/pep-0398/#id7

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28138] Windows _sys.path file should allow import site

2016-09-15 Thread Wolfgang Langner

Wolfgang Langner added the comment:

But this is nearly the same as a *.pth file.
Using the same logic and extension then does not confuse more users.

Why not doing the same as with a .pth file?

Using something like a _sys.pth file if it is there it will be used for path 
handling. In all cases on all platforms for interpreter startup.
(if we will have the embedded interpreter on more platforms)

--
nosy: +tds333

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22493] Deprecate the use of flags not at the start of regular expression

2016-09-15 Thread Tim Graham

Tim Graham added the comment:

Could we include the offending pattern in the deprecation message? I'm 
attaching a proposed patch. With that patch I can more easily find the 
offending pattern, whereas before I had no idea:

django/django/urls/resolvers.py:101: DeprecationWarning: Flags not at the start 
of the expression ^(?i)test/2/?$
  compiled_regex = re.compile(regex, re.UNICODE)

--
nosy: +Tim.Graham
Added file: http://bugs.python.org/file44675/better-warning.diff

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-09-15 Thread R. David Murray

R. David Murray added the comment:

Are SyntaxWarnings silent by default?  If not it can't even go into 3.7.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20160] broken ctypes calling convention on MSVC / 64-bit Windows (large structs)

2016-09-15 Thread Vinay Sajip

Vinay Sajip added the comment:

> This bug is clearly not a security issue.

I'm not sure it's all that clear - the bug could cause a crash (observed in 
practice - not theoretical), which perhaps could be exploited. See Steve 
Dower's message msg272008 in this thread. That's why I added the patch in 3.3.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22493] Deprecate the use of flags not at the start of regular expression

2016-09-15 Thread Tim Graham

Tim Graham added the comment:

And on further investigation, I'm not sure how to fix the deprecation warnings 
in Django. We have a urlpattern like this:

  url(r'^(?i)CaseInsensitive/(\w+)', empty_view, name="insensitive"),

The regex string r'^(?i)CaseInsensitive/(\w+)' is later substituted in this 
line in Django's URL resolver as the `pattern`:

if re.search('^%s%s' % (re.escape(_prefix), pattern), candidate_pat % 
candidate_subs, re.UNICODE):

It seems Django would need to extract any flags from `pattern` and put them at 
the start of the '^%s%s' string that's constructed for re.search(). I'm not 
sure if this can be done easily.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28138] Windows _sys.path file should allow import site

2016-09-15 Thread Steve Dower

Steve Dower added the comment:

On issue28137 I agreed with the proposal to rename to EXENAME.pth, but rather 
than supporting all of .pth file's syntax we would abort the process on 
anything we don't like.

Specifically, we'd allow relative paths, absolute paths, blank lines, comments, 
and "import site". (The parsing code is written in C and runs before 
initialization, so we can't exec stuff anyway, but if I had my way I'd ban that 
from .pth files everywhere.)

Supporting this on other platforms requires porting the code to 
Python/getpath.c. I took a quick survey of core devs at the sprints and nobody 
seemed desperate to have it, but it's something that we can add at any time 
since it is tied to build/install (rather than anything you'd write in Python 
code).

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28137] Windows sys.path file should be renamed

2016-09-15 Thread Steve Dower

Steve Dower added the comment:

I like it. Making the name match the exe name should have been obvious, and if 
nobody is opposed to simply aborting on unsupported syntax (i.e. imports other 
than site) I don't actually mind making it .pth.

It's a separate idea, but what if the presence of a __main__.py file caused 
that file to always run and every argument gets passed to that instead? The 
purposes seem separate enough to use two files. And we could implement that 
part easily enough in PC/WinMain.c, as Paul suggests.

Both of these options are fairly aggressive wrt other command line options 
(i.e. how do you specify unbuffered IO? how do you set the hash seed?), but the 
point is really that you wouldn't use them with these options - if you don't 
want to build your own main() function, the defaults should be good enough.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



  1   2   3   >