- resolves: bug#1055073 (fedora 1055072)

rlm_ippool; bad config file attribute and fails to send reply attributes
- resolves: bug#1055567 (fedora 1056227)
  bad mysql sql syntax
- change CFLAGS -imacros to -include to address gcc/gdb bug 1004526
  where gdb will not display source information, only <command-line>
This commit is contained in:
John Dennis 2014-01-21 13:50:00 -05:00
parent bf50edada9
commit 695482aab2
4 changed files with 149 additions and 1 deletions

13
freeradius-imacros.patch Normal file
View File

@ -0,0 +1,13 @@
diff -r -u freeradius-server-3.0.1.bak/Make.inc.in freeradius-server-3.0.1/Make.inc.in
--- freeradius-server-3.0.1.bak/Make.inc.in 2014-01-17 11:20:48.599733053 -0500
+++ freeradius-server-3.0.1/Make.inc.in 2014-01-17 14:37:33.739853796 -0500
@@ -47,7 +47,7 @@
CC = @CC@
RANLIB = @RANLIB@
-IMACROS = -imacros ${top_srcdir}/src/freeradius-devel/build.h -imacros ${top_srcdir}/src/freeradius-devel/autoconf.h -imacros ${top_srcdir}/src/freeradius-devel/features.h
+IMACROS = -include ${top_srcdir}/src/freeradius-devel/build.h -include ${top_srcdir}/src/freeradius-devel/autoconf.h -include ${top_srcdir}/src/freeradius-devel/features.h
INCLUDE = -I${top_srcdir} -I${top_srcdir}/src
CFLAGS = $(IMACROS) $(INCLUDE) -std=c99 -fno-strict-aliasing @CFLAGS@
CPPFLAGS = @CPPFLAGS@
Only in freeradius-server-3.0.1: Make.inc.in~

109
freeradius-ippool.patch Normal file
View File

@ -0,0 +1,109 @@
diff -r -u freeradius-server-3.0.1.bak/raddb/mods-available/ippool freeradius-server-3.0.1/raddb/mods-available/ippool
--- freeradius-server-3.0.1.bak/raddb/mods-available/ippool 2014-01-17 11:20:48.609733064 -0500
+++ freeradius-server-3.0.1/raddb/mods-available/ippool 2014-01-17 12:33:11.884537885 -0500
@@ -1,6 +1,6 @@
# -*- text -*-
#
-# $Id: d52dc9b385dec10e970ba9af070af612f25d596d $
+# $Id: 1d3305ba45ec71336f55f8f1db05f183772e1b82 $
# Do server side ip pool management. Should be added in
# post-auth and accounting sections.
@@ -22,54 +22,45 @@
# DEFAULT Group == teachers, Pool-Name := "teachers"
# DEFAULT Group == other, Pool-Name := "DEFAULT"
#
-# ********* IF YOU CHANGE THE RANGE PARAMETERS YOU MUST *********
-# ********* THEN ERASE THE DB FILES *********
+# Note: If you change the range parameters you must then erase the
+# db files.
#
ippool main_pool {
+ # The main db file used to allocate addresses.
+ filename = ${db_dir}/db.ippool
- # range-start,range-stop:
- # The start and end ip addresses for this pool.
+ # The start and end ip addresses for this pool.
range_start = 192.0.2.1
range_stop = 192.0.2.254
- # netmask:
- # The network mask used for this pool.
+ # The network mask used for this pool.
netmask = 255.255.255.0
- # cache_size:
- # The gdbm cache size for the db files. Should
- # be equal to the number of ip's available in
- # the ip pool
+ # The gdbm cache size for the db files. Should
+ # be equal to the number of ip's available in
+ # the ip pool
cache_size = 800
- # session-db:
- # The main db file used to allocate addresses.
- session_db = ${db_dir}/db.ippool
-
- # ip-index:
- # Helper db index file used in multilink
+ # Helper db index file used in multilink
ip_index = ${db_dir}/db.ipindex
- # override:
- # If set, the Framed-IP-Address already in the
- # reply (if any) will be discarded, and replaced
- # with a Framed-IP-Address assigned here.
+ # If set, the Framed-IP-Address already in the
+ # reply (if any) will be discarded, and replaced
+ # ith a Framed-IP-Address assigned here.
override = no
- # maximum-timeout:
- # Specifies the maximum time in seconds that an
- # entry may be active. If set to zero, means
- # "no timeout". The default value is 0
+ # Specifies the maximum time in seconds that an
+ # entry may be active. If set to zero, means
+ # "no timeout". The default value is 0
maximum_timeout = 0
- # key:
- # The key to use for the session database (which
- # holds the allocated ip's) normally it should
- # just be the nas ip/port (which is the default).
+ # The key to use for the session database (which
+ # holds the allocated ip's) normally it should
+ # just be the nas ip/port (which is the default).
#
- # If your NAS sends the same value of NAS-Port
- # all requests, the key should be based on some
- # other attribute that is in ALL requests, AND
- # is unique to each machine needing an IP address.
- #key = "%{NAS-IP-Address} %{NAS-Port}"
+ # If your NAS sends the same value of NAS-Port
+ # all requests, the key should be based on some
+ # other attribute that is in ALL requests, AND
+ # is unique to each machine needing an IP address.
+# key = "%{NAS-IP-Address} %{NAS-Port}"
}
commit 82d3d851e03fdc403c6694d5470905c489acb1b5
Author: Alan T. DeKok <aland@freeradius.org>
Date: Sat Jan 18 15:58:28 2014 -0500
Set the default length for the attributes
diff --git a/src/lib/valuepair.c b/src/lib/valuepair.c
index d1d1fca..ac955ad 100644
--- a/src/lib/valuepair.c
+++ b/src/lib/valuepair.c
@@ -109,6 +109,8 @@ VALUE_PAIR *pairalloc(TALLOC_CTX *ctx, DICT_ATTR const *da)
vp->op = T_OP_EQ;
vp->type = VT_NONE;
+ vp->length = da->flags.length;
+
talloc_set_destructor(vp, _pairfree);
return vp;

