[OpenSIPS-Users] MS teams
Andrew Colin
andrewd.colin at gmail.com
Thu Sep 17 15:33:55 EST 2020
nope :(
here is the full content
####### Routing Logic ########
# main request routing logic
# Checks from MS Teams
local_route {
$var(dst) = "pstnhub.microsoft.com";
if (is_method("OPTIONS") && ($(ru{s.index, $var(dst)}) != NULL))
append_hf("Contact: <sip:mydomain.com:5061;transport=tls>\r\n");
}
if (is_method("OPTIONS") && is_domain_local("$rd") &&
check_source_address("2")) {
xlog("L_INFO",
"[MS TEAMS] OPTIONS In");
send_reply("200", "OK");
exit;
}
route{
On Thu, Sep 17, 2020 at 4:32 PM Ben Newlin <Ben.Newlin at genesys.com> wrote:
> Check the line **before** that snippet. You might be missing a `;` or a
> closing brace.
>
>
>
> Ben Newlin
>
>
>
> *From: *Users <users-bounces at lists.opensips.org>
> *Date: *Thursday, September 17, 2020 at 11:27 AM
> *To: *OpenSIPS users mailling list <users at lists.opensips.org>
> *Subject: *Re: [OpenSIPS-Users] MS teams
>
> The only thing I can see there is there's no newline ending in the log
> content. Don't know if that matters though.
>
>
>
> On Thu, 2020-09-17 at 16:13 +0100, Andrew Colin wrote:
>
> Hi Guys
>
>
>
> i am trying to setup ms teams routing but keep getting this error on
> opensips 3.1
>
> it doesnt seem to like my config below
>
>
>
> if(is_method("OPTIONS") && is_domain_local("$rd") &&
> check_source_address("2")) {
>
> xlog("L_INFO", "[MS TEAMS] OPTIONS In");
>
> send_reply("200", "OK");
>
> exit;
>
> }
>
>
>
> Sep 17 15:11:47 [4341] INFO:tls_mgm:mod_load: openssl version: OpenSSL
> 1.1.1d 10 Sep 2019
>
> Sep 17 15:11:47 [4341] Traceback (last included file at the bottom):
>
> Sep 17 15:11:47 [4341] 0. /etc/opensips/opensips.cfg
>
> Sep 17 15:11:47 [4341] CRITICAL:core:yyerror: parse error in
> /etc/opensips/opensips.cfg:151:1-3: syntax error
>
> Sep 17 15:11:47 [4341]
>
> Sep 17 15:11:47 [4341] # Checks from MS Teams
>
> Sep 17 15:11:47 [4341] if(is_method("OPTIONS") && is_domain_local("$rd")
> && check_source_address("2")) {
>
> Sep 17 15:11:47 [4341] ^~~
>
> Sep 17 15:11:47 [4341] xlog("L_INFO", "[MS TEAMS] OPTIONS In");
>
> Sep 17 15:11:47 [4341] send_reply("200", "OK");
>
> Sep 17 15:11:47 [4341] CRITICAL:core:yyerror: parse error in
> /etc/opensips/opensips.cfg:151:1-3:
>
> Sep 17 15:11:47 [4341] ERROR:core:parse_opensips_cfg: bad config file (2
> errors)
>
> Sep 17 15:11:47 [4341] ERROR:core:main: failed to parse config file (null)
>
> Sep 17 15:11:47 [4341] NOTICE:core:main: Exiting....
>
> _______________________________________________
>
> Users mailing list
>
> <Users at lists.opensips.org>
>
> *Users at lists.opensips.org <Users at lists.opensips.org>*
>
>
>
>
>
> <http://lists.opensips.org/cgi-bin/mailman/listinfo/users>
>
> *http://lists.opensips.org/cgi-bin/mailman/listinfo/users <http://lists.opensips.org/cgi-bin/mailman/listinfo/users>*
>
>
>
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20200917/0d6e5ec3/attachment-0001.html>
More information about the Users
mailing list