summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvenaas <venaas>2007-06-19 09:25:50 +0000
committervenaas <venaas@e88ac4ed-0b26-0410-9574-a7f39faa03bf>2007-06-19 09:25:50 +0000
commit7799f8b5b69dc62e1bc0d429a50d79e438c86cef (patch)
tree2dd64e676dc37f864b079c8aeedde2e8dfbeb35a
parent30c9519e38b5c55b80a12911795c6c04a5fd4625 (diff)
fixed another new bug, thanks Hans
git-svn-id: https://svn.testnett.uninett.no/radsecproxy/trunk@142 e88ac4ed-0b26-0410-9574-a7f39faa03bf
-rw-r--r--packaging/OpenWRT.txt1
-rw-r--r--packaging/rpm/radsecproxy.spec93
-rw-r--r--packaging/rpm/radsecproxy.sysv81
-rw-r--r--radsecproxy.c2
4 files changed, 176 insertions, 1 deletions
diff --git a/packaging/OpenWRT.txt b/packaging/OpenWRT.txt
new file mode 100644
index 0000000..ed5f5f4
--- /dev/null
+++ b/packaging/OpenWRT.txt
@@ -0,0 +1 @@
+For OpenWRT packages, please see http://zandbelt.dyndns.org/radsecproxy/
diff --git a/packaging/rpm/radsecproxy.spec b/packaging/rpm/radsecproxy.spec
new file mode 100644
index 0000000..5685080
--- /dev/null
+++ b/packaging/rpm/radsecproxy.spec
@@ -0,0 +1,93 @@
+Summary: radsecproxy is a generic RADIUS proxy that provides both RADIUS UDP and TCP/TLS (RadSec) transport.
+Name: radsecproxy
+Version: 1.0.alpha
+Release: 1
+Group: Applications/Communications
+License: BSD
+URL: http://software.uninett.no/radsecproxy
+Packager: Arnes <aaa-podpora@arnes.si>
+Source: http://software.uninett.no/radsecproxy/radsecproxy-1.0-alpha.tar.gz
+Source1: radsecproxy.sysv
+Source2: radsecproxy.1
+Source3: radsecproxy.conf.5
+Requires: openssl >= 0.9.7a
+
+BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
+BuildRequires: openssl-devel >= 0.9.7a
+
+%description
+radsecproxy is a generic RADIUS proxy that in addition to to
+usual RADIUS UDP transport, also supports TLS (RadSec). The
+aim is for the proxy to have sufficient features to be flexible,
+while at the same time to be small, efficient and easy to configure.
+Currently the executable on Linux is only about 48 Kb, and it uses
+about 64 Kb (depending on the number of peers) while running.
+
+The proxy was initially made to be able to deploy RadSec (RADIUS
+over TLS) so that all RADIUS communication across network links
+could be done using TLS, without modifying existing RADIUS software.
+This can be done by running this proxy on the same host as an existing
+RADIUS server or client, and configure the existing client/server to
+talk to localhost (the proxy) rather than other clients and servers
+directly.
+
+There may however be other situations where a RADIUS proxy might be
+useful. Some people deploy RADIUS topologies where they want to
+route RADIUS messages to the right server. The nodes that do purely
+routing could be using a proxy. Some people may also wish to deploy
+a proxy on a firewall boundary. Since the proxy supports both IPv4
+and IPv6, it could also be used to allow communication in cases
+where some RADIUS nodes use only IPv4 and some only IPv6.
+
+%prep
+%setup -n %{name}-1.0-alpha
+
+%build
+%{__make}
+
+%install
+%{__rm} -rf %{buildroot}
+%{__install} -D -m0644 radsecproxy.conf-example %{buildroot}%{_docdir}/%{name}-%{version}/radsecproxy.conf-example
+%{__install} -D -m0644 AUTHORS %{buildroot}%{_docdir}/%{name}-%{version}/AUTHORS
+%{__install} -D -m0644 ChangeLog %{buildroot}%{_docdir}/%{name}-%{version}/ChangeLog
+%{__install} -D -m0644 COPYING %{buildroot}%{_docdir}/%{name}-%{version}/COPYING
+%{__install} -D -m0644 README %{buildroot}%{_docdir}/%{name}-%{version}/README
+%{__install} -D -m0755 radsecproxy %{buildroot}%{_sbindir}/radsecproxy
+%{__install} -D -m0755 %{SOURCE1} %{buildroot}%{_initrddir}/radsecproxy
+%{__install} -D -m0644 %{SOURCE2} %{buildroot}%{_mandir}/man1/radsecproxy.1
+%{__install} -D -m0644 %{SOURCE3} %{buildroot}%{_mandir}/man5/radsecproxy.conf.5
+
+%clean
+%{__rm} -rf %{buildroot}
+
+%post
+/sbin/chkconfig --add radsecproxy
+
+%preun
+if [ $1 -eq 0 ]; then
+ /sbin/service radsecproxy stop &>/dev/null || :
+ /sbin/chkconfig --del radsecproxy
+fi
+
+%postun
+if [ $1 -ge 1 ]; then
+ /sbin/service radsecproxy condrestart &> /dev/null || :
+fi
+
+%files
+%defattr(-, root, root, 0755)
+%config %{_initrddir}/radsecproxy
+%{_sbindir}/radsecproxy
+%doc %{_docdir}/%{name}-%{version}/AUTHORS
+%doc %{_docdir}/%{name}-%{version}/ChangeLog
+%doc %{_docdir}/%{name}-%{version}/COPYING
+%doc %{_docdir}/%{name}-%{version}/README
+%doc %{_docdir}/%{name}-%{version}/radsecproxy.conf-example
+%doc %{_mandir}/man1/radsecproxy.1.gz
+%doc %{_mandir}/man5/radsecproxy.conf.5.gz
+
+%changelog
+* Thu Jun 07 2007 Rok Papez <aaa-podpora@arnes.si> - 1.0-alpha.1
+- Initial packaging of the 1.0-alpha.1 release
+- Added SysV/RedHat init script
+- Added radsecproxy manages
diff --git a/packaging/rpm/radsecproxy.sysv b/packaging/rpm/radsecproxy.sysv
new file mode 100644
index 0000000..38a5055
--- /dev/null
+++ b/packaging/rpm/radsecproxy.sysv
@@ -0,0 +1,81 @@
+#!/bin/bash
+#
+# init script for radsecproxy
+#
+# chkconfig: 345 95 05
+# description: RADIUS UDP and RADSEC proxy
+#
+# config: /etc/radsecproxy.conf
+
+source /etc/init.d/functions
+source /etc/sysconfig/network
+
+# Check that networking is up.
+[ ${NETWORKING} = "no" ] && exit 0
+
+[ -x /usr/sbin/radsecproxy ] || exit 1
+[ -f /etc/radsecproxy.conf ] || exit 1
+
+RETVAL=0
+prog="radsecproxy"
+desc="RADSEC Proxying"
+
+start() {
+ echo -n $"Starting $desc ($prog): "
+ daemon /usr/sbin/$prog || RETVAL=1
+
+ if [ $RETVAL -eq 0 ]; then
+ success "$prog startup"
+ rm -f /var/lock/subsys/$prog
+ else
+ failure "$prog startup"
+ fi
+
+ echo
+ return $RETVAL
+}
+
+stop() {
+ echo -n $"Stopping $desc ($prog): "
+ killproc $prog || RETVAL=1
+
+ if [ $RETVAL -eq 0 ]; then
+ success "$prog shutdown"
+ rm -f /var/lock/subsys/$prog
+ else
+ failure "$prog shutdown"
+ fi
+
+ echo
+ return $RETVAL
+}
+
+restart() {
+ stop
+ start
+}
+
+case "$1" in
+ start)
+ start
+ ;;
+ stop)
+ stop
+ ;;
+ restart|reload)
+ restart
+ ;;
+ condrestart)
+ [ -e /var/lock/subsys/$prog ] && restart
+ RETVAL=$?
+ ;;
+ status)
+ status $prog
+ RETVAL=$?
+ ;;
+ *)
+ echo $"Usage $0 {start|stop|restart|reload|condrestart|status}"
+ RETVAL=1
+esac
+
+exit $RETVAL
diff --git a/radsecproxy.c b/radsecproxy.c
index 30d626d..10fae1d 100644
--- a/radsecproxy.c
+++ b/radsecproxy.c
@@ -2377,7 +2377,7 @@ int main(int argc, char **argv) {
}
for (i = 0; i < srvconf_count; i++)
- if (pthread_create(&srvconfs[i].servers->clientth, NULL, clientwr, (void *)&srvconfs[i]))
+ if (pthread_create(&srvconfs[i].servers->clientth, NULL, clientwr, (void *)srvconfs[i].servers))
debugx(1, DBG_ERR, "pthread_create failed");
if (client_tls_count) {