Remove dots from client-mac-address
Alan DeKok
aland at deployingradius.com
Tue Oct 25 12:53:31 UTC 2022
On Oct 25, 2022, at 8:33 AM, Steven Walters <steven.walters1 at gmail.com> wrote:
> I am using the below loop to extract client-mac-address from Cisco AVP and
> write it to the Telkom-CPE attribute.
>
> The format of the client-mac-address is "340a.3394.7291". Is there a way to
> remove the dots from the mac address like "340A33947291" before writing it
> the attribute?
Use a different regular expression.
if ("%{Foreach-Variable-0}" =~ /^client-mac-address=([0-9a-f]{3})\.([0-9a-f]{3})\,([0-9a-f]{3})/) {
update request {
Telkom-CPE := "%{1}%{2}%{3}"
}
Alan DeKok.
More information about the Freeradius-Users
mailing list