< Previous by Date Date Index Next by Date >
< Previous in Thread Thread Index Next in Thread >

Re: [reSIProcate] crash on mailformed From field.


Why is std::terminate being called the moment an exception is thrown, I wonder? At worst, this might have resulted in an abort due to an unhandled exception (we do catch these, so even that should not have happened).

Best regards,
Byron Campen

On Mar 14, 2013 7:04 AM, <roman.romanchenko@xxxxxxxxxxxx> wrote:
Dear resiprocate devels.

I have the following issue.

resiprocate 1.8.5

On receiving the first REGISTER message with mailformed From field included extra space before ">", my application based on resiprocate crashes into core.
Here is an example: 'From: <sip:XXXXX@xxxxxxxxxxxx >'

I expect that TransactionState::process would handle this in place where calling getTransactionId() and print something to log or call handleBadRequest()

Please advice.

Many thanks.

gdb stack for more details:

#0  0x0000003c524328a5 in raise () from /lib64/libc.so.6
#1  0x0000003c52434085 in abort () from /lib64/libc.so.6
#2  0x0000003c554bea5d in __gnu_cxx::__verbose_terminate_handler() () from /usr/lib64/libstdc++.so.6
#3  0x0000003c554bcbe6 in ?? () from /usr/lib64/libstdc++.so.6
#4  0x0000003c554bcc13 in std::terminate() () from /usr/lib64/libstdc++.so.6
#5  0x0000003c554bcd0e in __cxa_throw () from /usr/lib64/libstdc++.so.6
#6  0x0000003c5d63fb8a in resip::ParseBuffer::fail (this=0x7f5cf3ffe180, file=0x3c5d66493f "ParseBuffer.cxx", line=62, detail=<value optimized out>) at ParseBuffer.cxx:964
#7  0x0000003c5d6406bc in resip::ParseBuffer::skipChar (this=0x7f5cf3ffe180, c=62 '>') at ParseBuffer.cxx:62
#8  0x0000003c5eedbaf9 in resip::NameAddr::parse (this=0x7f5c5d96ba60, pb=...) at NameAddr.cxx:241
#9  0x0000003c5ef27d9c in resip::LazyParser::doParse (this=<value optimized out>) at LazyParser.cxx:79
#10 0x0000003c5eed6af0 in checkParsed (this=0x7f5c5d96ba60, paramType=...) at ../../resip/stack/LazyParser.hxx:106
#11 resip::NameAddr::exists (this=0x7f5c5d96ba60, paramType=...) at NameAddr.cxx:434
#12 0x0000003c5ef61266 in resip::SipMessage::compute2543TransactionHash (this=0x7f5c5d96b4c0) at SipMessage.cxx:424
#13 0x0000003c5ef61e28 in resip::SipMessage::getTransactionId (this=0x7f5c5d96b4c0) at SipMessage.cxx:357
#14 0x0000003c5ef8641a in resip::TransactionState::process (controller=..., message=0x7f5c5d96b4c0) at TransactionState.cxx:468
#15 0x0000003c5ef77720 in resip::TransactionController::process (this=0x563ffa0, timeout=<value optimized out>) at TransactionController.cxx:141
#16 0x0000003c5ef69f81 in resip::TransactionControllerThread::thread (this=0x3e81460) at ../../resip/stack/TransactionControllerThread.hxx:30
#17 0x0000003c5d646e3a in threadIfThreadWrapper (threadParm=<value optimized out>) at ThreadIf.cxx:51
#18 0x0000003c52c07851 in start_thread () from /lib64/libpthread.so.0
#19 0x0000003c524e811d in clone () from /lib64/libc.so.6

_______________________________________________
resiprocate-devel mailing list
resiprocate-devel@resiprocate.org
https://list.resiprocate.org/mailman/listinfo/resiprocate-devel