View File

@ -0,0 +1,12 @@
diff -r -u freeradius-server-3.0.1.orig/raddb/mods-config/sql/main/mysql/schema.sql freeradius-server-3.0.1/raddb/mods-config/sql/main/mysql/schema.sql
--- freeradius-server-3.0.1.orig/raddb/mods-config/sql/main/mysql/schema.sql 2014-01-13 20:13:56.000000000 -0500
+++ freeradius-server-3.0.1/raddb/mods-config/sql/main/mysql/schema.sql 2014-01-21 12:37:29.349480066 -0500
@@ -28,7 +28,7 @@
acctupdatetime datetime NULL default NULL,
acctstoptime datetime NULL default NULL,
acctinterval int(12) default NULL,
- acctsessiontime unsigned int(12) default NULL,
+ acctsessiontime int(12) unsigned default NULL,
acctauthentic varchar(32) default NULL,
connectinfo_start varchar(50) default NULL,
connectinfo_stop varchar(50) default NULL,

View File

@ -1,7 +1,7 @@
Summary: High-performance and highly configurable free RADIUS server
Name: freeradius
Version: 3.0.1
Release: 1%{?dist}
Release: 2%{?dist}
License: GPLv2+ and LGPLv2+
Group: System Environment/Daemons
URL: http://www.freeradius.org/
@ -23,6 +23,9 @@ Source104: freeradius-tmpfiles.conf
Patch1: freeradius-redhat-config.patch
Patch2: freeradius-postgres-sql.patch
Patch3: freeradius-ippool.patch
Patch4: freeradius-imacros.patch
Patch5: freeradius-mysql-schema.patch
%global docdir %{?_pkgdocdir}%{!?_pkgdocdir:%{_docdir}/%{name}-%{version}}
@ -181,6 +184,9 @@ This plugin provides the unixODBC support for the FreeRADIUS server project.
# mistakenly include these files, especially problematic for raddb config files.
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%build
# Force compile/link options, extra security for network facing daemon
@ -742,6 +748,14 @@ exit 0
%{_libdir}/freeradius/rlm_sql_unixodbc.so
%changelog
* Sun Jan 19 2014 John Dennis <jdennis@redhat.com> - 3.0.1-2
- resolves: bug#1055073 (fedora 1055072)
rlm_ippool; bad config file attribute and fails to send reply attributes
- resolves: bug#1055567 (fedora 1056227)
bad mysql sql syntax
- change CFLAGS -imacros to -include to address gcc/gdb bug 1004526
where gdb will not display source information, only <command-line>
* Tue Jan 14 2014 John Dennis <jdennis@redhat.com> - 3.0.1-1
- Upgrade to upstream 3.0.1 release, full config compatible with 3.0.0.
This is a roll-up of all upstream bugs fixes found in 3.0.0