From 0f3649297dc556f92ba43b267ce2089ce8e7aa99 Mon Sep 17 00:00:00 2001 From: Faidon Liambotis Date: Thu, 5 Sep 2019 02:47:49 +0300 Subject: [PATCH 1/3] Move manpages from section 1 to section 8 radsecproxy is a daemon, and as such, section 8 is more appropriate. --- Makefile.am | 4 ++-- README | 2 +- radsecproxy-hash.1 => radsecproxy-hash.8 | 2 +- radsecproxy.1 => radsecproxy.8 | 4 ++-- radsecproxy.conf.5 | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) rename radsecproxy-hash.1 => radsecproxy-hash.8 (92%) rename radsecproxy.1 => radsecproxy.8 (97%) diff --git a/Makefile.am b/Makefile.am index 7c2f5fc..ac85aa6 100644 --- a/Makefile.am +++ b/Makefile.am @@ -46,7 +46,7 @@ radsecproxy_LDADD = librsp.a @SSL_LIBS@ radsecproxy_conf_LDFLAGS = @TARGET_LDFLAGS@ radsecproxy_hash_LDADD = fticks_hashmac.o hash.o list.o -dist_man_MANS = radsecproxy.1 radsecproxy-hash.1 radsecproxy.conf.5 +dist_man_MANS = radsecproxy.8 radsecproxy-hash.8 radsecproxy.conf.5 EXTRA_DIST = \ LICENSE THANKS \ @@ -59,7 +59,7 @@ EXTRA_DIST = \ html: radsecproxy.html radsecproxy-hash.html radsecproxy.conf.html -%.html: %.1 +%.html: %.8 groff -mandoc -Thtml $< >$@ %.html: %.5 groff -mandoc -Thtml $< >$@ diff --git a/README b/README index 5576b5e..c6d5f3c 100644 --- a/README +++ b/README @@ -17,7 +17,7 @@ To use radsecproxy you need to create a config file which is normally found in /usr/local/etc/radsecproxy.conf. You can also specify the location with the "-c" command line option (see below). For further instructions, please see the enclosed example file and the manpages -radsecproxy(1) and radsecproxy.conf(5) +radsecproxy(8) and radsecproxy.conf(5). Note for Cygwin users: Due to a bug in openssl the tls option CACertificatePath is currently unusable. diff --git a/radsecproxy-hash.1 b/radsecproxy-hash.8 similarity index 92% rename from radsecproxy-hash.1 rename to radsecproxy-hash.8 index a614c23..a856aae 100644 --- a/radsecproxy-hash.1 +++ b/radsecproxy-hash.8 @@ -1,4 +1,4 @@ -.TH radsecproxy-hash 1 "5 May 2018" +.TH radsecproxy-hash 8 "5 May 2018" .SH "NAME" radsecproxy-hash - print digests of Ethernet MAC addresses diff --git a/radsecproxy.1 b/radsecproxy.8 similarity index 97% rename from radsecproxy.1 rename to radsecproxy.8 index b556ba7..8930e1b 100644 --- a/radsecproxy.1 +++ b/radsecproxy.8 @@ -1,4 +1,4 @@ -.TH radsecproxy 1 "5 July 2018" +.TH radsecproxy 8 "5 July 2018" .SH "NAME" radsecproxy - a generic RADIUS proxy that provides both RADIUS UDP and TCP/TLS (RadSec) transport. @@ -89,4 +89,4 @@ This signal is ignored. The default configuration file. .SH "SEE ALSO" -radsecproxy.conf(5), radsecproxy-hash(1) +radsecproxy.conf(5), radsecproxy-hash(8) diff --git a/radsecproxy.conf.5 b/radsecproxy.conf.5 index f6c42db..c17d619 100644 --- a/radsecproxy.conf.5 +++ b/radsecproxy.conf.5 @@ -8,7 +8,7 @@ When the proxy server starts, it will first check the command line arguments, and then read the configuration file. Normally radsecproxy will read the configuration file \fI/usr/local/etc/radsecproxy.conf\fR. The command line \fB\-c\fR option can be used to instead read an alternate file (see -\fBradsecproxy\fR(1) for details). +\fBradsecproxy\fR(8) for details). If the configuration file can not be found, the proxy will exit with an error message. Note that there is also an include facility so that any configuration @@ -911,5 +911,5 @@ subattributes are removed. .RE .SH "SEE ALSO" -\fBradsecproxy\fR(1), +\fBradsecproxy\fR(8), .URL https://tools.ietf.org/html/rfc6614 " Transport Layer Security (TLS) Encryption for RADIUS " From e3c836319205c30eae111536037fdb520cecc746 Mon Sep 17 00:00:00 2001 From: Faidon Liambotis Date: Thu, 5 Sep 2019 02:55:10 +0300 Subject: [PATCH 2/3] Fix radsecproxy.conf.5 manpage errors Remove references to 'T<' and 'T>' macros, as well as a a reference to a URL macro. The latter was for a pointer to RFC 6614, which is entirely removed as not overly helpful. Fixes: #49 --- radsecproxy.conf.5 | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/radsecproxy.conf.5 b/radsecproxy.conf.5 index c17d619..a1a300a 100644 --- a/radsecproxy.conf.5 +++ b/radsecproxy.conf.5 @@ -222,7 +222,7 @@ not supported. The FTicksPrefix option is used to set the \fIprefix\fR printed in F-Ticks messages. This allows for use of F-Ticks messages in non-eduroam environments. If no FTicksPrefix option is given, it defaults to the prefix used for eduroam -(\*(T) +(\fIF\-TICKS/eduroam/1.0\fR). .RE @@ -911,5 +911,4 @@ subattributes are removed. .RE .SH "SEE ALSO" -\fBradsecproxy\fR(8), -.URL https://tools.ietf.org/html/rfc6614 " Transport Layer Security (TLS) Encryption for RADIUS " +\fBradsecproxy\fR(8) From 4add5eaebb1e6c73a6bec76681c38fcc2191276e Mon Sep 17 00:00:00 2001 From: Faidon Liambotis Date: Thu, 5 Sep 2019 03:40:45 +0300 Subject: [PATCH 3/3] Avoid the hardcoding of /usr/local/etc On Linux systems, sysconfdir is usually /etc, while all the documentation refers to /usr/local/etc. Switch the two manpages that need to refer to the config file location to autoconf-substituted variables, and remove a spurious reference from the example config. --- .gitignore | 2 ++ README | 6 +++--- configure.ac | 10 ++++++++++ radsecproxy.8 => radsecproxy.8.in | 2 +- radsecproxy.conf-example | 3 +-- radsecproxy.conf.5 => radsecproxy.conf.5.in | 4 ++-- 6 files changed, 19 insertions(+), 8 deletions(-) rename radsecproxy.8 => radsecproxy.8.in (98%) rename radsecproxy.conf.5 => radsecproxy.conf.5.in (99%) diff --git a/.gitignore b/.gitignore index fa95497..8e166fc 100644 --- a/.gitignore +++ b/.gitignore @@ -22,6 +22,8 @@ TAGS radsecproxy radsecproxy-conf radsecproxy-hash +radsecproxy.8 +radsecproxy.conf.5 build-aux/* tests/t_fticks tests/t_rewrite diff --git a/README b/README index c6d5f3c..33346cf 100644 --- a/README +++ b/README @@ -13,9 +13,9 @@ support. Without any special options to configure, all transports supported by the system will be enabled. See the output from "./configure --help" for how to change this. -To use radsecproxy you need to create a config file which is normally -found in /usr/local/etc/radsecproxy.conf. You can also specify the -location with the "-c" command line option (see below). For further +To use radsecproxy you need to create a config file which is normally found in +/etc/radsecproxy.conf or /usr/local/etc/radsecproxy.conf. You can also specify +the location with the "-c" command line option (see below). For further instructions, please see the enclosed example file and the manpages radsecproxy(8) and radsecproxy.conf(5). diff --git a/configure.ac b/configure.ac index 55d0921..b69c1b4 100644 --- a/configure.ac +++ b/configure.ac @@ -92,6 +92,16 @@ if test "x$dtls" = "xyes" ; then TARGET_CFLAGS="$TARGET_CFLAGS -DRADPROT_DTLS" fi +dnl Substitute variables such as sysconfdir +AC_CONFIG_FILES([radsecproxy.8 radsecproxy.conf.5]) + +dnl Expand sysconfdir early to avoid two layers of substitution +test "x$prefix" = xNONE && prefix=$ac_default_prefix +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' +SYSCONFDIR=`eval echo $sysconfdir` +SYSCONFDIR=`eval echo $SYSCONFDIR` +AC_SUBST(SYSCONFDIR) + AC_SUBST(TARGET_CFLAGS) AC_SUBST(TARGET_LDFLAGS) AX_CHECK_SSL diff --git a/radsecproxy.8 b/radsecproxy.8.in similarity index 98% rename from radsecproxy.8 rename to radsecproxy.8.in index 8930e1b..b7fd334 100644 --- a/radsecproxy.8 +++ b/radsecproxy.8.in @@ -84,7 +84,7 @@ This signal is ignored. .SH "FILES" .TP -.B /usr/local/etc/radsecproxy.conf +.B @SYSCONFDIR@/radsecproxy.conf .sp The default configuration file. diff --git a/radsecproxy.conf-example b/radsecproxy.conf-example index c9347ee..1730e55 100644 --- a/radsecproxy.conf-example +++ b/radsecproxy.conf-example @@ -1,5 +1,4 @@ -# Master config file, must be in /usr/local/etc/radsecproxy or specified with -c option -# All possible config options are listed below +# Master config file, all possible config options are listed below # First you may define any global options, these are: # diff --git a/radsecproxy.conf.5 b/radsecproxy.conf.5.in similarity index 99% rename from radsecproxy.conf.5 rename to radsecproxy.conf.5.in index a1a300a..0f5d6aa 100644 --- a/radsecproxy.conf.5 +++ b/radsecproxy.conf.5.in @@ -6,7 +6,7 @@ radsecproxy.conf \- Radsec proxy configuration file .SH DESCRIPTION When the proxy server starts, it will first check the command line arguments, and then read the configuration file. Normally radsecproxy will read the -configuration file \fI/usr/local/etc/radsecproxy.conf\fR. The command line +configuration file \fI@SYSCONFDIR@/radsecproxy.conf\fR. The command line \fB\-c\fR option can be used to instead read an alternate file (see \fBradsecproxy\fR(8) for details). @@ -79,7 +79,7 @@ be included. The value can be a single file, or it can use normal shell globbing to specify multiple files, e.g.: .RS -include /usr/local/etc/radsecproxy.conf.d/*.conf +include @SYSCONFDIR@/radsecproxy.conf.d/*.conf .RE The files are sorted alphabetically. Included files are read in the order they