rpms/fail2ban/devel fail2ban-0.8.2-fd_cloexec.patch, NONE, 1.1 fail2ban.spec, 1.11, 1.12
Axel Thimm (athimm)
fedora-extras-commits at redhat.com
Sun Mar 30 19:29:14 UTC 2008
Author: athimm
Update of /cvs/extras/rpms/fail2ban/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv677/devel
Modified Files:
fail2ban.spec
Added Files:
fail2ban-0.8.2-fd_cloexec.patch
Log Message:
Fix #230191
fail2ban-0.8.2-fd_cloexec.patch:
--- NEW FILE fail2ban-0.8.2-fd_cloexec.patch ---
--- fail2ban-0.8.2/server/filter.py.orig 2008-03-27 16:26:59.000000000 +0000
+++ fail2ban-0.8.2/server/filter.py 2008-03-27 15:29:48.000000000 +0000
@@ -428,6 +428,7 @@
# is computed and compared to the previous hash of this line.
import md5
+import fcntl
class FileContainer:
@@ -455,6 +456,11 @@
def open(self):
self.__handler = open(self.__filename)
+
+ # Set the file descriptor to be FD_CLOEXEC
+ fd = self.__handler.fileno()
+ fcntl.fcntl (self.__handler.fileno(), fcntl.F_SETFD, fd | fcntl.FD_CLOEXEC)
+
firstLine = self.__handler.readline()
# Computes the MD5 of the first line.
myHash = md5.new(firstLine).digest()
Index: fail2ban.spec
===================================================================
RCS file: /cvs/extras/rpms/fail2ban/devel/fail2ban.spec,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- fail2ban.spec 16 Mar 2008 08:03:07 -0000 1.11
+++ fail2ban.spec 30 Mar 2008 19:28:37 -0000 1.12
@@ -4,7 +4,7 @@
Summary: Ban IPs that make too many password failures
Name: fail2ban
Version: 0.8.2
-Release: 13%{?dist}
+Release: 14%{?dist}
License: GPL
Group: System Environment/Daemons
URL: http://fail2ban.sourceforge.net/
@@ -13,6 +13,7 @@
Patch0: fail2ban-0.8.1-init.patch
Patch1: fail2ban-0.8.1-sshd.patch
#Patch2: fail2ban-0.8.1-sock.patch
+Patch3: fail2ban-0.8.2-fd_cloexec.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
BuildRequires: python-devel >= 2.3
BuildArch: noarch
@@ -31,6 +32,7 @@
%patch0 -p1 -b .init
%patch1 -p1 -b .sshd
#patch2 -p1 -b .sock
+%patch3 -p1 -b .fd_cloexec
%build
python setup.py build
@@ -80,6 +82,9 @@
%dir %{_localstatedir}/run/fail2ban
%changelog
+* Thu Mar 27 2008 Axel Thimm <Axel.Thimm at ATrpms.net> - 0.8.2-14
+- Close on exec fixes by Jonathan Underwood.
+
* Sun Mar 16 2008 Axel Thimm <Axel.Thimm at ATrpms.net> - 0.8.2-13
- Add %%{_localstatedir}/run/fail2ban (David Rees).
More information about the fedora-extras-commits
mailing list