mac address format

Alan DeKok aland at deployingradius.com
Mon Jan 28 14:39:51 CET 2013


François Dagorn wrote:
> So, is there a simple way to force radiusd to accept different mac address format ?

  Write a regular expression to turn one into the other.

  if (("%{User-Name}" == "%{User-Password}") && \
	(User-Name =~
/([0-9a-f]{2}):([0-9a-f]{2}):([0-9a-f]{2}):([0-9a-f]{2}):([0-9a-f]{2}):([0-9a-f]{2})))
{
	update request {
		User-Name := "%{1}%{2}%{3}%{4}%{5}%{6]"
		User-Password := "%{1}%{2}%{3}%{4}%{5}%{6]"
	}
  }
  files
  ...


  That should work.  It would also help for you to go through that, and
understand exactly what it means.

> Sorry if this is a FAQ, of course I've not changed anything within my conf
> since 2009 !

  FreeRADIUS is pretty darned stable.

  Alan DeKok.


More information about the Freeradius-Users mailing list