]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Allow EAP sub-modules to be disabled via (e.g.) "disable peap"
authorAlan T. DeKok <aland@freeradius.org>
Thu, 13 Aug 2015 08:48:00 +0000 (10:48 +0200)
committerAlan T. DeKok <aland@freeradius.org>
Thu, 13 Aug 2015 08:48:00 +0000 (10:48 +0200)
src/modules/rlm_eap/rlm_eap.c

index 1a2e614b0e2be8cb2c4cf8040484f252f50f6cbf..24163653fd94e7260abaacbb48ba8006d8fefd11 100644 (file)
@@ -119,7 +119,6 @@ static int mod_instantiate(CONF_SECTION *cs, void *instance)
        for(scs = cf_subsection_find_next(cs, NULL, NULL);
            scs != NULL;
            scs = cf_subsection_find_next(cs, scs, NULL)) {
-
                char const *name;
 
                name = cf_section_name1(scs);
@@ -127,6 +126,12 @@ static int mod_instantiate(CONF_SECTION *cs, void *instance)
 
                if (!strcmp(name, TLS_CONFIG_SECTION))  continue;
 
+               /*
+                *      Easier sometimes than commenting out blocks,
+                *      or deleting blocks.
+                */
+               if (!strcmp(name, "disable")) continue;
+
                method = eap_name2type(name);
                if (method == PW_EAP_INVALID) {
                        cf_log_err_cs(cs, "No dictionary definition for EAP method %s", name);