8 Replies Last post: Jun 20, 2008 1:16 AM by illizit  
Click to view illizit's profile   8 posts since
Jun 18, 2008

Jun 19, 2008 3:35 AM

incoming routes


Hello.

I finally got my trunks to register. This issue I currently have is when a incoming call is received opensbc replies back with Internal Server Error 500.

Here is the invite:


U 64.34.181.47:5060 -> 204.13.XX.XX:5066
INVITE sip:78621XXX@204.13.XX.XX:5066 SIP/2.0
Via: SIP/2.0/UDP 64.34.181.47:5060;branch=z9hG4bK68d77e9c;rport
From: "NOT FOUND" <sip:13052XXXXX@64.34.181.47>;tag=as1941af79
To: <sip:78621XXXX@204.13.XX.XX:5066>
Contact: <sip:130529XXX@64.34.181.47>
Call-ID: 046e8d7b24d7315c5074495a46fb29ba@64.34.181.47
CSeq: 102 INVITE
User-Agent: LES.NET.VoIP
Max-Forwards: 70
Date: Thu, 19 Jun 2008 07:30:16 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Content-Type: application/sdp
Content-Length: 317

Then opensbc responds back with:


U 204.13.XX.XX:5066 -> 64.34.181.47:5060
SIP/2.0 500 Internal Server Error
From: "NOT FOUND" <sip:1305XXXXXX@64.34.181.47>;tag=as1941af79
To: <sip:7862XXXXX@204.13.XX.XX:5066>;tag=c298d0d21d3cdd119638a704fbd83836
Via: SIP/2.0/UDP 64.34.181.47:5060;branch=z9hG4bK68d77e9c;rport=5060;received=64.34.181.47
CSeq: 102 INVITE
Call-ID: 046e8d7b24d7315c5074495a46fb29ba@64.34.181.47
Content-Length: 0


In my trunk configuration I have inbound route=sip:XXXX@sip.mydomain.com (which is a registered UA on the same server)

