When we pass the Invite message to stack, has a Proxy-Authorization header with invalid value, it hangs, due to this our application is also become unresonsive.
In our application when we called the API parseAllHeaders with following Invite message, stack is got hang.
INVITE sip:[service]@[remote_ip]:[remote_port] SIP/2.0
Via: SIP/2.0/[transport] [local_ip]:[local_port];branch=[branch]
From: "sut" <sip:7777@[local_ip]:[local_port]>;tag=[call_number]
CSeq: 1 INVITE
User-Agent: SIP Test Suite
Proxy-Authorization: Digest =AKAv0-MD5
o=user1 53655765 2353687637 IN IP4 127.0.0.1
c=IN IP4 [media_ip]
m=audio [media_port] RTP/AVP 0 8 18
Please look into the issue ASAP and let me know how to solve this issue.
Please find the backtrace of the above issue :
0x001b2d39 in resip::Auth::parseAuthParameters (this=0x9808960, pb=@0xbfe4ef5c) at ../../rutil/ParseBuffer.hxx:172
172 if (cs.test((unsigned char)(*mPosition)))
#0 0x001b2d39 in resip::Auth::parseAuthParameters (this=0x9808960, pb=@0xbfe4ef5c) at ../../rutil/ParseBuffer.hxx:172
#1 0x001b319c in resip::Auth::parse (this=0x9808960, pb=@0xbfe4ef5c) at Auth.cxx:80
#2 0x0023dcf5 in resip::LazyParser::doParse (this=0x9808960) at LazyParser.cxx:79
#3 0x00227c9c in resip::ParserContainer<resip::Auth>::parseAll (this=0x9808928) at ../../resip/stack/LazyParser.hxx:106
#4 0x00293fb9 in resip::SipMessage::parseAllHeaders (this=0x9806880) at SipMessage.cxx:312
Did you have assertions enabled (not compiled with NDEBUG)?
I think that I have seen an assertion failure occur with such issues if assertions are enabled.
Is this fixed by commit b7429f08e051670205bb2a4e050fb7866878d483 ?
I observed something like this in a case where username="", not sure if the stack trace was the same however as it was a while ago. I just tried to reproduce it with 1.10.0-1 and it doesn't crash. I also tried it with a debug build from the master branch and it doesn't crash/assert either.
Testing adding a reply #1.