<div dir="ltr">Hello,<br><br>I&#39;ve a single question about AVPs :<br>how can I use them when loaded from radius_load_attr ?<br><br>example : the 0123452000 is the caller, I want to use an acl to block him.<br><br>=&gt; in my radius user config :<br>
<br><a href="mailto:0123451010@sip.dot.com">0123451010@sip.dot.com</a> &nbsp; User-Password = &quot;0000&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; User-Name = &quot;<a href="mailto:0123451010@sip.dot.com">0123451010@sip.dot.com</a>&quot;,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-UID = &quot;<a href="mailto:0123451010@sip.dot.com">0123451010@sip.dot.com</a>&quot;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-DID = &quot;1&quot;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-From-UID = &quot;<a href="mailto:0123451010@sip.dot.com">0123451010@sip.dot.com</a>&quot;,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-From-DID = &quot;1&quot;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-Digest-Username = &quot;0123451010&quot;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-Digest-Realm = &quot;<a href="http://sip.dot.com">sip.dot.com</a>&quot;,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-Uri-User = &quot;<a href="mailto:0123451010@sip.dot.com">0123451010@sip.dot.com</a>&quot;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-Attr = &quot;acl:pstn&quot;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-Attr = &quot;asserted-id:0123451010&quot;,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-Attr = &quot;phone:0123451010&quot;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SER-Attr = &quot;lang:fr&quot;<br><br clear="all">=&gt; in the SER (v2.0.0) : <br><br>if (!radius_load_attrs(&quot;$fu&quot;, &quot;@f.uri&quot;))<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sl_reply(&quot;403&quot;, &quot;Radius attributes not found&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; exit;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br><br>if ( $acl == &quot;pstn&quot; )<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sl_reply(&quot;401&quot;, &quot;Unauthorized&quot;);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; exit;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br><br>I tried too &quot; $fu.acl &quot;, &quot; set_attr function, ... it seems I can&#39;t use SER-Attr as a variable.<br><br>in the debug (dump_attrs) :<br>...<br>ser[28670]: r_INBOUND:&nbsp;&nbsp; =&gt; dump_attrs()<br>
ser[28670]: INFO: avp.c:542: class=GLOBAL <br>ser[28670]: AVP[&quot;lang&quot;]=&quot;en&quot; <br>ser[28670]: INFO: avp.c:552: track=FROM class=DOMAIN <br>ser[28670]: AVP[&quot;did&quot;]=&quot;1&quot; <br>ser[28670]: AVP[&quot;digest_realm&quot;]=&quot;<a href="http://sip.dot.com">sip.dot.com</a>&quot; <br>
ser[28670]: INFO: avp.c:562: track=TO class=DOMAIN <br>ser[28670]: AVP[&quot;did&quot;]=&quot;1&quot; <br>ser[28670]: AVP[&quot;digest_realm&quot;]=&quot;<a href="http://sip.dot.com">sip.dot.com</a>&quot; <br>ser[28670]: INFO: avp.c:572: track=FROM class=USER <br>
ser[28670]: AVP[&quot;uid&quot;]=&quot;<a href="mailto:0123451010@sip.dot.com">0123451010@sip.dot.com</a>&quot; <br>ser[28670]: AVP[&quot;acl&quot;]=&quot;pstn&quot; <br>ser[28670]: AVP[&quot;asserted-id&quot;]=&quot;0123451010&quot;<br>
ser[28670]: AVP[&quot;lang&quot;]=&quot;fr&quot; <br>ser[28670]: AVP[&quot;phone&quot;]=&quot;0123451010&quot; <br>ser[28670]: AVP[&quot;acl&quot;]=&quot;pstn&quot; <br>ser[28670]: AVP[&quot;asserted-id&quot;]=&quot;0123451010&quot;<br>
ser[28670]: AVP[&quot;lang&quot;]=&quot;fr&quot;<br>ser[28670]: AVP[&quot;phone&quot;]=&quot;0123451010&quot; <br>ser[28670]: INFO: avp.c:582: track=TO class=USER <br>ser[28670]: AVP[&quot;acl&quot;]=&quot;pstn&quot; <br>
ser[28670]: AVP[&quot;asserted-id&quot;]=&quot;0123451005&quot;<br>ser[28670]: AVP[&quot;lang&quot;]=&quot;fr&quot;<br>ser[28670]: AVP[&quot;phone&quot;]=&quot;0123451005&quot; <br>ser[28670]: AVP[&quot;acl&quot;]=&quot;pstn&quot; <br>
ser[28670]: AVP[&quot;asserted-id&quot;]=&quot;0123451005&quot;<br>ser[28670]: AVP[&quot;lang&quot;]=&quot;fr&quot;<br>ser[28670]: AVP[&quot;phone&quot;]=&quot;0123451005&quot; <br>ser[28670]: INFO: avp.c:592: track=FROM class=URI <br>
ser[28670]: AVP[&quot;uac_nat&quot;]=1 <br>ser[28670]: AVP[&quot;account&quot;]=&quot;yes&quot; <br>ser[28670]: INFO: avp.c:602: track=TO class=URI <br>ser[28670]: INFO: No AVP present <br>...<br><br>If anyone has tips to help me, many thanks !<br>
<br>I&#39;m sure there&#39;s something who replaces the old group_radius module, but which one or how to create SER-Attr $grp ?<br><br><br>Many thanks,<br><br>-- <br>Samuel MULLER<br><a href="mailto:sml@720.fr">sml@720.fr</a><br>

</div>