[Users] avp error

jayesh nambiar jayesh_1017 at yahoo.com
Thu Sep 29 12:21:34 CEST 2005


hi bogdan,
Thanks for the help. atleast I got rid of that error but got a new error. I am trying to implement the ACL Bitmap example provided in the avp_docs. The idea is as follows:

 
# 1 - free destination
	# 2 - local call
	# 3 - long distance call
	# 4 - international call
	#
	if(uri=~"sip:0900[0-9]+") /* free destinations */
	{
		if (!avp_check("$acl", "and/i:0x01")
		{
			sl_send_reply("403","Forbidden - Free Destinations Not Allowed");
			return;
		};
	} else if(uri=~"sip:0[1-9][0-9]+") {
		if (!avp_check("$acl", "and/i:0x04")
		{
			sl_send_reply("403","Forbidden - Long Distance Calls Not Allowed");
			return;
		};
	} else if(uri=~"sip:00[1-9][0-9]+") {
		if (!avp_check("$acl", "and/i:0x08")
		{
			sl_send_reply("403","Forbidden - International Calls Not Allowed");
			return;
		};
	} else  {
		if (!avp_check("$acl", "and/i:0x02")
		{
			sl_send_reply("403","Forbidden - Local Calls Not Allowed");
			return;
		};
	};
	
	# authorized

	# rewritehostport("gateway_ip:gateway_port");
	rewritehostport("10.10.10.10:5060");

But now I get the following error:
 
ERROR:avpops:parse_check_value: parse error in <and/i:0x01> pos 3
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: ERROR:avpops:fixup_check_avp: failed to parse checked value
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: ERROR: fix_expr : fix_actions error
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: Binding '2204','sip:2204 at 192.168.2.20:8484' has expired
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: use_table(): Invalid parameter value
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: db_del_ucontact: Error in use_table
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: wb_timer(): Can't delete contact from the database
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: Binding '2207','sip:2207 at 192.168.2.18:8467' has expired
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: use_table(): Invalid parameter value
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: db_del_ucontact: Error in use_table
Sep 29 15:33:31 localhost /usr/local/sbin/openser[15481]: wb_timer(): Can't delete contact from the database

Is there anything wrong with the expression syntax or there could be problem with the entry in the table. Can you pls help me figure it out.
 
thanx in advance.
jayesh

		
---------------------------------
Yahoo! for Good
 Click here to donate to the Hurricane Katrina relief effort. 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kamailio.org/pipermail/users/attachments/20050929/9bcf7fc6/attachment.htm 


More information about the Users mailing list