Yate Community Forum

Yate server => Other Yate server issues => Topic started by: abma on December 08, 2015, 01:16:18 PM

Title: How to escape ; in regexroute.conf?
Post by: abma on December 08, 2015, 01:16:18 PM
i want yate to send a NOTIFY message when 9999 is called to the caller. ( http://wiki.snom.com/FAQ/How_to_trigger_the_phone_to_synchronize_its_settings_via_mass_deployment )

this basicly works but i'm having a problem getting a ; into the message:

Code: [Select]
[default]
^9999$=rename xsip.generate;\
method=NOTIFY;uri=\1;sip_From=<sip:${caller}@${domain$nosuch.dom}>;\
xsip_type=${type$text/plain};xsip_body_encoding=${body_encoding};\
sip_Event=check-sync\;reboot=true

this results in everything after \ beeing dropped.

how can ; be escaped?
Title: Re: How to escape ; in regexroute.conf?
Post by: marian on December 10, 2015, 01:45:37 AM
See $(chr,CHAR_NUM) function.
; can be set using $(chr,59)
Title: Re: How to escape ; in regexroute.conf?
Post by: abma on December 10, 2015, 10:40:49 AM
oh, i didn't expect that a function has to be used.

its even simpler, from http://docs.yate.ro/wiki/Regular_expressions:

Quote
$() = a ; character

thanks!