]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
move check to be closer to where it's needed
authorAlan T. DeKok <aland@freeradius.org>
Tue, 19 Jan 2016 20:39:36 +0000 (15:39 -0500)
committerAlan T. DeKok <aland@freeradius.org>
Tue, 19 Jan 2016 20:39:36 +0000 (15:39 -0500)
src/modules/rlm_eap/types/rlm_eap_peap/peap.c

index a41f7812e5aeb9fb59cae6131b56fd4e476a21a4..967bb424c0bb1de2780d874ee0ed875ef43dec39 100644 (file)
@@ -1023,13 +1023,6 @@ rlm_rcode_t eappeap_process(eap_handler_t *handler, tls_session_t *tls_session,
                if (vp) {
                        eap_tunnel_data_t *tunnel;
 
-                       if (!auth_type_eap) {
-                               RERROR("You must set 'inner_eap_module' in the 'peap' configuration");
-                               RERROR("This is required in order to proxy the inner EAP session.");
-                               rcode = RLM_MODULE_REJECT;
-                               goto done;
-                       }
-
                        /*
                         *      The tunneled request was NOT handled,
                         *      it has to be proxied.  This means that
@@ -1053,6 +1046,12 @@ rlm_rcode_t eappeap_process(eap_handler_t *handler, tls_session_t *tls_session,
                                 *      Auth-Type & EAP-Message here?
                                 */
 
+                               if (!auth_type_eap) {
+                                       RERROR("You must set 'inner_eap_module' in the 'peap' configuration");
+                                       RERROR("This is required in order to proxy the inner EAP session.");
+                                       rcode = RLM_MODULE_REJECT;
+                                       goto done;
+                               }
 
                                /*
                                 *      Run the EAP authentication.