The URI the provider sends is the exact URI in my configuration. I have restarted multiple times to no avail :(

Any help is appreciated!

Thanks

Click to view joegen's profile   87 posts since
Apr 28, 2007
1. Jun 19, 2008 9:11 PM in response to: illizit
Re: incoming routes
It won't work for this INVITE. SIPTrunks are identified through their domains. In your previous post you indicated that the domain is sip-domain="did.les.net". This should be the same domain that your provider should use in the TO-URI for inbound calls. Instead they sent sip:78621XXXX@204.13.XX.XX:5066 which is obviously the contact address.

Joegen


illizit wrote:

Hello.

I finally got my trunks to register. This issue I currently have is when a incoming call is received opensbc replies back with Internal Server Error 500.

Here is the invite:


U 64.34.181.47:5060 -> 204.13.XX.XX:5066
INVITE sip:78621XXX@204.13.XX.XX:5066 SIP/2.0
Via: SIP/2.0/UDP 64.34.181.47:5060;branch=z9hG4bK68d77e9c;rport
From: "NOT FOUND" <sip:13052XXXXX@64.34.181.47>;tag=as1941af79
To: <sip:78621XXXX@204.13.XX.XX:5066>
Contact: <sip:130529XXX@64.34.181.47>
Call-ID: 046e8d7b24d7315c5074495a46fb29ba@64.34.181.47
CSeq: 102 INVITE
User-Agent: LES.NET.VoIP
Max-Forwards: 70
Date: Thu, 19 Jun 2008 07:30:16 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
Content-Type: application/sdp
Content-Length: 317

Then opensbc responds back with:


U 204.13.XX.XX:5066 -> 64.34.181.47:5060
SIP/2.0 500 Internal Server Error
From: "NOT FOUND" <sip:1305XXXXXX@64.34.181.47>;tag=as1941af79
To: <sip:7862XXXXX@204.13.XX.XX:5066>;tag=c298d0d21d3cdd119638a704fbd83836
Via: SIP/2.0/UDP 64.34.181.47:5060;branch=z9hG4bK68d77e9c;rport=5060;received=64.34.181.47
CSeq: 102 INVITE
Call-ID: 046e8d7b24d7315c5074495a46fb29ba@64.34.181.47
Content-Length: 0


In my trunk configuration I have inbound route=sip:XXXX@sip.mydomain.com (which is a registered UA on the same server)

The URI the provider sends is the exact URI in my configuration. I have restarted multiple times to no avail :(

Any help is appreciated!

Thanks

Click to view joegen's profile   87 posts since
Apr 28, 2007
3. Jun 19, 2008 10:57 PM in response to: illizit
Re: incoming routes
Let us say your REGISTER to your provider looks like this

REGISTER sip:1111@proxy.yourprovider.com SIP/2.0
To: sip:1111@yourprovider.com;tag=12345
From: sip:1111@yourprovider.com
Contact: sip:1111@10.0.0.1:5066

then your provider should send the INVITE as follows

INVITE sip:1111@10.0.0.1:5066 SIP/2.0
To: sip:1111@yourprovider.com;tag=6789
From: sip:compliant-provider@yourprovider.com

This is simply how it works now in OSBC SIP Trunking. OpenSBC will take the domain from the To-URI and match it to the trunk you specified in the XML config.

illizit wrote:

All three providers (including gafachi) use this standard. Are you telling me it's not compatible?

The TO field, I thought, was supposed to be used for the number that was dialed.

For instance, if I call from my cell phone 55555 to the number 88888, then TO should be: TO:88888@openbcserver.com and FROM should be: FROM:55555@yourprovider.com

Click to view joegen's profile   87 posts since
Apr 28, 2007
5. Jun 20, 2008 12:02 AM in response to: illizit
Re: incoming routes
illizit wrote:
Is there a specific reason why it works like this?

RFC 3261
10.3 Processing REGISTER Requests

5. The registrar extracts the address-of-record from the To header
field of the request. If the address-of-record is not valid
for the domain in the Request-URI, the registrar MUST send a
404 (Not Found) response and skip the remaining steps. The URI
MUST then be converted to a canonical form. To do that, all
URI parameters MUST be removed (including the user-param), and
any escaped characters MUST be converted to their unescaped
form. The result serves as an index into the list of bindings

I simply mean your provider is not sending the correct AOR it got from the REGISTER request. And that correct AOR processing is vital for OSBC SIP Trunking operation.

If not, do you know which part of the code this sip trunking is in so I can modify it? According to this website, the from tag in a sip packet should say where the call originated from and the to tag should be the uri of where it is going.


See:

B2BUAConnection * SBCSIPTrunkEndPoint::OnCreateB2BUA(
const SIPMessage & request,
const OString & sessionId,
B2BUACall * /*call*/
)

Feel free to send in patches.
Click to view joegen's profile   87 posts since
Apr 28, 2007
7. Jun 20, 2008 1:08 AM in response to: illizit
Re: incoming routes
It should be something like below:

INVITE sip:1518421590@204.13.7.33:5066 SIP/2.0 ;tag=920ef16ccc3cdd119562d496dbc76295
To: sip:1518421590@did.voip.les.net illizit wrote:

Hmm. ok.

Thanks for the help! Sorry to keep bothering however, what exactly should the provider be sending?

Here is my SIP Register packet to the provider:

204.13.X.XX:5066 -> 64.34.181.47:5060
REGISTER sip:did.voip.les.net SIP/2.0..
From: <sip:1518421590@did.voip.les.net>;tag=920ef16ccc3cdd119562d496dbc76295..
To: sip:1518421590@did.voip.les.net..Via: SIP/2.0/UDP 204.13.7.33:5066;iid=9578;branch=z9hG4bKa6d1f36fcc3cdd119562d496dbc76295;uas-addr=64.34.181.47;rport..CSeq: 2 REGISTER..
Call-ID:1c11f16c-cc3c-dd11-96d4-d496dbc76295@did.voip.les.net..
Contact: <sip:1518421590@204.13.7.33:5066;transport=udp>..
User-Agent: ..Expires: 3600..Max-Forwards: 70..Authorization: Digest username="1518421590", realm="did.voip.les.net", nonce="3b131f7f", uri="sip:did.voip.les.net", response="e62e92397699
10e84475b05d72ac35e6", opaque="", algorithm=MD5..Allow: INVITE, BYE, ACK, R
EFER, MESSAGE, INFO, NOTIFY, OPTIONS, PRACK..Content-Length: 0....
#


According to my register packet, what should the provider be sending me?

Thanks