| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
| |
(cherry picked from commit 030345c0bfc2f76684666fe5c61e766ba5debfe6)
Co-authored-by: Takuya Akiba <469803+iwiwi@users.noreply.github.com>
|
| |
|
|
|
|
| |
handling fixes. (GH-6318)
This change generally splits the xmlparser creation code into an unsafe part with "rollback" error handling and a safe "object initialisation done" part with normal decref cleanup.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
LibreSSL 2.7 introduced OpenSSL 1.1.0 API. The ssl module now detects
LibreSSL 2.7 and only provides API shims for OpenSSL < 1.1.0 and
LibreSSL < 2.7.
Documentation updates and fixes for failing tests will be provided in
another patch set.
Signed-off-by: Christian Heimes <christian@python.org>.
(cherry picked from commit 4ca0739c9d97ac7cd45499e0d31be68dc659d0e1)
Co-authored-by: Christian Heimes <christian@python.org>
|
| |
|
|
| |
executing user code) with a live exception set. (GH-3992)
|
| |
|
|
|
| |
(cherry picked from commit 9308dea3e1fd565d50a76a667e4e8ef0568b7053)
Co-authored-by: Zackery Spytz <zspytz@gmail.com>
|
| |
|
|
|
|
| |
(cherry picked from commit 3e197c7a6740d564ad52fb7901c07d5ff49460f5)
Co-authored-by: Alexey Izbyshev <izbyshev@users.noreply.github.com>
|
| |
|
|
|
|
| |
Signed-off-by: Christian Heimes <christian@python.org>.
(cherry picked from commit 29eab55309b9f78b79074d26db16a44e7841c639)
Co-authored-by: Christian Heimes <christian@python.org>
|
| |
|
| |
Signed-off-by: Christian Heimes <christian@python.org>
|
| |
|
|
|
|
|
|
|
| |
The ssl module now detects missing NPN support in LibreSSL.
Co-Authored-By: Bernard Spil <brnrd@FreeBSD.org>
Signed-off-by: Christian Heimes <christian@python.org>.
(cherry picked from commit 6cdb7954b0a578d899e4b78b868ea59eef08480a)
Co-authored-by: Christian Heimes <christian@python.org>
|
| |
|
|
|
|
|
|
|
| |
The SSL module no longer sends IP addresses in SNI TLS extension on
platforms with OpenSSL 1.0.2+ or inet_pton.
Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit e9370a47389903bb72badc95032ec84a0ebbf8cc)
Co-authored-by: Christian Heimes <christian@python.org>
|
| |
|
|
|
| |
SSLContext.load_dh_params() now supports non-ASCII path.
Signed-off-by: Christian Heimes <christian@python.org>
|
| |
|
|
|
|
|
|
| |
A closing parentheses was missing.
Signed-off-by: Ngie Cooper <yaneurabeya@gmail.com>
(cherry picked from commit 7745ec4e356ac1f4eaf43b155f4482c20a907d48)
Co-authored-by: ngie-eign <1574099+ngie-eign@users.noreply.github.com>
|
| |
|
|
|
|
|
| |
(#5169)
See https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247(v=vs.85).aspx?f=255&MSPPError=-2147217396#maxpath
Paths that begin with `\\?\` are "extended-length paths".
|
| |
|
| |
(cherry picked from commit 83cb778b4a3f856f2243b0f0d36fefb5c44b388f)
|
| |
|
|
|
|
|
|
| |
In fileio, there were 3 fstat() calls and one lseek() call that did not
release the GIL during the call. This can cause all threads to hang for
unlimited time when using io.FileIO with inaccessible NFS server.
Same issue seen in fileio exists also in fileobject, fixed in the same
way.
|
| |
|
|
|
|
|
| |
address (GH-4235) (GH-4352) (#4355)
on NetBSD and DragonFly BSD.
(cherry picked from commit d3187158c09cf899e9849f335bdff10594209167).
(cherry picked from commit 596286f8f3c8e53ef010d6298464775dc900a515)
|
| |
|
|
| |
object is uninitialized (GH-4333)
|
| | |
|
| |
|
|
|
| |
sqlite3.Cursor.__init__() more than once (GH-3968) (#4302)
(cherry picked from commit e56ab746a965277ffcc4396d8a0902b6e072d049)
|
| |
|
|
|
|
| |
(#4263)
Bug report and patch by Jeroen Demeyer..
(cherry picked from commit f6f90ff079a22b79a58d47b6117cc8a8c7d366f3)
|
| |
|
|
|
| |
(GH-4220) (#4222)
(cherry picked from commit 4f469c096628af730b17798d0ebfd8925bfde836)
|
| |
|
|
| |
8cbf4e10646c3f5b8f0d274c2d7dea5bb6305f57. (#4219)
|
| |
|
| |
(cherry picked from commit 894ebd065e02debf20c0657d26020ecc42b7534f)
|
| |
|
|
|
|
|
|
|
|
|
| |
(#4213)
Modify the code to use ncurses is_pad() instead of checking WINDOW
_flags field. If your platform does not provide the is_pad(), the
existing way that checks the field will be enabled.
Note: This change does not drop support for platforms where do not
have both WINDOW _flags field and is_pad().
(cherry picked from commit 8bc7d63560024681dce9f40445f2877b2987e92c)
|
| |
|
|
|
|
|
| |
(#4202)
* Fix a compilation error on FreeBSD.
* Fix the data attribute size on Mac OS X.
(cherry picked from commit 2298fad5ff907dd48ea0fb5c71fa22334ef28c6b)
|
| |
|
|
|
| |
* Fixed the layout of the kqueue_event structure on OpenBSD and NetBSD.
* Fixed the comparison of the kqueue_event objects..
(cherry picked from commit b9052a0f91d2e83bbc27267247a5920c82b242a3)
|
| |
|
| |
(cherry picked from commit baac01e629d90f63dfde6b5cc433f4bc65c5feeb)
|
| |
|
|
|
|
| |
custom integers. (GH-3947) (#4088)
Bad remainder in divmod() in intermediate calculations caused an assertion failure..
(cherry picked from commit 4ffd4653a7ec9c97775472276cf5e159e2366bb2)
|
| |
|
|
|
|
|
| |
Always pass -1, or INFTIM where defined, to the poll() system call when
a negative timeout is passed to the poll.poll([timeout]) method in the
select module. Various OSes throw an error with arbitrary negative
values..
(cherry picked from commit 6cfa927ceb931ad968b5b03e4a2bffb64a8a0604)
|
| |
|
|
|
| |
(GH-1095). (#3976)
(cherry picked from commit de072100775cc29e6cd93a75466cecbd1086f258)
|
| |
|
|
| |
attr is defined only outside _fields_. (GH-3615) (#3952)
|
| |
|
|
| |
Element.text and Element.tail (GH-3924) (#3950)
|
| |
|
|
|
|
|
| |
Add a new _testcapi._read_null() function to crash Python in a
reliable way on s390x.
On s390x, ctypes.string_at(0) returns an empty string rather than
crashing.
|
| |
|
|
|
|
|
|
| |
split() (GH-3866) (#3876)
when pass a string larger than 2 GiB.
Decrease memory requirements for Tcl's bigmem tests..
(cherry picked from commit 27c623c845dd6e4b8e1782666ca3a956636da266)
|
| |
|
|
| |
the arg has a bad __abs__() method (GH-3596) (#3845)
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
* init commit, with initial tests for from_param and fields __set__ and __get__, and some additions to from_buffer and from_buffer_copy
* added the rest of tests and patches. probably only a first draft.
* removed trailing spaces
* replace ctype with ctypes in error messages
* change back from ctypes instance to ctype instance
(cherry picked from commit 1bea762d9ec823544c530d567330a47f64d93d4f)
|
| |
|
|
|
|
| |
attr is defined only outside _fields_. (GH-3615) (#3780)
(cherry picked from commit 30b61b51e05d2d43e8e2e783b0a9df738535423b)
|
| |
|
|
|
| |
ctypes._CData.__setstate__(), in case of a bad __dict__. (GH-3254). (#3781)
(cherry picked from commit 57c2561c8c5663aef55b00e3f29cba575ff36ccd)
|
| |
|
|
|
| |
(GH-3712) (#3779)
(cherry picked from commit d6238a76c655e0feb13478505220dc9049f1682f)
|
| |
|
|
|
| |
itertools.groupby() iterators. (GH-1557). (#3772)
(cherry picked from commit c740e4fe8a9bc5815dc18c38d7f7600b128c3c51)
|
| |
|
| |
This no-op change makes 2.7 more consistent with 3.x to ease comparison and backports.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bpo-29136: Add TLS 1.3 support
TLS 1.3 introduces a new, distinct set of cipher suites. The TLS 1.3
cipher suites don't overlap with cipher suites from TLS 1.2 and earlier.
Since Python sets its own set of permitted ciphers, TLS 1.3 handshake
will fail as soon as OpenSSL 1.1.1 is released. Let's enable the common
AES-GCM and ChaCha20 suites.
Additionally the flag OP_NO_TLSv1_3 is added. It defaults to 0 (no op) with
OpenSSL prior to 1.1.1. This allows applications to opt-out from TLS 1.3
now.
Signed-off-by: Christian Heimes <christian@python.org>.
(cherry picked from commit cb5b68abdeb1b1d56c581d5b4d647018703d61e3)
|
| |
|
|
| |
Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit 17c9ac9)
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Fix copying of partial characters for UTF-8 input (libexpat bug 115):
https://github.com/libexpat/libexpat/issues/115
(cherry picked from commit 759e30ec47048cb9835c62aaeac48748c8151390)
The standard header stdbool.h is not available
with old Visual Studio compilers
Cherry-picked from libexpat b4b89c2ab0cc5325a41360c25ef9d2ccbe617e5c.
expat: Add artificial scopes in xmltok.c utf8_toUtf8() to fix c89 compilation.
Cherry-picked from libexpat commit e0b290eb3d8f4c4b45137a7d7f4f8db812145bd2
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* bpo-31339: Rewrite time.asctime() and time.ctime()
Backport and adapt the _asctime() function from the master branch to
not depend on the implementation of asctime() and ctime() from the
external C library. This change fixes a bug when Python is run using
the musl C library.
* bound checks for time.asctime()
* bound checks for time.strftime()
|
| | |
| |
| | |
(cherry picked from commit e503ca52889bf66ac502702569e726caa7970299)
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
The ssl and hashlib modules now call OPENSSL_add_all_algorithms_noconf() on
OpenSSL < 1.1.0. The function detects CPU features and enables optimizations
on some CPU architectures such as POWER8. Patch is based on research from
Gustavo Serra Scalet.
Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit c941e62)
|
| | |
| |
| |
| |
| |
| |
| | |
Include sys/sysmacros.h for major(), minor(), and makedev(). GNU C libray
plans to remove the functions from sys/types.h.
Signed-off-by: Christian Heimes <christian@python.org>.
(cherry picked from commit 75b961869a1184895c9d5bf41a57f3c985622662)
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Change NPN detection:
Version breakdown, support disabled (pre-patch/post-patch):
- pre-1.0.1: OPENSSL_NPN_NEGOTIATED will not be defined -> False/False
- 1.0.1 and 1.0.2: OPENSSL_NPN_NEGOTIATED will not be defined ->
False/False
- 1.1.0+: OPENSSL_NPN_NEGOTIATED will be defined and
OPENSSL_NO_NEXTPROTONEG will be defined -> True/False
Version breakdown support enabled (pre-patch/post-patch):
- pre-1.0.1: OPENSSL_NPN_NEGOTIATED will not be defined -> False/False
- 1.0.1 and 1.0.2: OPENSSL_NPN_NEGOTIATED will be defined and
OPENSSL_NO_NEXTPROTONEG will not be defined -> True/True
- 1.1.0+: OPENSSL_NPN_NEGOTIATED will be defined and
OPENSSL_NO_NEXTPROTONEG will not be defined -> True/True
* Refine NPN guard:
- If NPN is disabled, but ALPN is available we need our callback
- Make clinic's ssl behave the same way
This created a working ssl module for me, with NPN disabled and ALPN
enabled for OpenSSL 1.1.0f.
Concerns to address:
The initial commit for NPN support into OpenSSL [1], had the
OPENSSL_NPN_* variables defined inside the OPENSSL_NO_NEXTPROTONEG
guard. The question is if that ever made it into a release.
This would need an ugly hack, something like:
GH-if defined(OPENSSL_NO_NEXTPROTONEG) && \
!defined(OPENSSL_NPN_NEGOTIATED)
GH- define OPENSSL_NPN_UNSUPPORTED 0
GH- define OPENSSL_NPN_NEGOTIATED 1
GH- define OPENSSL_NPN_NO_OVERLAP 2
GH-endif
[1] https://github.com/openssl/openssl/commit/68b33cc5c7.
(cherry picked from commit b2d096bd2a5ff86e53c25d00ee5fa097b36bf1d8)
|