Updating nas-port after authentication

rgreiner mrgreiner at gmail.com
Tue Dec 23 15:47:34 CET 2008


tnt at kalik.net wrote:
>> The query I tried looks like this:
>>
>>        postauth_query = "UPDATE radcheck SET radcheck.value='%{NAS-Port}' \
>>                        WHERE radcheck.username = '%{User-Name}' \
>>                        and radcheck.attribute='NAS-Port'"
>>
>>     
>
> More important is how does it look in the debug. Is it used? You should
>   
Of course. If I had done this in first place, I would have seen my
mistake. I'm using <%{User-Name}> in the query, but I'm also using
domains, so the query ended up like ....WHERE radcheck.username =
'name at domain'. Of course, there is no such user, so no update was done.
I'm using <%{Stripped-User-Name}> now, and it worked fine.
> change the op in the same time.
>   
Yes, that's exactly what I intended to do. ^_^

Thanks a lot for the help,

Roberto


-- 
  -----------------------------------------------------
                Marcos Roberto Greiner

   Os otimistas acham que estamos no melhor dos mundos
    Os pessimistas tem medo de que isto seja verdade
                                       Murphy
  -----------------------------------------------------




More information about the Freeradius-Users mailing list