999_asterisk_err.py 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. import inc_sip as sip
  2. import inc_sdp as sdp
  3. # http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/2008-June/003426.html:
  4. #
  5. # Report in pjsip mailing list on 27/6/2008 that this message will
  6. # cause pjsip to respond with 500 and then second request will cause
  7. # segfault.
  8. complete_msg = \
  9. """INVITE sip:5001@192.168.1.200:5060;transport=UDP SIP/2.0
  10. Via: SIP/2.0/UDP 192.168.1.11:5060;branch=z9hG4bK74a60ee5;rport
  11. From: \"A user\" <sip:66660000@192.168.1.11>;tag=as2858a32c
  12. To: <sip:5001@192.168.1.200:5060;transport=UDP>
  13. Contact: <sip:66660000@192.168.1.11>
  14. Call-ID: 0bc7612c665e875a4a46411442b930a6@192.168.1.11
  15. CSeq: 102 INVITE
  16. User-Agent: Asterisk PBX
  17. Max-Forwards: 70
  18. Date: Fri, 27 Jun 2008 08:46:47 GMT
  19. Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY
  20. Supported: replaces
  21. Content-Type: application/sdp
  22. Content-Length: 285
  23. v=0
  24. o=root 4236 4236 IN IP4 192.168.1.11
  25. s=session
  26. c=IN IP4 192.168.1.11
  27. t=0 0
  28. m=audio 14390 RTP/AVP 0 3 8 101
  29. a=rtpmap:0 PCMU/8000
  30. a=rtpmap:3 GSM/8000
  31. a=rtpmap:8 PCMA/8000
  32. a=rtpmap:101 telephone-event/8000
  33. a=fmtp:101 0-16
  34. a=silenceSupp:off - - - -
  35. a=ptime:20
  36. a=sendrecv
  37. """
  38. sendto_cfg = sip.SendtoCfg( "Asterisk 500", "--null-audio --auto-answer 200",
  39. "", 200, complete_msg=complete_msg)