Commit Graph

1389 Commits

Author SHA1 Message Date
Olle Johansson 725e285bc4 Commit of the new SIP transfer support (oej/siptransfer branch)
- improved support of attended transfers (REFER with replaces)
- support of INVITE/replaces in the context of a transfer
- improved support of blind transfers (REFER)

Thanks to Voop, Nuvio and Foniris for sponsoring this work.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@31274 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-01 07:30:45 +00:00
Russell Bryant 414106a3a6 move the includes of abstract_jb.h to be with the rest of the asterisk includes.
These used to be wrapped in a #ifdef


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@31078 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-31 17:29:12 +00:00
Russell Bryant bb7dd96cfe Add support for using a jitterbuffer for RTP on bridged calls. This includes
a new implementation of a fixed size jitterbuffer, as well as support for the
existing adaptive jitterbuffer implementation. (issue #3854, Slav Klenov)

Thank you very much to Slav Klenov of Securax and all of the people involved
in the testing of this feature for all of your hard work!


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@31052 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-31 16:56:50 +00:00
Joshua Colp 503486e99d OKAY - Only replace our IP address in the outgoing SIP messages if the actual source address is within the specified local network. (issue #7051 reported by Luke-Jr with mods by me)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@31050 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-31 16:31:41 +00:00
Olle Johansson c7007e1f55 Add congestion message to SIP history
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@30992 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-31 14:36:47 +00:00
Olle Johansson bc0f0a3226 Use ast_channel_trylock for channels
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@30990 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-31 14:28:29 +00:00
Kevin P. Fleming f890cab292 Merged revisions 30293 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r30293 | kpfleming | 2006-05-25 12:18:01 -0500 (Thu, 25 May 2006) | 2 lines

allow SIPCHANINFO(peername) to work for calls from users as well (issue #7215)

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@30294 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-25 17:22:26 +00:00
Kevin P. Fleming 57f6093661 don't send CANCEL for an INVITE that we haven't received a provisional response for yet... mark it pending until a response arrives (issue #7079)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@30070 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-24 20:37:45 +00:00
Olle Johansson b8b1fda04c Typo
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@30038 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-24 19:58:36 +00:00
Kevin P. Fleming 3e99be68d1 add a new option for 'obscuring' SIP user/peer names from fishers
use an enum for authentication results and clean up code
fix a bug where SUBSCRIBE for an unknown user/peer would not generate a response


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29903 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-24 03:28:49 +00:00
Kevin P. Fleming b31af470e7 Merged revisions 29764 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r29764 | kpfleming | 2006-05-23 13:16:40 -0500 (Tue, 23 May 2006) | 2 lines

simplify/fix lock retry, and fix comment

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29765 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-23 18:17:40 +00:00
BJ Weschke c4227714fd Sanity check code for an extended failure in trying to obtain a channel lock that may have been obtained elsewhere. Prevents the monitor thread of the SIP module from going into an infinite loop, effectively, breaking SIP until you restart Asterisk or the mutex is unlocked, whichever comes first.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29735 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-23 17:31:05 +00:00
Olle Johansson 16a648aaf1 Breaking once will stop us... :-)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29668 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-23 12:39:48 +00:00
Olle Johansson 883e4d6a9b Code formatting
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29665 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-23 12:14:35 +00:00
Mark Spencer fa9e0ed768 Handle ringing (early) state properly on SIP
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29619 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-23 04:49:31 +00:00
Luigi Rizzo 76c47813fe remove code duplication generating some ast_verbose messages .
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29363 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 03:16:38 +00:00
Luigi Rizzo 82dbf5a4c1 use the functional form of time(), and mark XXX a couple of places
with dubious assignments.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29334 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 02:43:24 +00:00
Luigi Rizzo afe7c46924 more constifications
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29333 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 02:31:58 +00:00
Luigi Rizzo 322aff00c6 various constification of function arguments to prevent erroneous
usage and to ease understanding of the function themselves.




git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29332 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 02:27:33 +00:00
Luigi Rizzo ba195ee2d4 the msg argument of the various transmi_response*() functions is const.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29331 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 02:22:39 +00:00
Luigi Rizzo 75c6b453a3 mark const the 'header' argument of gettag
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29330 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 02:19:14 +00:00
Luigi Rizzo 1a709886e3 mark const the source of copy_request
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29329 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 02:17:52 +00:00
Luigi Rizzo c76882a94a fix indentation to make a table more readable
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29328 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 02:16:04 +00:00
Luigi Rizzo 3ade391d1d simplify register_peer_exten() removing some duplicated code.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29315 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 02:02:57 +00:00
Luigi Rizzo 734535011a use strsep() to trim away ;xxx from SIP messages.
Note that in a couple of places the code overwrites the string
in the buffer - mark the two places with XXX but do not fix the
bug yet.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29299 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 01:27:52 +00:00
Luigi Rizzo 8414445108 use a more compact method to trim the trailing ;... from SIP lines.
These are just the first two instances, there are many more to replace.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29298 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 01:08:41 +00:00
Luigi Rizzo 917182e286 annotate const parameters of copy_header()
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29268 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 00:46:04 +00:00
Luigi Rizzo 27f4fb4990 src is const in parse_copy()
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29267 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 00:32:36 +00:00
Luigi Rizzo 564ca6394a minor logic simplification in get_sip_pvt_byid_locked()
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29266 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 00:29:12 +00:00
Luigi Rizzo 15b7465cd2 simplify logic in function create_addr()
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29265 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 00:17:46 +00:00
Luigi Rizzo a234f92337 simplify logic in realtime_peer(), removing an unnecessary
initialization, an extra variable (newpeername) and a 
variable newpeername, and an 'else' branch.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29264 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 00:07:48 +00:00
Luigi Rizzo 94d3a99089 strcmp() is the right function to use here, not strncmp().
On passing simplify an ast_cli message nearby.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29234 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-21 23:54:28 +00:00
Russell Bryant ed0b86c916 fix the possibility of writing one byte past the end of a buffer.
(issue #7189, Mithraen)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@29053 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-20 19:54:14 +00:00
Kevin P. Fleming 6d92d53d41 attributes need trailing CR-LF
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28863 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-19 23:08:47 +00:00
Kevin P. Fleming 42e2cf61d8 Merged revisions 28794 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r28794 | kpfleming | 2006-05-19 14:39:55 -0500 (Fri, 19 May 2006) | 2 lines

use the specified 'subscribecontext' for a peer rather than the context found via the target domain (domain contexts are for calls, not for subscriptions) (issue #7122, reported by raarts)

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28795 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-19 19:43:33 +00:00
Tilghman Lesher d0c36296d2 As requested by kpfleming, renaming messagecount to inboxcount and messagecount2 to messagecount.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28745 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-19 18:21:31 +00:00
Olle Johansson cd03597f0c Formatting cleanup
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28483 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-19 07:52:08 +00:00
Kevin P. Fleming 0c73d47618 Merged revisions 28380,28384 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r28380 | kpfleming | 2006-05-18 15:24:07 -0500 (Thu, 18 May 2006) | 2 lines

handle incoming multipart/mixed message bodies in SIP and find the SDP, if presnet (issue #7124 reported and patched by eborgstrom, but very different fix)

........
r28384 | kpfleming | 2006-05-18 15:43:42 -0500 (Thu, 18 May 2006) | 2 lines

fix up a few more places to find the SDP properly (fallout from fix for #7124)

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28394 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-18 21:02:21 +00:00
Kevin P. Fleming 42cf0b0a8f add another media path reinvite 'flavor', where we will only redirect our media to devices that we know are not behind a NAT (based on the evidence collected when we receive media from them)
also, documented the 'canreinvite=update' option in the sample config file


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28215 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-18 16:57:59 +00:00
Kevin P. Fleming 48c36f4b89 adding new code should require following the formatting guidelines :-)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28214 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-18 16:38:26 +00:00
Joshua Colp 6d603ec09c Allow contexts in regexten so that extensions can be added to multiple contexts when peer registers (issue #6869 reported by and created by Marquis)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@28168 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-18 14:07:46 +00:00
Joshua Colp 6eb1d09ad9 Only set the RTP DTMF information of an RTP structure does indeed exist.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27972 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-17 22:02:15 +00:00
Olle Johansson 10c0ed16f0 Issue #7176 - Crash in expire_register (imported from 1.2)
This is a bad fix, since peer should never be 0. Why is it zero
on Royk's system? 


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27928 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-17 19:37:51 +00:00
Olle Johansson 270d5f6191 Adding a debug line
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27892 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-17 18:19:17 +00:00
Olle Johansson 770a4a30c5 Use pointer instead of un-needed buffer. Thanks Kevin!
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27684 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-17 06:18:09 +00:00
Kevin P. Fleming c3dce57d95 mark RTP sessions that are not carrying DTMF
allow native bridging of RTP sessions that are not carrying DTMF even when the bridge needs to listen to DTMF (when SIP INFO is used for DTMF, for example)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27559 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-16 22:11:02 +00:00
Olle Johansson eeb2184920 Send a=recvonly when put on hold, otherwise a=sendrecv to indicate that we want two streams.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27479 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-16 20:13:10 +00:00
Olle Johansson e4c0a90649 Show all formats for an active SIP call
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27396 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-16 18:06:27 +00:00
Olle Johansson c625a539be One sipfrag attachment is enough...
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@27306 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-16 12:44:04 +00:00
Luigi Rizzo 87e909476d simplify determine_firstline_parts
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26919 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 14:55:34 +00:00
Luigi Rizzo f3e6fa56ab remove last instance of add_blank_header()
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26917 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 14:47:12 +00:00
Luigi Rizzo b87aea8d60 remove almost all useless instances of add_blank_header() but one,
for which i need to investigate a bit more (but i am almost 100%
sure that one is also useless).
I do the commit in two steps so it is easier to track the problem.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26915 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 14:35:06 +00:00
Olle Johansson 5237a0e06d - Use systemname for realm in sip, if we have no configuration for realm
- Optionally send systemname in manager (cool when you have a manager proxy)
- Use systemname in CLI prompt


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26884 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 13:54:00 +00:00
Luigi Rizzo 945ec73b09 remove trailing space
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26848 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 10:26:39 +00:00
Luigi Rizzo 589241e300 remove a duplicate prototype
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26847 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 10:26:00 +00:00
Luigi Rizzo 96478ea3a2 remove duplicated code in add_header
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26846 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 10:22:18 +00:00
Luigi Rizzo d06427978c simplify init_req()
As the rest of the chan_sip.c changes i am committing, this is

Approved by: oej



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26804 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 09:38:53 +00:00
Luigi Rizzo 5cd1ec4e17 cleanup init_resp with proper variable names and arguments.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26802 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 09:36:10 +00:00
Luigi Rizzo e08e646252 staticize a variable.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26801 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 09:32:51 +00:00
Luigi Rizzo 798b82e184 replace list unlinking with UNLINK macro
(when the list becomes an astobj this will be revisited;
however at the moment the change would be too intrusive).



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26800 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 09:29:37 +00:00
Luigi Rizzo 067c472abb simplify sip_pretend_ack also removing a bug in the existing
code which called ast_skip_blanks erroneously.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26799 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 09:24:35 +00:00
Kevin P. Fleming 70a554a264 Merged revisions 26760 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r26760 | kpfleming | 2006-05-11 03:52:46 -0500 (Thu, 11 May 2006) | 2 lines

ensure that we send a response to REGISTER requests that are successfully authenticated but contain invalid Contact URIs

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26764 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 09:01:53 +00:00
Olle Johansson 71aabeef4f Ignore CANCEL on call that is already answered
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26757 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 08:25:20 +00:00
Olle Johansson 2dd2865d7b Small formatting fixes
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26756 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 08:20:59 +00:00
Olle Johansson 52cb5c87db Issue #OEJ12399.3 - Set default maxcallbitrate for users too.
(Well, could have opened a branch for this, but felt community pressure not to... ;-)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26755 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 08:08:54 +00:00
Olle Johansson 9b2d51fb4a - Add more and organize forward declarations (preparing for splitting up this file)
- Doxygen fixes


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26720 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 07:57:03 +00:00
Olle Johansson d04f0da698 Issue #7081 (kanoop) - use proper cause code for 480
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26716 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-11 07:25:03 +00:00
Russell Bryant 19ca8dc7c1 remove some chekc sof the result of ast_mutex_lock (issue #7119, Mithraen)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26531 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-10 15:41:23 +00:00
Russell Bryant 04ecb29d03 remove almost all of the checks of the result from ast_strdupa() or alloca().
As it turns out, all of these checks were useless, because alloca will never
return NULL.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26451 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-10 13:22:15 +00:00
Kevin P. Fleming fdcfd6469b ensure that control frames with payload can be sent to channel drivers via ->indicate()
update iax2_indicate to pass control frame payload to the connected channel
add an API call for sending an indication with payload, and use it for control frames with payload


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26417 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-10 12:24:11 +00:00
Mark Spencer 9953f4f40e Make SIP early media work more efficiently without so many reinvites
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26019 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-09 11:44:50 +00:00
Mark Spencer 3135a35b92 Make sure we update parameters correctly with reinvite
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@25959 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-09 09:47:22 +00:00
Mark Spencer db502da870 Make menuselect be able to show what the modules are
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@25929 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-09 08:44:50 +00:00
Olle Johansson 5a31054599 Issue #7103 (mikma)
- Don't send reply on ACK
- use "require" instead of "required" which is an unknown header
 (Partly imported from 1.2)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@25612 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-08 15:31:58 +00:00
Olle Johansson 896362d30c - Issue 7101 (mikma) - Don't crash with no From: header in pedantic mode
- Cleanup of get_destination
- Don't call uri_decode twice on the same string if you're in a rush ... :-)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@25568 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-08 14:45:28 +00:00
Russell Bryant b6ac5b36c6 document the return value of gettag()
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@25063 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-05 21:55:25 +00:00
Russell Bryant e91afbaef1 fix the return value of gettag() to only return the pointer to the provided
tag buffer if the tag was actually found.  There is code that checks to see
if this result is non-zero to determine whether the tag was found or not.
(issue #7092, mikma)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@25060 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-05 21:43:06 +00:00
Olle Johansson 9c60f78ea1 Issue #7074 - Problem with long contact lines
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@24382 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-03 12:46:29 +00:00
Russell Bryant d649d03170 fix sending the group numbers for a sip peer over the manager interface
(issue #7046)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@23178 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-28 16:50:32 +00:00
Kevin P. Fleming 574e14cbea Thanks to the fine work of Russell Bryant and Dancho Lazarov, we now have autoconf and menuselect tools for Asterisk!
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@22267 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-24 17:11:45 +00:00
Olle Johansson 5873462c2e - Add doxygen documentation for sipsock_read locking
- Improve documentation of pedantic
  (related to issue #7016)

  From the air above Russia...


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@22163 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-23 06:22:29 +00:00
Olle Johansson 6149e82b6c Clarify result of sipsock_read
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21707 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-19 23:49:36 +00:00
Olle Johansson 4403905c2d Add reference to RFC for mailbox notification
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21277 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-19 00:45:37 +00:00
Olle Johansson d0f254ef61 Cosmetic fixes to code...
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21262 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-19 00:04:03 +00:00
Olle Johansson fc2d28805b - call parking improvements (part of the siptransfer branch)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21157 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-18 15:09:01 +00:00
Olle Johansson 2af3d42e9b Implement somewhat improved support for 481 Call leg does not exist responses...
- There are some questions on what to do here, but it is a first step.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21131 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-18 14:50:30 +00:00
Olle Johansson 910c44b1b6 Clean up handle_response_peerpoke
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21129 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-18 14:41:57 +00:00
Olle Johansson 60d91caa23 Change sip show channels to include refer status
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21128 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-18 14:37:54 +00:00
Olle Johansson 1fec0e47e7 - Deallocate refer structure at sip_destroy time
- Implement new sip_transfer() function


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21127 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-18 14:35:15 +00:00
Olle Johansson 177b8e9143 It's critical that we get an ACK on a 200 OK to an INVITE. If we do not get the ACK,
tear down the call. (Discovered at SIPit18)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21061 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-18 07:03:36 +00:00
Olle Johansson 2c73c08f5a use XMIT_RELIABLE ...
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21043 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-18 07:00:27 +00:00
Olle Johansson 40161ae947 - Move subscribeuri away from refer-to, since refer-to is moving away from sip_pvt
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@21039 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-18 06:40:01 +00:00
Olle Johansson 080298dad4 Set timeout timers to Timer A and F in rfc 3261, section 17
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20932 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 14:22:16 +00:00
Olle Johansson ea7f924b30 Change transmit_invite(). SIP Transfers are now broken officially, while
waiting for the rest of the patches... This is the dev branch, after all.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20931 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 14:07:50 +00:00
Olle Johansson 5320c6b76a - Add supported header
- Send cause codes as well


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20908 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 14:00:44 +00:00
Olle Johansson 42918c225a Add more history on masqs
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20903 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 13:52:53 +00:00
Olle Johansson b124cf4c80 - Implementing the new SIP transfer data structure
- Changing SIP call to support sending INVITEs as part of call transfers


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20902 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 13:47:30 +00:00
Olle Johansson bdb2332621 - Documentation update
- Formatting change


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20901 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 13:22:31 +00:00
Olle Johansson bedd0c2ed3 Documentation update
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20900 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 13:08:24 +00:00
Olle Johansson 382fd7260c Remove ignore from handle_respons_refer
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20872 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 09:21:56 +00:00
Olle Johansson a5e5fb18e2 Clean up handle_response_invite
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20844 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 08:15:38 +00:00
Olle Johansson 92ac73fe3b - Drop too bad SIP requests in order to avoid some UDP misuse (hello Edwin)
- Clean up initialization of initatial request initialization


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20816 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 05:32:22 +00:00
Olle Johansson 4a312a044d - Fixes to ast_channel_lock functions
- New get_sip_pvt_byid function (not really used correctly yet...)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20424 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-16 12:57:15 +00:00
Olle Johansson e75fa47099 More ast_channel_lock fixes
- Update lock.h with definitions of ast_channel_lock, ast_channel_unlock and ast_channel_trylock
- Convert some functions (but not all) in channel.c
- Fix some bugs in chan_sip.c
- Convert rest of chan_sip.c


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20295 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-15 15:07:39 +00:00
Olle Johansson 6b3367bf5c New functions for locking a channel - these simplify debugging
when you have channel locking issues.
(Part of the SIP transfer patch, where I had a *lot* of
channel locking problems)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20264 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-15 08:07:50 +00:00
Luigi Rizzo e43bc6634d This rather large commit changes the way modules are loaded.
As partly documented in loader.c and include/asterisk/module.h,
modules are now expected to return all of their methods and flags
into a structure 'mod_data', and are normally loaded with RTLD_NOW
| RTLD_LOCAL, so symbols are resolved immediately and conflicts
should be less likely.  Only in a small number of cases (res_*,
typically) modules are loaded RTLD_GLOBAL, so they can export
symbols.
 
The core of the change is only the two files loader.c and
include/asterisk/module.h, all the rest is simply adaptation of the
existing modules to the new API, a rather mechanical (but believe
me, time and finger-consuming!) process whose detail you can figure
out by svn diff'ing any single module.

Expect some minor compilation issue after this change, please
report it on mantis http://bugs.digium.com/view.php?id=6968
so we collect all the feedback in one place.

I am just sorry that this change missed SVN version number 20000!



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@20003 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-14 14:08:19 +00:00
Olle Johansson 5af687b83b Issue #6951 - Show last successful registration time in "sip show registry" (ivanfm) with mods for svn trunk
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19736 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-13 12:48:03 +00:00
Olle Johansson d4b5393eeb - Adding some refer state definitions from the siptransfer branch
- A bit more URI conversions 
- Changes to sip_dual and the SIP invite structure
- Add Supported: headers to more requests


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19578 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-12 21:21:44 +00:00
Olle Johansson 9468e5cd06 Fix for Polycom bug...
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19549 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-12 21:00:31 +00:00
Olle Johansson ea4235c56c Implement a setting for denying/allowing transfer requests. At this stage,
we only have open/closed. Well, at least you can deny transfers from unknown
callers or at least incoming calls.
(Part of the SIPtransfer branch)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19546 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-12 20:57:07 +00:00
Olle Johansson 975ddb8552 Doxygen docs
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19542 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-12 20:32:40 +00:00
Luigi Rizzo b24bc86fc2 reindent block properly
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19466 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-12 00:17:37 +00:00
Luigi Rizzo 86e8094c3c localize some variables, remove useless parentheses
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19465 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-12 00:15:57 +00:00
Luigi Rizzo 3579d11dc1 remove useless \0, and fix formatting.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19437 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-11 23:54:33 +00:00
Kevin P. Fleming fb4d5fb6a6 fix logic error; don't test for rtcache flag unless asked to (issue #6923)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19393 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-11 22:07:52 +00:00
Olle Johansson 8318cddd8e - First stab at removing debug and ignore variables that
we pass along function calls, instead implementing them as
  flags on the incoming packet.
- Adding forward declarations of handle_request functions


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19128 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-11 06:09:01 +00:00
Olle Johansson 26198e8826 Fixup fixup - add some debugging and error handling
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18940 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 20:18:14 +00:00
Olle Johansson 8b1543974f Resolve conflicts, prepare for next batch of conflicts
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18909 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 19:55:39 +00:00
Olle Johansson fed57c1eb2 Making sure that cancel destroy is only executed once...
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18799 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 13:43:54 +00:00
Olle Johansson f74538df11 Small fix
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18797 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 13:19:36 +00:00
Luigi Rizzo c3b3feab76 - staticize gettag() complete_sip_peer() get_calleridname() arguments;
- use strsep() instead of strchr() where appropriate
- constify some args and add comments. 
- remove a conditional near line 1940 - we already know what to use.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18793 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 12:20:57 +00:00
Luigi Rizzo 8731b6386d - constification of some functions (args and return values):
transmit_response_reliable()
        hangup_cause2sip()
- remove useless braces;
- add comments on some slightly cryptic code segments
- mark XXX possible critical pieces of code.
- remove an unneeded string termination after ast_copy_string
- mark usage of some rarely used functions;
- use strsep() instead of emulating it inline;
- replace magic constants with sizeof(array)




git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18792 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 11:57:40 +00:00
Luigi Rizzo 7e5e2ffb5f - localize 'struct cfalias' into the only function using it;
- remove duplicate code to walk through sdp packets, replacing
  sdpLineNum_iterator_init(&foo); with  "foo = 0";
- remove duplicate code to test ast_test_flag(&p->flags[0], SIP_NAT_ROUTE);



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18791 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 11:36:02 +00:00
Luigi Rizzo 25e9168fea constify get_sdp*() and friends.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18790 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 11:19:14 +00:00
Luigi Rizzo 87890e75ba constify get_header(), which let me find out and fix one bug (overwriting
a string in the buffer) and finding out another one (not fixed yet,
just marked XXX).



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18789 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 11:04:04 +00:00
Luigi Rizzo 47df1e2020 - describe how sip packets are stored internally;
- remove useless braces or local variables;
- simplify some code sequences;
- mark with XXX a possible locking issue.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18788 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 10:40:13 +00:00
Luigi Rizzo 20d1876617 struct sip_request cleanup:
- remove a debug field that was read but never set, so it was basically
  unused as well as the code testing it (also removed);

- make scalar fields contiguous so any array overflow will be
  less harmful;



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18787 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 10:30:38 +00:00
Luigi Rizzo 104c2b0a3a more cleanup: remove useless braces, replace "if" with "?",
localize a couple of variables, remove trailing whitespace.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18786 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 10:22:42 +00:00
Olle Johansson 9b4e335439 Re-instate removed comment
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18785 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 10:01:14 +00:00
Luigi Rizzo e081b42cd6 another batch of minor code simplifications
(moving repeated expressions into a function, const on
some arguments)



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18784 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 09:53:22 +00:00
Luigi Rizzo e468d9011d a bunch of trivial code normalizations (removal of unnecessary
casts and parentheses, formatting fixes, pointing out replicated
code and so on). No functional changes.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18666 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-09 23:16:29 +00:00
Kevin P. Fleming f10f427d49 since the module API is changing, it's a good time to const-ify the description() and key() return values
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18552 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-08 22:01:19 +00:00
Olle Johansson 8159124572 -Fixing some debugging messages in history and console
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18403 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 20:19:44 +00:00
Olle Johansson aefba4ad7d Add history events for re-invites
(need to nail this issue...)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18373 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 19:46:50 +00:00
Olle Johansson f235bbe5a5 make history easier to read
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18371 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 19:36:44 +00:00
Olle Johansson 8cd506cdfd Add some more information to SIP history
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18370 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 19:25:19 +00:00
Olle Johansson 7089dc1341 Issue #6899 - remove OSP support code from chan_sip.c and app_dial.c
- implement all functions through internal APIs in res_osp.c and app_osplookup.c
(homesick)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18369 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 19:11:22 +00:00
Olle Johansson fd54f36509 Hmm. What is that keyword?? Let me see... Wait... Maybe... Ahh! OOPS!
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18342 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 18:52:23 +00:00
Russell Bryant 3808318cff change a couple uses of !strlen() to ast_strlen_zero(). Oddly enough, one of
these used to be this way and got changed ...


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18309 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 16:28:50 +00:00
Olle Johansson 839ebd8e03 - sip_alloc failures are also caused by too few available file descriptors, so we can not
open socket for RTP (audio/video/rtcp).
  Error message change to clarify.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18307 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 16:22:28 +00:00
Olle Johansson b479a91e97 - Add cause code for format error
- Change to SWITCH_CONGESTION instead of CONGESTION
(imported from 1.2)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18262 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 14:42:25 +00:00
Olle Johansson 48ca2c82bf Import of revistion 18250 from 1.2
- Fix minor memory leak
- Add proper cause codes on memory allocation failures


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18261 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 14:30:14 +00:00
Olle Johansson b7d32b9e0b Issue #6674: Set the URI correctly on BYEs when we have an incoming call
Reported by aubergine, fix by oej


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18161 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-07 08:19:52 +00:00
Olle Johansson 4ded41daa5 Cosmetic update for outbound REFERs
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18060 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 21:49:24 +00:00
Olle Johansson 965394e4c2 Add "NewChan" event to history to track the birth of a new ast_chan from a
SIP invite


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18059 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 21:33:39 +00:00
Olle Johansson 009e081199 Improved handling of 491 responses
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18058 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 21:29:54 +00:00
Olle Johansson 518c4b295d Small changes to parse_sip_options
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18057 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 21:18:12 +00:00
Olle Johansson be4ac5e57a Small fixes to handle_request_invite
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18056 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 21:13:32 +00:00
Olle Johansson 62128ba7b7 - Don't change channel direction on re-invites
- Don't re-initialize initreq on re-invites


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18033 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 21:01:06 +00:00
Olle Johansson 5483288048 - Implement handle_request_notify to handle incoming NOTIFY requests
and respond properly to them.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18024 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 20:36:25 +00:00
Olle Johansson 9bd9bceef7 Implement a handle_response_refer function to take care of responses
to outbound REFERS. Not that common, but still needed.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18022 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 20:16:08 +00:00
Olle Johansson 1e8d1dda7d Change transmit_notify_sipfrag to handle other messages than 200 OK, needed for
SIPtransfer improvement


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17993 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 19:59:21 +00:00
Olle Johansson ddcd16e519 - doxygen
- debug message control


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17991 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 19:39:27 +00:00
Luigi Rizzo 4408c0e6b5 structures can be copied with the '=' operators, no need to
use memcpy.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17988 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 19:31:59 +00:00
Luigi Rizzo 6f09a652dd normalize some for() loops.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17943 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-06 17:09:00 +00:00
Tilghman Lesher 756c7cbb12 Bug 6873 - Finish moving from the non-threadsafe (and poor randomness) rand() to threadsafe ast_random()
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17627 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-05 17:44:44 +00:00
Olle Johansson 37ff50a890 - Don't return AST_DEVICE_UNKNOWN to devicestate engine, since this will
cause a channel walk...
- Doxygen fixed for devicestate.c


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17365 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-04 18:24:41 +00:00
Olle Johansson 878c88f899 Add tag to NOTIFY headers (imported from 1.2)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17151 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-03 20:40:08 +00:00
Olle Johansson 5fbe9f80e8 Don't add hangup cause on non-final responses. (Imported from 1.2)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17075 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-03 17:52:11 +00:00
Olle Johansson 67b460d43c Issue #6848 - Accept MWI subscriptions with no Accept: header
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@17050 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-03 10:50:56 +00:00
Olle Johansson 46a1b7c73b Don't add ast_extension_state on re-subscribes
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16829 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-01 00:44:36 +00:00
Olle Johansson 2240245389 Reverse revision 16804 that disables authentication
and a lot of other issues...


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16825 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-01 00:24:05 +00:00
BJ Weschke 225d8d5270 Don't process re-subscribes as new subscriptions.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16804 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-31 21:02:23 +00:00
Olle Johansson 83b7de9463 Doxygen fix
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16703 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-31 16:02:29 +00:00
Olle Johansson 2994fa390c Make REG_STATE_* enum
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16690 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-31 15:19:04 +00:00
Olle Johansson 40b71d4b39 Don't accept new INVITE if we already have one pending.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16688 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-31 15:07:36 +00:00
Tilghman Lesher 9a9ab4e7cf Merged revisions 16581 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r16581 | tilghman | 2006-03-30 16:56:35 -0600 (Thu, 30 Mar 2006) | 2 lines

Bug 6853 - Manager fixes: 1) extra ActionID, 2) missing colon

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16600 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-30 23:05:58 +00:00
Kevin P. Fleming 4e5ea82b7e deprecate insecure=very and insecure=yes, since we have more explicit versions available now
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16548 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-30 18:17:36 +00:00
Olle Johansson 50f0b12880 Issue #5374 - Enable internal timing of generators (cmantunes)
Thanks everyone involved for hard work, testing and testing!


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16473 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-30 06:07:04 +00:00
Olle Johansson 2c4ebe356e Issue #6450 - Don't remove characters from SIP uri's when not needed
Patch by jcomellas, heavily modified by oej


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16425 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-30 04:16:38 +00:00
Olle Johansson 3d1f9b747e Formatting fix.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16304 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-30 00:30:49 +00:00
Olle Johansson b366c4062e Issue #6823 - Registration and port numbers. (from 1.2)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15905 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-29 01:01:09 +00:00
Kevin P. Fleming bb87cd151b make 'sip show subscriptions' include context for subscribed hints
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15819 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-28 22:47:02 +00:00
Luigi Rizzo f84e5cfd43 fix a bug introduced in 15187 that scrambled the flags and
among other things prevented proper handling of NAT.
Don't think it exist in 1.2 but be careful if 15187 is merged.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15744 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-28 20:22:25 +00:00
Olle Johansson 147ae336d2 Fix NAT support breakage for peers with qualify=yes (imported from 1.2)
- Blame KLM, still jetlagged :-)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15701 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-28 19:09:51 +00:00
Kevin P. Fleming 584ab24577 oops :-(
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15618 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-28 17:53:27 +00:00
Russell Bryant dea8078eef conversions to S_OR (issue #6817)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15617 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-28 17:52:50 +00:00
Kevin P. Fleming 8410e0d681 support subscription-based MWI, and use proper Call-ID on NOTIFY messages (issue #6390)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15476 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-28 04:21:21 +00:00
Kevin P. Fleming 0b5f2a5d3f use proper file name
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15436 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-28 03:36:17 +00:00
Kevin P. Fleming 278b8e8fc7 improve IP TOS support for SIP and IAX2 (issue #6355, code from jcollie plus modifications)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15435 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-28 03:28:52 +00:00
Olle Johansson ddaeaae214 Issue #6736 - use flags for OPTIONs messages
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15382 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 23:49:44 +00:00
Olle Johansson 2c9ecd7baa Reverting previous patch. Ok, let's take this from 1.2 instead... :-)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15380 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 23:41:21 +00:00
Olle Johansson e4c8021b7d Issue #6736 - Enable NAT flags for OPTIONs requests (Thanks casper!)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15379 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 23:39:48 +00:00
Olle Johansson 0b39c35161 Issue #6597 - Show correct port in "sip show registry" - import from 1.2 branch
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15377 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 23:32:34 +00:00
Olle Johansson 450bc8dad6 Issue #6409 - Make calls to URI without username go to "s" extension (imported from 1.2)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15375 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 23:13:31 +00:00
Matt O'Gorman a5ece3388a Janitor work converting !ast_strlen_zero(a)?a:b
to S_OR functions. from bug note 6805 with minor
modifications.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15283 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 19:31:54 +00:00
Kevin P. Fleming 15873eb39c simplify flags/page2_flags stuff by using arrays instead
enhance handle_common_options to be able to set flags in the second set of flags (what used to be page2_flags)
various other minor fixes


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15187 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 04:54:06 +00:00
Olle Johansson 83d9331261 Issue #5427
- Enable videosupport per device
- Implement maxcallbitrate setting for video calls

Patch by John Martin, thanks!


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15148 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 03:35:49 +00:00
Olle Johansson 18de2b7787 Issue #6705 (oej)
- Implement option for allow/disallow subscriptions
- Implement option for allow/disallow overlap dialling
- Set default to disable overlap dialling in sip.conf.sample for new installations
- Remove overlap dialling from subscription logic


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@15107 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-27 02:57:17 +00:00
Mark Spencer 9164eac21a Add micro-http server and abstract manager interface, make snmp not die
on reload.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@14953 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-25 23:50:09 +00:00
Olle Johansson f554c03652 - In response to asterisk-users discussion - show which peers in "sip show peers" and "sip show peer" that are cached realtime peers.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@14425 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-23 19:58:32 +00:00
Olle Johansson 19af878bac Issue #6766 - Make ;user=phone work again - imported from 1.2
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@14141 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-22 09:14:42 +00:00
Olle Johansson 9e1e47450a Issue #6759, generate warning when refusing connection requiring unsupported SIP extensions
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@14110 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-22 08:00:32 +00:00
Olle Johansson 8bb397b439 Import revision 13547 from branch 1.2 - reset global_rtautoclear at reload
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@13548 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-19 09:32:36 +00:00
Olle Johansson 7296dd030e - Remove comment about non-existing XML format ;-)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@13546 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-19 09:08:57 +00:00
Olle Johansson dbd3fa49fd - change "regcontext" to "global_regcontext" to mark it as a global setting
- show regexten in "sip show peer <name"


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@13545 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-19 09:07:29 +00:00
Olle Johansson 1bad801595 Importing "oops" fix from 1.2 branch.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@13206 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-16 08:40:45 +00:00
Olle Johansson 8864646870 Import of rev 13026 from 1.2 branch: Fix parameters to event: header
in SUBSCRIBE request


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@13027 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-15 13:06:48 +00:00
Russell Bryant 9bf08efa16 add a missing header to fix building with -Werror (issue #6717)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@12894 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-14 16:16:14 +00:00
Russell Bryant a6f2a3899b add some missing braces
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@12688 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-12 21:17:58 +00:00