Ensure that 'Realm' is added to vps in all cases when we find
authorcparker <cparker>
Thu, 18 Jul 2002 17:09:18 +0000 (17:09 +0000)
committercparker <cparker>
Thu, 18 Jul 2002 17:09:18 +0000 (17:09 +0000)
a matching realm ( even if we handle it locally ).  Bug noted
by Chris Brotsos.

src/modules/rlm_realm/rlm_realm.c

index 1ac4175..d3f88db 100644 (file)
@@ -185,6 +185,13 @@ static REALM *check_for_realm(void *instance, REQUEST *request)
               username, realm->realm);
 
        /*
+        *      Add the realm name to the request.
+        */
+       pairadd(&request->packet->vps, pairmake("Realm", realm->realm,
+                                               T_OP_EQ));
+       DEBUG2("    rlm_realm: Adding Realm = \"%s\"", realm->realm);
+
+       /*
         *      Figure out what to do with the request.
         */
        is_local = FALSE;
@@ -226,13 +233,6 @@ static REALM *check_for_realm(void *instance, REQUEST *request)
        }
 
        /*
-        *      Add the realm name to the request.
-        */
-       pairadd(&request->packet->vps, pairmake("Realm", realm->realm,
-                                               T_OP_EQ));
-       DEBUG2("    rlm_realm: Adding Realm = \"%s\"", realm->realm);
-
-       /*
         *      Local realm, don't proxy it.
         */
        if (is_local) {