[PATCH] policy.conf rewrite.called_station_id fix
    Arran Cudbard-Bell 
    a.cudbardb at freeradius.org
       
    Fri Aug 19 17:02:43 CEST 2011
    
    
  
Ok committed fix. Should have been using the *8th* capture group. It's because you can have non capturing subgroups in extended regex syntax, the expression was correct, the capture group used wasn't.
-Arran
On 19 Aug 2011, at 16:09, Alexander Clouter wrote:
> For 802.11 sessions Called-Station-Id is typically 
> '00-11-22-33-44-55:foobar'.  However, after calling 
> rewrite.called_station_id it is re-written to 
> '00-11-22-33-44-55::foobar' as the regex grouping captures the ':' too.
> 
> The patch below prevents the addition of this extra.
> 
> Signed-off-by: Alexander Clouter <alex at digriz.org.uk>
> 
> diff --git a/raddb/policy.conf b/raddb/policy.conf
> index 73b1951..ece72b1 100644
> --- a/raddb/policy.conf
> +++ b/raddb/policy.conf
> @@ -171,7 +171,7 @@ policy {
> 			# SSID component?
> 			if ("%{7}") {
> 				update request {
> -					Called-Station-Id := "%{Called-Station-Id}:%{7}"
> +					Called-Station-Id := "%{Called-Station-Id}%{7}"
> 				}
> 			}
> 			updated
> 
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/devel.html
> 
Arran Cudbard-Bell
a.cudbardb at freeradius.org
RADIUS - Half the complexity of Diameter
    
    
More information about the Freeradius-Devel
mailing list