Incoming Calls - 401 Unauthorised

Hi,

Freepbx 13.0.190.19 with Asterisk v13.14.0

I’m having a problem with incoming calls being rejected with a 401 Unauthorised message. Outgoing calls work fine.

I’ve put a packet sniffer on the link and can see the SIP Invite packet being received, the Freepbx server is responding with a 401 Unauthorised reply. I’ve looked in the full log but nothing is written to the log re the incoming call.

I’ve tried disabling the freepbx firewall but that didn’t make any difference.

Can anyone suggest how I can further troubleshoot this issue ?

Any help greatly appreciated.

Working from memory, but it seems to me that the first connect attempt is (always/usually) responded to with an “unauthorized”. It seems to be this is supposed to trigger the username/password process at the requesting end.

Solved, problem was in one of the parameters in the Incoming SIP settings set on the trunk.

Bit strange nothing was logged in the Asterisk log.

having the same problem can you pls share the parameters that have the problem

chansip trunk?

Try insecure=invite

Yes is a Chan sip trunk
i have try the insecure=invite what ATT tells me is that when they try to send the call my pbx send a 401 unauthorized. this is my confi so far.

outgoing
peer details

host=172.31.xx.xx
username=787xxxxxxx
secret=xxxxxx
type=peer

incoming

User details

secret=764580
type=user
context=from-trunk
insecure=invite

Register String

xxxxxxxxxx:[email protected]

Try below and delete incoming user details entirely.
Leave registration string.

    outgoing
    peer details

    host=172.31.xx.xx
    username=787xxxxxxx
    remotesecret=xxxxxx
    type=friend
    context=from-trunk



Register String

xxxxxxxxxx:[email protected]

Thanks It works like a sharm

calls start to get in but no sound after the 4th try won get in any more i’m rebooting the apliance

done all it neede was areboot

That would be a different problem

Wanted8000Jose
14h

done all it need it was a reboot