- new version 2.51
This commit is contained in:
parent
80a7583e23
commit
fa07928015
@ -1 +1 @@
|
||||
dnsmasq-2.48.tar.lzma
|
||||
dnsmasq-2.51.tar.lzma
|
||||
|
@ -1,69 +0,0 @@
|
||||
diff -up dnsmasq-2.48/src/tftp.c.tftp-server-vulnerabilities dnsmasq-2.48/src/tftp.c
|
||||
--- dnsmasq-2.48/src/tftp.c.tftp-server-vulnerabilities 2009-10-05 11:15:10.104555320 +0100
|
||||
+++ dnsmasq-2.48/src/tftp.c 2009-10-05 11:15:12.104564277 +0100
|
||||
@@ -192,20 +192,21 @@ void tftp_request(struct listener *liste
|
||||
|
||||
while ((opt = next(&p, end)))
|
||||
{
|
||||
- if (strcasecmp(opt, "blksize") == 0 &&
|
||||
- (opt = next(&p, end)) &&
|
||||
- !(daemon->options & OPT_TFTP_NOBLOCK))
|
||||
+ if (strcasecmp(opt, "blksize") == 0)
|
||||
{
|
||||
- transfer->blocksize = atoi(opt);
|
||||
- if (transfer->blocksize < 1)
|
||||
- transfer->blocksize = 1;
|
||||
- if (transfer->blocksize > (unsigned)daemon->packet_buff_sz - 4)
|
||||
- transfer->blocksize = (unsigned)daemon->packet_buff_sz - 4;
|
||||
- transfer->opt_blocksize = 1;
|
||||
- transfer->block = 0;
|
||||
+ if ((opt = next(&p, end)) &&
|
||||
+ !(daemon->options & OPT_TFTP_NOBLOCK))
|
||||
+ {
|
||||
+ transfer->blocksize = atoi(opt);
|
||||
+ if (transfer->blocksize < 1)
|
||||
+ transfer->blocksize = 1;
|
||||
+ if (transfer->blocksize > (unsigned)daemon->packet_buff_sz - 4)
|
||||
+ transfer->blocksize = (unsigned)daemon->packet_buff_sz - 4;
|
||||
+ transfer->opt_blocksize = 1;
|
||||
+ transfer->block = 0;
|
||||
+ }
|
||||
}
|
||||
-
|
||||
- if (strcasecmp(opt, "tsize") == 0 && next(&p, end) && !transfer->netascii)
|
||||
+ else if (strcasecmp(opt, "tsize") == 0 && next(&p, end) && !transfer->netascii)
|
||||
{
|
||||
transfer->opt_transize = 1;
|
||||
transfer->block = 0;
|
||||
@@ -217,17 +218,17 @@ void tftp_request(struct listener *liste
|
||||
{
|
||||
if (daemon->tftp_prefix[0] == '/')
|
||||
daemon->namebuff[0] = 0;
|
||||
- strncat(daemon->namebuff, daemon->tftp_prefix, MAXDNAME);
|
||||
+ strncat(daemon->namebuff, daemon->tftp_prefix, (MAXDNAME-1) - strlen(daemon->namebuff));
|
||||
if (daemon->tftp_prefix[strlen(daemon->tftp_prefix)-1] != '/')
|
||||
- strncat(daemon->namebuff, "/", MAXDNAME);
|
||||
+ strncat(daemon->namebuff, "/", (MAXDNAME-1) - strlen(daemon->namebuff));
|
||||
|
||||
if (daemon->options & OPT_TFTP_APREF)
|
||||
{
|
||||
size_t oldlen = strlen(daemon->namebuff);
|
||||
struct stat statbuf;
|
||||
|
||||
- strncat(daemon->namebuff, inet_ntoa(peer.sin_addr), MAXDNAME);
|
||||
- strncat(daemon->namebuff, "/", MAXDNAME);
|
||||
+ strncat(daemon->namebuff, inet_ntoa(peer.sin_addr), (MAXDNAME-1) - strlen(daemon->namebuff));
|
||||
+ strncat(daemon->namebuff, "/", (MAXDNAME-1) - strlen(daemon->namebuff));
|
||||
|
||||
/* remove unique-directory if it doesn't exist */
|
||||
if (stat(daemon->namebuff, &statbuf) == -1 || !S_ISDIR(statbuf.st_mode))
|
||||
@@ -245,8 +246,7 @@ void tftp_request(struct listener *liste
|
||||
}
|
||||
else if (filename[0] == '/')
|
||||
daemon->namebuff[0] = 0;
|
||||
- strncat(daemon->namebuff, filename, MAXDNAME);
|
||||
- daemon->namebuff[MAXDNAME-1] = 0;
|
||||
+ strncat(daemon->namebuff, filename, (MAXDNAME-1) - strlen(daemon->namebuff));
|
||||
|
||||
/* check permissions and open file */
|
||||
if ((transfer->file = check_tftp_fileperm(&len)))
|
@ -10,8 +10,8 @@
|
||||
%endif
|
||||
|
||||
Name: dnsmasq
|
||||
Version: 2.48
|
||||
Release: 5%{?extraversion}%{?dist}
|
||||
Version: 2.51
|
||||
Release: 1%{?extraversion}%{?dist}
|
||||
Summary: A lightweight DHCP/caching DNS server
|
||||
|
||||
Group: System Environment/Daemons
|
||||
@ -19,7 +19,6 @@ License: GPLv2 or GPLv3
|
||||
URL: http://www.thekelleys.org.uk/dnsmasq/
|
||||
Source0: http://www.thekelleys.org.uk/dnsmasq/%{?extrapath}%{name}-%{version}%{?extraversion}.tar.lzma
|
||||
Source1: %{name}.init
|
||||
Patch2: %{name}-2.48-tftp-server-vulnerabilities.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
|
||||
BuildRequires: dbus-devel
|
||||
@ -56,7 +55,6 @@ sed -i 's|/* #define HAVE_DBUS */|#define HAVE_DBUS|g' src/config.h
|
||||
#enable /etc/dnsmasq.d fix bz 526703
|
||||
sed -i 's|#conf-dir=/etc/dnsmasq.d|conf-dir=/etc/dnsmasq.d|g' dnsmasq.conf.example
|
||||
|
||||
%patch2 -p1
|
||||
|
||||
%build
|
||||
make %{?_smp_mflags}
|
||||
@ -120,11 +118,12 @@ fi
|
||||
|
||||
|
||||
%changelog
|
||||
* Sat Oct 17 2009 Itamar Reis Peixoto <itamar@ispbrasil.com.br> - 2.48-5
|
||||
* Sat Oct 17 2009 Itamar Reis Peixoto <itamar@ispbrasil.com.br> - 2.51-1
|
||||
- move initscript from patch to a plain text file
|
||||
- drop (dnsmasq-configuration.patch) and use sed instead
|
||||
- enable /etc/dnsmasq.d fix bz 526703
|
||||
- change requires to package name instead of file
|
||||
- new version 2.51
|
||||
|
||||
* Mon Oct 5 2009 Mark McLoughlin <markmc@redhat.com> - 2.48-4
|
||||
- Fix multiple TFTP server vulnerabilities (CVE-2009-2957, CVE-2009-2958)
|
||||
|
1
import.log
Normal file
1
import.log
Normal file
@ -0,0 +1 @@
|
||||
dnsmasq-2_51-1_fc12:HEAD:dnsmasq-2.51-1.fc12.src.rpm:1255825544
|
Loading…
Reference in New Issue
Block a user