(RADIATOR) Problem with Class attribute

Ganbold ganbold at micom.mng.net
Sun Nov 24 22:55:14 CST 2002


Hi Hugh,

These class_id and CONTRACTID fields are integer fields. If I choose 
literal it will write only 0 into these fields.
This configuration works sometimes except saying error. It writes these 
fields as integer values.
What do you recommend? What should I change to make it work properly?

Ganbold



At 03:27 PM 11/25/2002 +1100, you wrote:

>Hello Ganbold -
>
>OK - having looked at the code in AuthSQL.pm, it appears that the
>problem is due to your AcctColumnDef:
>
>>>>         AcctColumnDef
>>>>class_id,Class,integer,substring('%{Class}',1,locate('- ','%{Class}')-> 1)
>>>>         AcctColumnDef
>>>>CONTRACTID,Class,integer,substring('%{Class}',locate('->
>>>>','%{Class}')+1)
>>>>...
>
>You have specified "integer" which is causing the problem - you might
>try "literal" instead.
>
>Have a look at section 6.28.14 in the Radiator 3.3.1 reference manual.
>
>regards
>
>Hugh
>
>
>On Monday, Nov 25, 2002, at 12:39 Australia/Melbourne, Ganbold wrote:
>
>>Hi Hugh,
>>
>>I changed as you suggested '-' into ':', but it seems like still error.
>>
>>Mon Nov 25 10:11:01 2002: ERR: There is no value named 16:3049 for
>>attribute Class. Using 0.
>>Mon Nov 25 10:11:01 2002: ERR: There is no value named 16:3049 for
>>attribute Class. Using 0.
>>Mon Nov 25 10:11:01 2002: DEBUG: do query is: insert into ACCOUNTING
>>(USERNAME,ACCTSTATUSTYPE,class_id,TIME_STAMP,NASPORT,CALLINGSTATIONID,A 
>>CCTDELAYTIME,CONTRACTID,ACCTSESSIONID,ACCTINPUTOCTETS,FRAMEDIPADDRESS,A 
>>CCTSESSIONTIME,ACCTOUTPUTOCTETS) values
>>('ynbstone','Stop',substring('16:3049',1,locate(':','16:3049')- 
>>1),1038190261,'434','11305106',0,substring('16:3049',locate(':','16:304 
>>9')+1),'00001D6F',1631,'202.179.xx.xx',18,836)
>>
>>
>>Ganbold
>>
>>
>>At 09:47 AM 11/25/2002 +1100, you wrote:
>>
>>>Hello Ganbold -
>>>
>>>I think a better approach would be to use a different delimiter than
>>>"-", which I suspect is confusing things.
>>>
>>>What about using ":" (colon) instead?
>>>
>>>Please try it and let me know what happens.
>>>
>>>regards
>>>
>>>Hugh
>>>
>>>
>>>On Sunday, Nov 24, 2002, at 17:45 Australia/Melbourne, Ganbold wrote:
>>>
>>>>Hi Hugh,
>>>>
>>>>Following is the part of the radius config file where I'm
>>>>concatenating 2 integer values into one string and  putting into 2
>>>>integer field from
>>>>concatenated string:
>>>>.....
>>>>
>>>>         AuthSelect select
>>>>ENCRYPTEDPASSWORD,CHECKATTR,REPLYATTR,concat(CLASS_ID,'-',CONTRACTID)
>>>>from SUBSCRIBERS where USERNAME='%n' and STATUS='Active'
>>>>
>>>>         EncryptedPassword
>>>>
>>>>         AuthColumnDef 0, Encrypted-Password, check
>>>>         AuthColumnDef 1, GENERIC, check
>>>>         AuthColumnDef 2, GENERIC, reply
>>>>         AuthColumnDef 3, Class, reply
>>>>
>>>>...
>>>>         AcctColumnDef
>>>>class_id,Class,integer,substring('%{Class}',1,locate('- ','%{Class}')-> 1)
>>>>         AcctColumnDef
>>>>CONTRACTID,Class,integer,substring('%{Class}',locate('->
>>>>','%{Class}')+1)
>>>>...
>>>>
>>>>In dictionary file Class is defined as string.
>>>>
>>>>Ganbold
>>>>
>>>>
>>>>At 03:24 PM 11/23/2002 +1100, you wrote:
>>>>
>>>>>Hello Ganbold -
>>>>>
>>>>>What definition do you have for "Class" in your dictionary (looks
>>>>>like
>>>>>"integer")?
>>>>>
>>>>>It should be defined as "string".
>>>>>
>>>>>Here is the entry from the standard dictionary:
>>>>>
>>>>>ATTRIBUTE       Class                   25      string
>>>>>
>>>>>regards
>>>>>
>>>>>Hugh
>>>>>
>>>>>
>>>>>On Friday, Nov 22, 2002, at 17:20 Australia/Melbourne, Ganbold
>>>>>wrote:
>>>>>
>>>>>>Hi,
>>>>>>
>>>>>>I'm having trouble with Radiator 3.3.1. I'm putting concatenated
>>>>>>value
>>>>>>to Class attribute.
>>>>>>But in radius logfile it says ERR: There is no value named 19-400
>>>>>>for
>>>>>>attribute Class. Using 0.
>>>>>>In insert statement it gets Class value and gets part of string and
>>>>>>puts into 2 different int field.
>>>>>>
>>>>>>Following is the part of logfile and insert statement.
>>>>>>
>>>>>>Ganbold
>>>>>>
>>>>>>------Logfile --------------------------
>>>>>>
>>>>>>Thu Nov 21 19:53:08 2002: ERR: There is no value named 19-400 for
>>>>>>attribute Class. Using 0.
>>>>>>Thu Nov 21 19:53:08 2002: ERR: There is no value named 19-400 for
>>>>>>attribute Class. Using 0.
>>>>>>Thu Nov 21 19:53:08 2002: DEBUG: do query is: insert into
>>>>>>ACCOUNTING
>>>>>>(USERNAME,ACCTSTATUSTYPE,class_id,TIME_STAMP,ACCTTERMINAT
>>>>>>ECAUSE,NASPORT,CALLINGSTATIONID,ACCTDELAYTIME,CONTRACTID,ACCTSESSIO 
>>>>>>NI D, ACCTINPUTOCTETS,FRAMEDIPADDRESS,ACCTSESSIONTIME,ACCTOUT
>>>>>>PUTOCTETS) values
>>>>>>('skytel','Stop',substring('19-400',1,locate('-','19-400')-
>>>>>>1),1037879588,'User-Request','56','11366801',0,su
>>>>>>bstring('19-400',locate('-','19-
>>>>>>400')+1),'000F6CE3',511690,'202.179.x.xx',3131,7864103)
>>>>>>
>>>>>>===
>>>>>>Archive at http://www.open.com.au/archives/radiator/
>>>>>>Announcements on radiator-announce at open.com.au
>>>>>>To unsubscribe, email 'majordomo at open.com.au' with
>>>>>>'unsubscribe radiator' in the body of the message.
>>>>>
>>>>>--
>>>>>Radiator: the most portable, flexible and configurable RADIUS server
>>>>>anywhere. Available on *NIX, *BSD, Windows 95/98/2000, NT, MacOS X.
>>>>>-
>>>>>Nets: internetwork inventory and management - graphical, extensible,
>>>>>flexible with hardware, software, platform and database
>>>>>independence.
>>>
>>>--
>>>Radiator: the most portable, flexible and configurable RADIUS server
>>>anywhere. Available on *NIX, *BSD, Windows 95/98/2000, NT, MacOS X.
>>>-
>>>Nets: internetwork inventory and management - graphical, extensible,
>>>flexible with hardware, software, platform and database independence.
>>
>>
>>===
>>Archive at http://www.open.com.au/archives/radiator/
>>Announcements on radiator-announce at open.com.au
>>To unsubscribe, email 'majordomo at open.com.au' with
>>'unsubscribe radiator' in the body of the message.
>>
>
>--
>Radiator: the most portable, flexible and configurable RADIUS server
>anywhere. Available on *NIX, *BSD, Windows 95/98/2000, NT, MacOS X.
>-
>Nets: internetwork inventory and management - graphical, extensible,
>flexible with hardware, software, platform and database independence.
>
>===
>Archive at http://www.open.com.au/archives/radiator/
>Announcements on radiator-announce at open.com.au
>To unsubscribe, email 'majordomo at open.com.au' with
>'unsubscribe radiator' in the body of the message.


===
Archive at http://www.open.com.au/archives/radiator/
Announcements on radiator-announce at open.com.au
To unsubscribe, email 'majordomo at open.com.au' with
'unsubscribe radiator' in the body of the message.


More information about the radiator mailing list