Simplify PAP auth - hardcode password to test basic flow
Single processor with hardcoded password "test" to verify PAP works. Removed Acct-Interim-Interval (not in dictionary). Once PAP works, will add attributes lookup. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
16
cgrates.json
16
cgrates.json
@@ -81,27 +81,15 @@
|
||||
"*default": ["/usr/share/cgrates/radius/dict/"]
|
||||
},
|
||||
"request_processors": [
|
||||
{
|
||||
"id": "AuthGetPassword",
|
||||
"filters": ["*string:~*vars.*radReqType:*radAuth"],
|
||||
"flags": ["*message", "*attributes", "*continue", "*log"],
|
||||
"request_fields": [
|
||||
{"tag": "Account", "path": "*cgreq.Account", "type": "*composed", "value": "~*req.User-Name", "mandatory": true},
|
||||
{"tag": "PasswordFromAttributes", "path": "*cgreq.PasswordFromAttributes", "type": "*constant", "value": "*attributes"}
|
||||
],
|
||||
"reply_fields": [
|
||||
{"tag": "SessionTimeout", "path": "*rep.Session-Timeout", "type": "*constant", "value": "3600"},
|
||||
{"tag": "AcctInterimInterval", "path": "*rep.Acct-Interim-Interval", "type": "*constant", "value": "60"}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "AuthPAP",
|
||||
"filters": ["*string:~*vars.*radReqType:*radAuth"],
|
||||
"flags": ["*radauth", "*pap", "*log"],
|
||||
"request_fields": [
|
||||
{"tag": "UserPassword", "path": "*vars.UserPassword", "type": "*variable", "value": "~*cgrep.Attributes.Password"}
|
||||
{"tag": "UserPassword", "path": "*vars.UserPassword", "type": "*constant", "value": "test"}
|
||||
],
|
||||
"reply_fields": [
|
||||
{"tag": "SessionTimeout", "path": "*rep.Session-Timeout", "type": "*constant", "value": "3600"},
|
||||
{"tag": "ReplyOnError", "filters": ["*notempty:~*cgrep.Error:"], "path": "*rep.*radReplyCode", "type": "*constant", "value": "AccessReject"},
|
||||
{"tag": "ReplyMessage", "filters": ["*notempty:~*cgrep.Error:"], "path": "*rep.Reply-Message", "type": "*variable", "value": "~*cgrep.Error"}
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user