From ae41322355147b6378ee98892091f6e3dc79b342 Mon Sep 17 00:00:00 2001 From: Junaid Saeed Uppal Date: Tue, 23 Dec 2025 20:42:19 +0500 Subject: [PATCH] Fix attributes filter matching - use named filters MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Changed context from *sessions to *any for all attribute profiles - Created explicit filter definitions in Filters.csv - Changed from inline filters to named filters (FLTR_ACCOUNT_*) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- tariffplans/pppoe/Attributes.csv | 8 ++++---- tariffplans/pppoe/Filters.csv | 4 ++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/tariffplans/pppoe/Attributes.csv b/tariffplans/pppoe/Attributes.csv index bc2ea87..ce5d212 100644 --- a/tariffplans/pppoe/Attributes.csv +++ b/tariffplans/pppoe/Attributes.csv @@ -2,12 +2,12 @@ # PPPoE user credentials and RADIUS reply attributes # User: test - Test user for MikroTik PPPoE -cgrates.org,ATTR_PPPOE_TEST,*sessions,*string:~*req.Account:test,,,,,,false,20 +cgrates.org,ATTR_PPPOE_TEST,*any,FLTR_ACCOUNT_TEST,,,,,,false,20 cgrates.org,ATTR_PPPOE_TEST,,,,,*req.Password,*constant,test,, cgrates.org,ATTR_PPPOE_TEST,,,,,*req.RequestType,*constant,*prepaid,, cgrates.org,ATTR_PPPOE_TEST,,,,,*req.MikrotikRateLimit,*constant,10M/10M,, # User: pppoe_user1 - 10Mbps plan with static IP -cgrates.org,ATTR_PPPOE_USER1,*sessions,*string:~*req.Account:pppoe_user1,,,,,,false,20 +cgrates.org,ATTR_PPPOE_USER1,*any,FLTR_ACCOUNT_USER1,,,,,,false,20 cgrates.org,ATTR_PPPOE_USER1,,,,,*req.Password,*constant,SecurePass123,, cgrates.org,ATTR_PPPOE_USER1,,,,,*req.RequestType,*constant,*prepaid,, cgrates.org,ATTR_PPPOE_USER1,,,,,*req.FramedIPAddress,*constant,10.0.0.101,, @@ -15,7 +15,7 @@ cgrates.org,ATTR_PPPOE_USER1,,,,,*req.FramedIPNetmask,*constant,255.255.255.0,, cgrates.org,ATTR_PPPOE_USER1,,,,,*req.MikrotikRateLimit,*constant,10M/10M,, # User: pppoe_user2 - 20Mbps plan with static IP -cgrates.org,ATTR_PPPOE_USER2,*sessions,*string:~*req.Account:pppoe_user2,,,,,,false,20 +cgrates.org,ATTR_PPPOE_USER2,*any,FLTR_ACCOUNT_USER2,,,,,,false,20 cgrates.org,ATTR_PPPOE_USER2,,,,,*req.Password,*constant,SecurePass456,, cgrates.org,ATTR_PPPOE_USER2,,,,,*req.RequestType,*constant,*prepaid,, cgrates.org,ATTR_PPPOE_USER2,,,,,*req.FramedIPAddress,*constant,10.0.0.102,, @@ -23,7 +23,7 @@ cgrates.org,ATTR_PPPOE_USER2,,,,,*req.FramedIPNetmask,*constant,255.255.255.0,, cgrates.org,ATTR_PPPOE_USER2,,,,,*req.MikrotikRateLimit,*constant,20M/20M,, # User: pppoe_user3 - 50Mbps plan with dynamic IP -cgrates.org,ATTR_PPPOE_USER3,*sessions,*string:~*req.Account:pppoe_user3,,,,,,false,20 +cgrates.org,ATTR_PPPOE_USER3,*any,FLTR_ACCOUNT_USER3,,,,,,false,20 cgrates.org,ATTR_PPPOE_USER3,,,,,*req.Password,*constant,SecurePass789,, cgrates.org,ATTR_PPPOE_USER3,,,,,*req.RequestType,*constant,*prepaid,, cgrates.org,ATTR_PPPOE_USER3,,,,,*req.MikrotikRateLimit,*constant,50M/50M,, diff --git a/tariffplans/pppoe/Filters.csv b/tariffplans/pppoe/Filters.csv index 109c68b..8580a0a 100644 --- a/tariffplans/pppoe/Filters.csv +++ b/tariffplans/pppoe/Filters.csv @@ -1 +1,5 @@ #Tenant,ID,Type,Path,Values,ActivationInterval +cgrates.org,FLTR_ACCOUNT_TEST,*string,~*req.Account,test, +cgrates.org,FLTR_ACCOUNT_USER1,*string,~*req.Account,pppoe_user1, +cgrates.org,FLTR_ACCOUNT_USER2,*string,~*req.Account,pppoe_user2, +cgrates.org,FLTR_ACCOUNT_USER3,*string,~*req.Account,pppoe_user3,