Hello,
I guess you are using openser 1.1.0, bu the config is still for the
1.0.x in some cases. See:
If I am right with my assumption, then you have to change: $adresa in
$avp(adresa) in avp_check(). Also, there looks to be a mistake, you
compare the avp it itself.
Cheers,
Daniel
On 12/22/06 13:35, Zoran Milic wrote:
Hi guys,
I am trying to set up radius and avp for ages now, and this time i
think i am close to it. I have a problem and I can't find any
information about it.
The thing is, my soft agent (set to uid 101) can't register, and it
is getting "Forbidden IP" even with this in the cfg file (see below) I
have set up freeradius and radiusclient-ng according to the manual on
http://www..openser.org/docs/openser-radius-1.0.x.html
<http://www.openser.org/docs/openser-radius-1.0.x.html>. I can't find
anything on the error i am getting in my log. If you need my complete
.cfg or log file, just ask, and I will send them promptly.
thanks
in advance, best regards, Zoran
*openser.cfg:*
...
xlog("L_ERR","rpid = $avp(s:rpid)");
xlog("L_ERR","adresa = $avp(s:adresa)");
xlog("L_ERR","adresa2 = $avp(s:adresa2)");
# check the src ip address
# avp_load_radius("caller");
if(!avp_check("$adresa", "eq/$adresa/ig"))
{
sl_send_reply("403", "Forbidden IP");
exit;
};
save("location");
exit;
};
...
*freeradius/users:*
...
101 Auth-Type := Digest, User-Password == "101"
Reply-Message = "Authenticated",
Sip-Avp += "rpid:101",
Sip-Avp += "adresa:10.0.0.157",
Sip-Avp += "adresa2:10.0.0.157"
...
*last entries in the log after the rejected register.
*...
DEBUG:auth_radius:extract_avp: AVP val is <10.0.0.157>
DEBUG:auth_radius:generate_avps: AVP 'adresa'/0='10.0.0.157'/0 has
been added
DEBUG:auth_radius:extract_avp: string is <adresa2:10.0.0.157>
DEBUG:auth_radius:extract_avp: AVP name is <adresa2>
DEBUG:auth_radius:extract_avp: AVP val is <10.0.0.157>
DEBUG:auth_radius:generate_avps: AVP 'adresa2'/0='10.0.0.157'/0 has
been added
DEBUG:auth_radius:extract_avp: string is <rpid:101>
DEBUG:auth_radius:extract_avp: AVP name is <rpid>
DEBUG:auth_radius:extract_avp: AVP val is <101>
DEBUG:auth_radius:generate_avps: AVP 'rpid'/0='101'/0 has been added
DEBUG:auth_radius:extract_avp: string is <adresa:10.0.0.157>
DEBUG:auth_radius:extract_avp: AVP name is <adresa>
DEBUG:auth_radius:extract_avp: AVP val is <10.0.0.157>
DEBUG:auth_radius:generate_avps: AVP 'adresa'/0='10.0.0.157'/0 has
been added
DEBUG:auth_radius:extract_avp: string is <adresa2:10.0.0.157>
DEBUG:auth_radius:extract_avp: AVP name is <adresa2>
DEBUG:auth_radius:extract_avp: AVP val is <10.0.0.157>
DEBUG:auth_radius:generate_avps: AVP 'adresa2'/0='10.0.0.157'/0 has
been added
rpid = 101
adresa = 10.0.0.157
adresa2 = 10.0.0.157
xl_get_spec_value: error - null sp->itf
ERROR:avpops:ops_check_avp: cannot get src value
parse_headers: flags=ffffffffffffffff
check_via_address(192.168.52.145, 192.168.52.145, 0)
DEBUG:destroy_avp_list: destroying list 0x404d9238
receive_msg: cleaning up
------------------------------------------------------------------------
_______________________________________________
Users mailing list
Users(a)openser.org
http://openser.org/cgi-bin/mailman/listinfo/users