Hello. I have an Asterisk 16 installation that I’m converting from chan_sip to pjsip. It has two Vitelity subaccount registrations, which both appear to be registering correctly, both on port 5060.
vitelity-1234-reg/sip:firstname.lastname@example.org vitelity-1234-auth-outbound Registered
vitelity-5678-reg/sip:email@example.com vitelity-5678-auth-outbound Registered
I can send a call to 5678 but 1234 will fail with “401 Unauthorized”. If I comment out 5678 and reload pjsip, calls will go through to 1234 just fine, so that tells me that both accounts can receive calls. It appears that the last one that registers is the one that works. This didn’t happen with chan_sip() so I’m assuming I just have something wrong in my configs.
Looking at the SIP logs for the failed call, the correct username, xxxx_1234, is being sent in the authorization but then is rejected:
[2021-10-08 16:55:54] NOTICE: res_pjsip/pjsip_distributor.c:672 log_failed_request: Request ‘INVITE’ from ‘"[V] 1112223333" sip:firstname.lastname@example.org’ failed for ‘22.214.171.124:5060’ (callid: email@example.com) - Failed to authenticate
SIP/2.0 401 Unauthorized
I can post anything relevant that might be needed. Just let me know. If this rings a bell with anyone, just point me in the right direction. Thank you!