Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
3a976055
Kaydet (Commit)
3a976055
authored
Ara 04, 2005
tarafından
Andrew M. Kuchling
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
[Bug #1222790] Set reuse-address and close-on-exec flags on the HTTP listening socket
üst
cf6b7c99
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
1 deletion
+14
-1
SimpleXMLRPCServer.py
Lib/SimpleXMLRPCServer.py
+11
-1
NEWS
Misc/NEWS
+3
-0
No files found.
Lib/SimpleXMLRPCServer.py
Dosyayı görüntüle @
3a976055
...
@@ -104,7 +104,7 @@ from xmlrpclib import Fault
...
@@ -104,7 +104,7 @@ from xmlrpclib import Fault
import
SocketServer
import
SocketServer
import
BaseHTTPServer
import
BaseHTTPServer
import
sys
import
sys
import
os
import
os
,
fcntl
def
resolve_dotted_attribute
(
obj
,
attr
,
allow_dotted_names
=
True
):
def
resolve_dotted_attribute
(
obj
,
attr
,
allow_dotted_names
=
True
):
"""resolve_dotted_attribute(a, 'b.c.d') => a.b.c.d
"""resolve_dotted_attribute(a, 'b.c.d') => a.b.c.d
...
@@ -465,6 +465,8 @@ class SimpleXMLRPCServer(SocketServer.TCPServer,
...
@@ -465,6 +465,8 @@ class SimpleXMLRPCServer(SocketServer.TCPServer,
from SimpleXMLRPCDispatcher to change this behavior.
from SimpleXMLRPCDispatcher to change this behavior.
"""
"""
allow_reuse_address
=
True
def
__init__
(
self
,
addr
,
requestHandler
=
SimpleXMLRPCRequestHandler
,
def
__init__
(
self
,
addr
,
requestHandler
=
SimpleXMLRPCRequestHandler
,
logRequests
=
1
):
logRequests
=
1
):
self
.
logRequests
=
logRequests
self
.
logRequests
=
logRequests
...
@@ -472,6 +474,14 @@ class SimpleXMLRPCServer(SocketServer.TCPServer,
...
@@ -472,6 +474,14 @@ class SimpleXMLRPCServer(SocketServer.TCPServer,
SimpleXMLRPCDispatcher
.
__init__
(
self
)
SimpleXMLRPCDispatcher
.
__init__
(
self
)
SocketServer
.
TCPServer
.
__init__
(
self
,
addr
,
requestHandler
)
SocketServer
.
TCPServer
.
__init__
(
self
,
addr
,
requestHandler
)
# [Bug #1222790] If possible, set close-on-exec flag; if a
# method spawns a subprocess, the subprocess shouldn't have
# the listening socket open.
if
hasattr
(
fcntl
,
'FD_CLOEXEC'
):
flags
=
fcntl
.
fcntl
(
self
.
fileno
(),
fcntl
.
F_GETFD
)
flags
|=
fcntl
.
FD_CLOEXEC
fcntl
.
fcntl
(
self
.
fileno
(),
fcntl
.
F_SETFD
,
flags
)
class
CGIXMLRPCRequestHandler
(
SimpleXMLRPCDispatcher
):
class
CGIXMLRPCRequestHandler
(
SimpleXMLRPCDispatcher
):
"""Simple handler for XML-RPC data passed through CGI."""
"""Simple handler for XML-RPC data passed through CGI."""
...
...
Misc/NEWS
Dosyayı görüntüle @
3a976055
...
@@ -448,6 +448,9 @@ Library
...
@@ -448,6 +448,9 @@ Library
disables recursive traversal through instance attributes, which can
disables recursive traversal through instance attributes, which can
be exploited in various ways.
be exploited in various ways.
- Bug #1222790: in SimpleXMLRPCServer, set the reuse-address and close-on-exec
flags on the HTTP listening socket.
- Bug #1110478: Revert os.environ.update to do putenv again.
- Bug #1110478: Revert os.environ.update to do putenv again.
- Bug #1103844: fix distutils.install.dump_dirs() with negated options.
- Bug #1103844: fix distutils.install.dump_dirs() with negated options.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment