Products : freeradius 0.2, oracle client 8.1.6, oracle server 8.1.7.2
I compile freeradius with rlm_sql module for oracle and it s ok.
When i start the radiusd program, it connects well to the oracle database.
But, when i try a connection with a radius client, i am rejected.
I set the database in trace mode and I saw no error and the good request in the trace 
file.
So, I dont understand what is bad.

This is the row of my radcheck table in my database :
============================================================================
SQL> select * from radcheck;

        ID USERNAME   ATTRIBUTE            VALUE
---------- ---------- -------------------- --------------------
         1 clam       Password             clampwd
============================================================================

And this is the radiusd log :
============================================================================
Listening on IP address *, ports 1812/udp and 1813/udp.
Ready to process requests.
rad_recv: Access-Request packet from host 192.168.1.30:3230, id=0, length=65
        Proxy-State = 0x304b7e00
        User-Name = "clam"
        Password = "\364\354\005`{O8"
        NAS-IP-Address = 192.168.1.27
        NAS-Port = 1
        NAS-Port-Type = ISDN
        Acct-Delay-Time = 2000
modcall: entering group authorize
  modcall[authorize]: module "preprocess" returns ok
  modcall[authorize]: module "suffix" returns ok
    users: Matched DEFAULT at 148
  modcall[authorize]: module "files" returns ok
modcall: group authorize returns ok
  rad_check_password:  Found auth-type SQL
auth: type "SQL"
modcall: entering group authtype
rlm_sql: Reserving sql socket id: 4
radius_xlat:  'clam'
sql_escape in:  'clam'
sql_escape out:  'clam'
sql_set_user:  escaped user --> 'clam'
radius_xlat:  'SELECT Value,Attribute FROM radcheck WHERE UserName = 'clam' AND ( 
Attribute = 'Password' OR Attribute = 'Crypt-Password' ) ORDER BY Attribute DESC'
SELECT Value,Attribute FROM radcheck WHERE UserName = 'clam' AND ( Attribute = 
'Password' OR Attribute = 'Crypt-Password' ) ORDER BY Attribute DESC
rlm_sql: Released sql socket id: 4
  modcall[authenticate]: module "sql" returns reject
modcall: group authtype returns reject
auth: Failed to validate the user.
Login incorrect: [clam/clampwd] (from nas fred_pc port 1)
============================================================================
Next step, i try to know if the problem is between my radius client and my radius 
server or between my radius server and my database.
To do this, i had three printf lines to the rlm_sql.c file :
============================================================================
     if (auth_item->attribute != PW_CHAP_PASSWORD) {
                        printf("FG:request->password->strvalue : 
%s\n",request->password->strvalue);
                        printf("FG:row[0] : %s\n",row[0]);
                        printf("FG:row[1] : %s\n",row[1]);
                        if (strcmp(request->password->strvalue, row[0]) == 0) {
                                retval = RLM_MODULE_OK;
                        }
============================================================================
i compile and install this update and i have the following radiusd log :
============================================================================
Ready to process requests.
rad_recv: Access-Request packet from host 192.168.1.30:3288, id=2, length=65
        Proxy-State = 0x304b7e00
        User-Name = "clam"
        Password = "\001;\370\247\363\026\310"
        NAS-IP-Address = 192.168.1.27
        NAS-Port = 1
        NAS-Port-Type = ISDN
        Acct-Delay-Time = 2000
modcall: entering group authorize
  modcall[authorize]: module "preprocess" returns ok
  modcall[authorize]: module "suffix" returns ok
    users: Matched DEFAULT at 148
  modcall[authorize]: module "files" returns ok
modcall: group authorize returns ok
  rad_check_password:  Found auth-type SQL
auth: type "SQL"
modcall: entering group authtype
rlm_sql: Reserving sql socket id: 4
radius_xlat:  'clam'
sql_escape in:  'clam'
sql_escape out:  'clam'
sql_set_user:  escaped user --> 'clam'
radius_xlat:  'SELECT Value,Attribute FROM radcheck WHERE UserName = 'clam' AND ( 
Attribute = 'Password' OR Attribute = 'Crypt-Password' ) ORDER BY Attribute DESC'
SELECT Value,Attribute FROM radcheck WHERE UserName = 'clam' AND ( Attribute = 
'Password' OR Attribute = 'Crypt-Password' ) ORDER BY Attribute DESC
rlm_sql: Released sql socket id: 4
FG:request->password->strvalue : clampwd
FG:row[0] : 
p@p@��€@€@ˆ@ˆ@�@�@˜@˜@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@
FG:row[1] : 
p@p@��€@€@ˆ@ˆ@�@�@˜@˜@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@
  modcall[authenticate]: module "sql" returns reject
modcall: group authtype returns reject
auth: Failed to validate the user.
Login incorrect: [clam/clampwd] (from nas fred_pc port 1)
Sending Access-Reject of id 2 to 192.168.1.30:3288
============================================================================
The communication seems ok between my client and my radiusd server because the 
requested password look's
ok but row[0] who should contains the password stored in the database is strange and 
row[1] who should
contains "Password" look's the same.
I dont know what else to do.
Does anybody has an idea ?
Thank's and sorry for my english.
Fred




__________________________________________________________________
Your favorite stores, helpful shopping tools and great gift ideas. Experience the 
convenience of buying online with Shop@Netscape! http://shopnow.netscape.com/

Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.com/


- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to