Asterisk IMS TEL protocol for incoming calls not recognized

I am currently using Asterisk 1.6.

Asterisk seems NOT to support incoming TEL connections from an IMS platform.

X-Lite does support this type of call without issue!

Is there any possibility that Asterisk could accept a TEL incoming connection?

Do we need a specific module?

This is currently the error we get: 404 Not Found

Here you find part of an (incoming) INVITE request.

From: tel:0987654321;phone-context=+32987654321;tag=tag-etc
P-Asserted-Identity: tel:0987654321
P-Called-Party-ID: sip:+3212345678@...
Diversion: sip:+3212345678@...;user=phone;reason=“extension”;privacy=“off”;counter=1

Using INVITE request as basis request -
Nov 13 17:52:05 NOTICE[27459]: chan_sip.c:6973 check_user_full: From address missing ‘sip:’, using it anyway

Nov 13 17:52:05 WARNING[27459]: chan_sip.c:6525 get_destination: Huh? Not a SIP header (tel:0987654321;phone-context=+32987654321)?

RDNIS is +3212345678
SIP/2.0 404 Not Found

It is strange that Asterisk seems to recognize the called number (see RDNIS); so why does it reject the call?

The basic problem seems to be that Asterisk only accepts SIP: in the From address and not TEL:

This way the incoming call is rejected!

Does your IMS platform have an option to connect to systems that aren’t RFC 3966 compliant?

Actually I found out that Asterisk is indeed not conform to the RFC 3966 standard.

I have written a patch for Asterisk chan-sip.c to support the TEL URI INVITE standard for incoming calls. Changes in bold.

Now IMS and Asterisk are talking to each other without problems.

When there is no domain as with TEL INVITE we should set name to the calling number (I simply reversed dom and name in the original source for TEL INVITE leaving the domain blank).


if ((c = strchr(uri, ‘@’)) == NULL) {
/* TEL INVITE does not have a domain /
dom = “”;
name = uri;

} else {
SIP INVITE does have a domain */
*c++ = ‘\0’;
dom = c;
name = uri;


if (!strncasecmp(t, “sip:”, 4))
t+= 4;
else if (!strncasecmp(t, “tel:”, 4))
t += 4;

else if (!strncasecmp(t, “sips:”, 5))
t += 5;

if (parse_uri(of, “sip:,tel:,sips:”, &of, &dummy, &domain, &dummy, &dummy, NULL)) {
ast_log(LOG_NOTICE, “From address missing ‘sip:’, using it anyway\n”);


if (!strncasecmp(uri, “sip:”, 4)) {
uri += 4;
} else if (!strncasecmp(uri, “tel:”, 4)) {
uri += 4;
} else if (!strncasecmp(uri, “sips:”, 5)) {
uri += 5;
} else {
ast_log(LOG_WARNING, “Huh? Not a SIP header (%s)?\n”, uri);
return -1;


We only need to stop Asterisk, transfer to production, and restart Asterisk.

Can someone validate and incorporate these changes into the source tree for Asterisk?

There is a section on this page:

about the process for adding new features to Asterisk.


I have posted an Issue, with a patch.

I have exactly the same problem, but I am a newbie, can anyone tell me how to apply the patch or how to locate the files that need editing to allow the TEL invites to be accepted by my asterisk server.

As of mid 2014 this protocol is built into Asterisk 13.

For any earlier versions you need to patch and build from sources yourself… see for details and patches for different versions.