how to remove some character from end of user name

Arran Cudbard-Bell a.cudbardb at freeradius.org
Sat Apr 27 19:33:47 CEST 2013


On 27 Apr 2013, at 12:11, Mehdi Ravanbakhsh <babakco at gmail.com> wrote:

> Dear  All
> 
> 
> I need to remove "m" character in end of all username
> 
> i think i should use hint but i can not find how ?

authorize {
	if (User-Name =~ /^(.*)m$/) {
		update request {
			User-Name := "%{1}"
		}
	}
}

Arran Cudbard-Bell <a.cudbardb at freeradius.org>
FreeRADIUS Development Team



More information about the Freeradius-Users mailing list