Patches item #1712764, was opened at 2007-05-04 18:13 Message generated for change (Comment added) made by av_kot You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=743022&aid=1712764&group_id=139143
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: modules Group: ver 1.2.x Status: Open >Resolution: Duplicate Priority: 5 Private: No Submitted By: Alexei Volkov (av_kot) Assigned to: Nobody/Anonymous (nobody) Summary: UAC module Initial Comment: RFC declare that SIP strings (at least From To Remote-Party-Id) can be utf8 encoded, but not all SIP terminals can correctly process that strings when thay are out of latin charset. In this case i want special processing for that uteminals (user-agents). For example i want enaple pass through utf8 for terminals with predefined user agent string and clear or transform for others. I found the way to do it in branch_route handler instead of route handler (due to more than one terminal can be registered under same URI and they can be from different vendors). branch_route[1] { $avp(s:useragent)=""; avp_db_query("select user_agent from location where contact='$ru'","$avp(s:useragent)"); if ($avp(s:useragent)=~"SJphone") {return;}; uac_replace_from("transliterate",""); return; } But uac_replace_from in auc.c declared with REQUEST_ROUTE flag only. With attached patch i can solve proplem with some utf8 buggy sip terminals. I thing that this simple patch will be usefull. ---------------------------------------------------------------------- >Comment By: Alexei Volkov (av_kot) Date: 2007-07-02 22:45 Message: Logged In: YES user_id=1779106 Originator: YES This patch is obsoleted by bug #1739565 https://sourceforge.net/tracker/index.php?func=detail&aid=1739565&group_id=139143&atid=743020 ---------------------------------------------------------------------- Comment By: Klaus Darilion (klaus_darilion) Date: 2007-05-04 18:32 Message: Logged In: YES user_id=1318360 Originator: NO Hi Alexei! if you have NATed clients and you use fix_nated_register() then the SQL query is wrong and should be avp_db_query("select user_agent from location where contact='$ru' and received='$du'","$avp(s:useragent)"); Further, this query is dangerous because of SQL injection, thus you should use transformations (openser >=1.2): avp_db_query("select user_agent from location where contact='$ru.escape.common' and received='$du'","$avp(s:useragent)"); ---------------------------------------------------------------------- Comment By: Alexei Volkov (av_kot) Date: 2007-05-04 18:16 Message: Logged In: YES user_id=1779106 Originator: YES File Added: branch_route_uac.patch ---------------------------------------------------------------------- Comment By: Alexei Volkov (av_kot) Date: 2007-05-04 18:15 Message: Logged In: YES user_id=1779106 Originator: YES File Added: branch_route_auc.patch ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=743022&aid=1712764&group_id=139143 _______________________________________________ Devel mailing list Devel@openser.org http://openser.org/cgi-bin/mailman/listinfo/devel