check attribute for several values

Ruslan N. Marchenko ruff at olimp.ua
Fri Aug 11 08:15:06 CEST 2006


Hi all.

Sorry for my poor english, mybe my explanations are not 
clear.

I want to find out, if i can add to radcheck table several 
values for attribute, in order to validate it in sequence?


radius=> SELECT radgroupcheck.GroupName, 
radgroupcheck.Attribute, 
radgroupcheck.Value,radgroupcheck.Op FROM radgroupcheck, 
usergroup WHERE usergroup.Username = '3813978' AND 
usergroup.GroupName = radgroupcheck.GroupName ORDER BY 
radgroupcheck.id;

  groupname  |  attribute   |   value    | op
-------------+--------------+------------+----
  VoIP Phones | Service-Type | Login-User | ==
  VoIP        | Service-Type | Call-Check | ==
(2 rows)

radius=> SELECT attribute,value ,op FROM radcheck WHERE 
Username='3813978'; 
                                                       attribute 
    |    value    | op
-------------------+-------------+----
  Framed-IP-Address | 192.168.5.5 | ==
  User-Password     | 3813978     | :=
(2 rows)

debug output:
rad_recv: Access-Request packet from host 127.0.0.1:4799, 
id=146, length=246
         User-Name = "3813978"
         NAS-IP-Address = 192.168.7.229
         NAS-Identifier = "GnuGk"
         NAS-Port-Type = Virtual
         Service-Type = Call-Check
         Framed-IP-Address = 192.168.5.5
         Calling-Station-Id = "1751don at olymp.local"
         Called-Station-Id = "3813978"
         h323-conf-id = "h323-conf-id=8975D519 283611DB 
80658D6C 7728828E"
         h323-call-origin = "h323-call-origin=answer"
         h323-call-type = "h323-call-type=VoIP"
         h323-gw-id = "h323-gw-id=GnuGk"
         User-Password = "3813978"
   Processing the authorize section of radiusd.conf
modcall: entering group authorize for request 205
   modcall[authorize]: module "preprocess" returns ok for 
request 205
   modcall[authorize]: module "chap" returns noop for 
request 205
radius_xlat:  '3813978'
rlm_sql (sql): sql_set_user escaped user --> '3813978'
...
skip
...
rlm_sql_postgresql: Status: PGRES_TUPLES_OK
rlm_sql_postgresql: affected rows =
rlm_sql (sql): Released sql socket id: 4
rlm_sql (sql): No matching entry in the database for 
request from user [3813978]
   modcall[authorize]: module "sql" returns notfound for 
request 205
modcall: leaving group authorize (returns ok) for request 
205
auth: No authenticate method (Auth-Type) configuration 
found for the request: Rejecting the user
auth: Failed to validate the user.
Delaying request 205 for 1 seconds
Finished request 205


--
Olimp, System Administrator
  IT Dept. 8 062 381-34-28
----
Looking forward to reading yours.
  MRN-RIPE RUFF-EUNIC RUFF-6BONE
      Ruslan N. Marchenko



More information about the Freeradius-Users mailing list