[Freeswitch-dev] backslash in call-id
Michael Giagnocavo
mgg at giagnocavo.net
Tue Feb 14 19:40:57 MSK 2012
If you quote backslash, you corrupt data for databases that follow the SQL standard and don’t use backslash. <snarky MySQL comment elided>
This is really more a problem with using a “quote” function instead of proper parameterized queries. I don’t believe it’s possible to accommodate both escaping methods with the same function.
If parameterized queries aren’t possible to do in FS (or too much work), there should probably be some switch that controls backslash handling.
-Michael
From: freeswitch-dev-bounces at lists.freeswitch.org [mailto:freeswitch-dev-bounces at lists.freeswitch.org] On Behalf Of Seven Du
Sent: Wednesday, February 08, 2012 6:55 AM
To: freeswitch-dev
Subject: [Freeswitch-dev] backslash in call-id
Hi,
I have a sip client which generates call-id with backslashes which causing error:
ERR: [insert into sip_registrations ............. values ('<c)X/Iz\'
I looked into
http://sofia-sip.sourceforge.net/refdocs/sip/group__sip__call__id.html
looks like backslash '\' is valid in call-id
so is it ok to to let switch_mprintf %q also quote backslash ?
should I report a jira?
Thanks.
--
About: http://about.me/dujinfang
Blog: http://www.dujinfang.com
Proj: http://www.freeswitch.org.cn
Sent with Sparrow<http://www.sparrowmailapp.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-dev/attachments/20120214/38503cda/attachment.html
Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-dev
mailing list