Outgoing call via SIP trunk problem

Hello guys,
I will appreciate any help. My problem:

I trying to connect to my VoIP provider. Registration seems to be OK, Incoming calls work fine too. But outgoing calls does not.

My setting in sip.conf:

register => username:password@provider.domain/provider's_number

[random_name]
type=peer
username=username
secret=password
host=provider.domain
port=5060
context=From-VoIP
insecure=port,invite
canreinvite=no
disallow=all
allow=alaw
bindport=5060
qualify=yes
qualifyfreq=60

extensions.conf:
[out-to-international]
exten => _X., 1, Dial(SIP/random_name/${EXTEN})
   - There I also tried: 
   exten => _X., 1, Dial(SIP/${EXTEN}@random_name)
 - And also almost every combination 

But the result is always same:

NOTICE[2758]: chan_sip.c:21337 handle_response_invite: Failed to authenticate on INVITE to '"My server" <sip:100@IP_of_my_PBX>;tag=as6a9d2792'
    -- SIP/random_name-00000063 is circuit-busy
  == Everyone is busy/congested at this time (1:0/1/0)
    -- Auto fallthrough, channel 'SIP/100-00000062' status is 'CONGESTION'

In wireshark i see this message:
407 proxy Authentication message Required, so I send INVITE with Proxy-Authorization, but after that I got 503 Service unaviable response.

So I’m obviously doing something wrong with registration, but I can not figure out what. How Proxy-Authorization header should looks like? Especialy Authentication uri.

I’ve got:
“sip:username@provider.domain” or “sip:provider’s_number@provider.domain” or “sip:number_which_I_calling@provider.domain”
depends on how I configure Dial func in extension.conf

Thanks for any reply, I’m lost with that

Firstly, you should not be persisting in trying to make an unsupported driver that will be completely removed in 2023 work; you should be using chan_pjsip.

My best guess is that it wants fromuser setting.

username is essentially useless if you are doing the registering.

Although you will need insecure=invite (although remotesecret is a better approach), you are unlikely to need insecure=port.

canreinvite was renamed to directmedia about a decade ago

You haven’t configured an authorisation section, so I wouldn’t expect proxy authentication to work, except maybe by treating it like user agent authentication.

Thank you for reply,
I know that about pjsip and in common mounths I’d like to use it in newer systems.

Thank you for answer,
I know about pjsip and in the following months I would like to use it in newer systems.

Unfortunately provider told me I should not use fromuser.
I changed insecure to invite only

And that is maybe the problem - configuration of authorisation section. But can you be more specific? How should I configure it?

and also: when I run sip reload I always see the line:

doing dnsmgr_lookup for ‘provider.domain’
So it look like the DNS translation does not work am I right? How can I fix this?

Thanks for advices I’m really frustrated about this problem with this concrete trunk

It’s actually authentication. I was going from memory.

Details depend on your provider, and your account with them.

Thank you David!
I’ve never seen that before (sad sigh).
But it looks like exactly same as register string. So I filled with same data as register string and Whoohuuuu it’s working!!

So thank you very much for solving this! It took me few long night

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.