On Fri, May 18, 2012 at 11:35:39AM +0800, C.F. Yeung wrote:
> Sorry to bother again, how should I rewrite the unlang for the condition
> that if the Called-Station-Id contains "eduroam"?
> 
>  if (Called-Station-Id == "xx-xx-xx-xx-xx-xx:eduroam") {

man unlang - look for regular expressions.

  if (Called-Station-Id =~ /eduroam/) {

or you may want something more like

  if (Called-Station-Id =~ /:eduroam$/) {

to check that it ends in ":eduroam"

Matthew


-- 
Matthew Newton, Ph.D. <[email protected]>

Systems Architect (UNIX and Networks), Network Services,
I.T. Services, University of Leicester, Leicester LE1 7RH, United Kingdom

For IT help contact helpdesk extn. 2253, <[email protected]>
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to