[monitoring-plugins] check_radius: remove dead libraries (#2339)
GitHub
git at monitoring-plugins.org
Wed Sep 9 20:50:14 CEST 2026
Module: monitoring-plugins
Branch: master
Commit: 0d07ab1756e3984e7b24010efffe5315683e72d9
Author: Lorenz Kästle <12514511+RincewindsHat at users.noreply.github.com>
Committer: GitHub <noreply at github.com>
Date: Wed Sep 9 20:40:33 2026 +0200
URL: https://www.monitoring-plugins.org/repositories/monitoring-plugins/commit/?id=0d07ab17
check_radius: remove dead libraries (#2339)
To my best knowledge libradiusclient and libradiusclient-ng
are dead and gone (partially merged back into FreeRadius).
This change removes the detection logic and the
corresponding includes and leaves us with only
radcli and FreeRadius as options.
---
REQUIREMENTS | 8 --------
configure.ac | 18 ++----------------
plugins/check_radius.c | 21 +++++++++------------
plugins/check_radius.d/config.h | 4 +---
4 files changed, 12 insertions(+), 39 deletions(-)
diff --git a/REQUIREMENTS b/REQUIREMENTS
index 7bb898c3..f839e124 100644
--- a/REQUIREMENTS
+++ b/REQUIREMENTS
@@ -72,14 +72,6 @@ check_radius:
http://freeradius.org/freeradius-client/
The minimal version is 1.1.8, since it broke compatibility in that
release. Later versions may be used if that does not happen again
- - As another alternative, the radiusclient-ng library may be used:
- http://sourceforge.net/projects/radiusclient-ng.berlios/
- - This plugin also works with the original radiusclient library from
- ftp://ftp.cityline.net/pub/radiusclient/
- RPM (rpmfind): radiusclient 0.3.2, radiusclient-devel-0.3.2
- However, you probably want to use either radcli or the FreeRADIUS
- Client library, as both radiusclient and radiusclient-ng are
- unmaintained and have known issues.
check_snmp:
- Requires the NET-SNMP package available from
diff --git a/configure.ac b/configure.ac
index 2bda91ab..3ee89e2e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -291,22 +291,8 @@ AS_IF([test "x$with_radius" != "xno"], [
RADIUSLIBS="-lfreeradius-client"
AC_SUBST(RADIUSLIBS)
else
- AC_CHECK_LIB(radiusclient-ng,rc_read_config)
- if test "$ac_cv_lib_radiusclient_ng_rc_read_config" = "yes"; then
- EXTRAS="$EXTRAS check_radius\$(EXEEXT)"
- RADIUSLIBS="-lradiusclient-ng"
- AC_SUBST(RADIUSLIBS)
- else
- AC_CHECK_LIB(radiusclient,rc_read_config)
- if test "$ac_cv_lib_radiusclient_rc_read_config" = "yes"; then
- EXTRAS="$EXTRAS check_radius\$(EXEEXT)"
- RADIUSLIBS="-lradiusclient"
- AC_SUBST(RADIUSLIBS)
- else
- AC_MSG_WARN([Skipping radius plugin])
- AC_MSG_WARN([install radius libs to compile this plugin (see REQUIREMENTS).])
- fi
- fi
+ AC_MSG_WARN([Skipping radius plugin])
+ AC_MSG_WARN([install radius libs to compile this plugin (see REQUIREMENTS).])
fi
fi
LIBS="$_SAVEDLIBS"
diff --git a/plugins/check_radius.c b/plugins/check_radius.c
index 5ad08989..49055fce 100644
--- a/plugins/check_radius.c
+++ b/plugins/check_radius.c
@@ -43,10 +43,8 @@ const char *email = "devel at monitoring-plugins.org";
# include <radcli/radcli.h>
#elif defined(HAVE_LIBFREERADIUS_CLIENT)
# include <freeradius-client.h>
-#elif defined(HAVE_LIBRADIUSCLIENT_NG)
-# include <radiusclient-ng.h>
#else
-# include <radiusclient.h>
+# error "no radius library available"
#endif
typedef struct {
@@ -57,8 +55,7 @@ static check_radius_config_wrapper process_arguments(int /*argc*/, char ** /*arg
static void print_help(void);
void print_usage(void);
-#if defined(HAVE_LIBFREERADIUS_CLIENT) || defined(HAVE_LIBRADIUSCLIENT_NG) || \
- defined(HAVE_LIBRADCLI)
+#if defined(HAVE_LIBFREERADIUS_CLIENT) || defined(HAVE_LIBRADCLI)
# define my_rc_conf_str(a) rc_conf_str(rch, a)
# if defined(HAVE_LIBRADCLI)
# define my_rc_send_server(a, b) rc_send_server(rch, a, b, AUTH)
@@ -165,8 +162,7 @@ int main(int argc, char **argv) {
mp_set_format(config.output_format);
}
-#if defined(HAVE_LIBFREERADIUS_CLIENT) || defined(HAVE_LIBRADIUSCLIENT_NG) || \
- defined(HAVE_LIBRADCLI)
+#if defined(HAVE_LIBFREERADIUS_CLIENT) || defined(HAVE_LIBRADCLI)
rc_handle *rch = NULL;
#endif
@@ -197,7 +193,8 @@ int main(int argc, char **argv) {
if (!(my_rc_avpair_add(&data.send_pairs, PW_SERVICE_TYPE, &service, 0) &&
my_rc_avpair_add(&data.send_pairs, PW_USER_NAME, config.username, 0) &&
my_rc_avpair_add(&data.send_pairs, PW_USER_PASSWORD, config.password, 0))) {
- mopl_utils_xasprintf(&sc_configuring.output, "Failed to the radius options: Out of Memory?");
+ mopl_utils_xasprintf(&sc_configuring.output,
+ "Failed to the radius options: Out of Memory?");
sc_configuring = mp_set_subcheck_state(sc_configuring, STATE_UNKNOWN);
mp_add_subcheck_to_check(&overall, sc_configuring);
mp_exit(overall);
@@ -206,7 +203,7 @@ int main(int argc, char **argv) {
if (config.nas_id != NULL) {
if (!(my_rc_avpair_add(&data.send_pairs, PW_NAS_IDENTIFIER, config.nas_id, 0))) {
mopl_utils_xasprintf(&sc_configuring.output,
- "Failed to the radius options: invalid NAS identifier?");
+ "Failed to the radius options: invalid NAS identifier?");
sc_configuring = mp_set_subcheck_state(sc_configuring, STATE_UNKNOWN);
mp_add_subcheck_to_check(&overall, sc_configuring);
mp_exit(overall);
@@ -234,7 +231,8 @@ int main(int argc, char **argv) {
uint32_t client_id = ntohl(((struct sockaddr_in *)&radius_server_socket)->sin_addr.s_addr);
if (my_rc_avpair_add(&(data.send_pairs), PW_NAS_IP_ADDRESS, &client_id, 0) == NULL) {
- mopl_utils_xasprintf(&sc_configuring.output, "invalid NAS IP address. Setting option failed");
+ mopl_utils_xasprintf(&sc_configuring.output,
+ "invalid NAS IP address. Setting option failed");
sc_configuring = mp_set_subcheck_state(sc_configuring, STATE_UNKNOWN);
mp_add_subcheck_to_check(&overall, sc_configuring);
mp_exit(overall);
@@ -498,8 +496,7 @@ void print_usage(void) {
}
int my_rc_read_config(char *config_file_name, rc_handle **rch) {
-#if defined(HAVE_LIBFREERADIUS_CLIENT) || defined(HAVE_LIBRADIUSCLIENT_NG) || \
- defined(HAVE_LIBRADCLI)
+#if defined(HAVE_LIBFREERADIUS_CLIENT) || defined(HAVE_LIBRADCLI)
*rch = rc_read_config(config_file_name);
return (rch == NULL) ? 1 : 0;
#else
diff --git a/plugins/check_radius.d/config.h b/plugins/check_radius.d/config.h
index 656bf98e..d76c985a 100644
--- a/plugins/check_radius.d/config.h
+++ b/plugins/check_radius.d/config.h
@@ -7,10 +7,8 @@
# include <radcli/radcli.h>
#elif defined(HAVE_LIBFREERADIUS_CLIENT)
# include <freeradius-client.h>
-#elif defined(HAVE_LIBRADIUSCLIENT_NG)
-# include <radiusclient-ng.h>
#else
-# include <radiusclient.h>
+# error "no radius library available"
#endif
typedef struct {
More information about the Commits
mailing list