Using Client-Shortname within perl module

Alex Sharaz alex.sharaz at
Mon Jun 23 16:07:03 CEST 2014


I'm using perl to convert various attributes into a standardised  XX-XX-XX-XX-XX-XX format e.g

        $RAD_REQUEST{'Calling-Station-Id'} = &formatMac($RAD_REQUEST{'Calling-Station-Id'});
        $RAD_REQUEST{'Called-Station-Id'} = &formatMac($RAD_REQUEST{'Called-Station-Id'});
        $RAD_REQUEST{'User-Name'} = &formatMac($RAD_REQUEST{'User-Name'});
 which works just fine. 

However, our Comp Science dept decided not to use the same hex formatting as us so when I proxy mac-auth requests off to their server, I need to make sure that I don't do the above. 

Is there any way I can wrap an 

if ( Client-Shortname != "cseswitches") {
round the above so that I only perform the conversion when processing non Comp Sci requests?


More information about the Freeradius-Users mailing list