unlang fails for some strange reason...

Fajar A. Nugraha list at fajar.net
Wed May 9 09:53:33 CEST 2012


On Wed, May 9, 2012 at 2:45 PM, Stefan Winter <stefan.winter at restena.lu> wrote:
> Hello,
>
> noone with a hint?

Might not be the direct cause for your problem, but I'm pretty sure
you're not supposed to put unlang blocks inside authenticate section.
Or at least it's not recommended.

Try moving it to authorize section.

-- 
Fajar


>
> Stefan
>
> On 07.05.2012 11:13, Stefan Winter wrote:
>> Hi,
>>
>> at a client's site, I have to some chopping off parts of User-Name,
>> pretty straightforward, but for some reason it doesn't work (2.1.12):
>>
>> In inner-tunnel, authenticate, MSCHAPv2 for PEAP:
>>
>> authenticate {
>>
>>         Auth-Type MS-CHAP {
>>
>>                 if("%{Stripped-User-Name}" =~ /(....................).*/){
>>                                 update request {
>>                                         SAMAccountName := "%{1}"
>>                                 }
>>                 }
>>                 else {
>>                         update request {
>>                                         SAMAccountName := "%{Stripped-User-Name}"
>>                                 }
>>                 }
>>                 mschap
>>         }


More information about the Freeradius-Users mailing list