问题
I am working on a sip client. I'm monitoring with wireshark the sip packets.
Register with the sip server works fine
When making a call I have this:
Client - INVITE message Server - 401 UNAUTHORIZED Client - INVITE message Server - 403 Forbidden
I do not have access to the server. What could go wrong? Why can't I make a call?
What is with that 401 and than 403 if registered worked ok?
回答1:
That is noramal. Server ask for authorization(401). After that it say authorization incorrect.
That is normal behavour for any of this:
1) You use incorrect secret for this username
2) You use domain name/realm which is incorrect and domain name/realm is set on server.
If registration work ok, can be
1) Server work with registration different way - contact server support
2) You dialling in incorrect format or this number not allowed to call with your extension.
回答2:
Another reason for that error: device trying to register is not sending authentication.
while the server may request authentication
来源:https://stackoverflow.com/questions/18955400/sip-making-a-call-401-unauthorized