Commit Graph

114 Commits

Author SHA1 Message Date
Mike Bradeen 4095a382da chan_sip: Remove deprecated module.
ASTERISK-30297

Change-Id: Ic700168c80b68879d9cee8bb07afe2712fb17996
2023-01-03 09:00:42 -06:00
Josh Soref 01697d4836 addons: Spelling fixes
Correct typos of the following word families:

definition
listener
fastcopy
logical
registration
classify
documentation
explicitly
dialed
endpoint
elements
arithmetic
might
prepend
byte
terminal
inquiry
skipping
aliases
calling
absent
authentication
transmit
their
ericsson
disconnecting
redir
items
client
adapter
transmitter
existing
satisfies
pointer
interval
supplied

ASTERISK-29714

Change-Id: I8548438246f7b718d88e0b9e0a1eb384bbec88e4
2021-11-16 06:00:43 -06:00
George Joseph a47cb71bb1 Build: Fix compile issues with seldom used modules
The following modules needed tweaks for API changes.

addons/cdr_mysql.c
addons/chan_ooh323.c
apps/app_meetme.c

ASTERISK-28604

Change-Id: Ib40e513ae55b5114be035cdc929abb6a8ce2d06d
2019-11-07 08:31:53 -05:00
Alexander Anikin a8f1e26d34 chan_ooh323: fix h323 log file path
Change h323 log path relative to AST_LOG_DIR instead of
/var/log/asterisk hardcoded
Add return back error message from OOH323EP initialize

ASTERISK-28348 #close

Reported by: Dmitry Shubin

Change-Id: Ib102dd36bbe6c2a7a4ce6870ae9110d9000d7e98
2019-04-10 17:12:42 -06:00
Alexander Traud 10de9fcbf1 chan_ooh323: IPTOS_MINCOST is not defined on Solaris.
Furthermore, <sys/sockio.h> is required for SIOCGIF*.

ASTERISK-27938

Change-Id: Idc9153ece769944765b66122efb11728d8d8ebde
2018-07-09 09:45:06 +02:00
Jenkins2 8c1400bb57 Merge "chan_ooh323: introduce localras config parameter" 2018-04-26 11:42:06 -05:00
Richard Mudgett 0464e773d8 Merge "chan_ooh323: fix ooManualProgress/ooManualRingback on ooh323 debuggin on" 2018-04-25 10:46:05 -05:00
Alexander Anikin c481afe873 chan_ooh323: fix ooManualProgress/ooManualRingback on ooh323 debuggin on
Call ooManualProgress/Ringback outside of ast_debug function
when ooh323 debugging is on

ASTERISK-27812 #close
ASTERISK-26893 #close
Reported by: Dimos, Marco Giordani

Change-Id: I5873762e4f05824e7b6e94a19dd4eb56adbbbb79
2018-04-20 22:17:31 +03:00
Alexander Anikin 95e8450194 chan_ooh323: introduce localras config parameter
Introduce localras parameter that specify source IP
for connecting to Gatekeeper. Useful for multihome configurations.

ASTERISK-25129 #close
Reported by: Dmitry Melekhov
Tested by: Dmitry Melekhov

Change-Id: I0b604b01793f3e02a776502659e07cd3fc7e3097
2018-04-18 13:46:30 +03:00
Alexander Anikin 446320f1d4 chan_ooh323: Fix cppcheck warnings
Fix cppcheck warnings about redundant conditions and possible
null pointer usage

ASTERISK-27793 #close
Reported by: Ilya Shipitsin
Tested by: Ilya Shipitsin

Change-Id: I0b31933b062a23331dbac9a82b8bcfe345f406f6
2018-04-18 13:38:09 +03:00
Corey Farrell 572a508ef2 loader: Convert reload_classes to built-in modules.
* acl (named_acl.c)
* cdr
* cel
* ccss
* dnsmgr
* dsp
* enum
* extconfig (config.c)
* features
* http
* indications
* logger
* manager
* plc
* sounds
* udptl

These modules are now loaded at appropriate time by the module loader.
Unlike loadable modules these use AST_MODULE_LOAD_FAILURE on error so
the module loader will abort startup on failure of these modules.

Some of these modules are still initialized or shutdown from outside the
module loader.  logger.c is initialized very early and shutdown very
late, manager.c is initialized by the module loader but is shutdown by
the Asterisk core (too much uses it without holding references).

Change-Id: I371a9a45064f20026c492623ea8062d02a1ab97f
2018-03-14 05:20:12 -04:00
Corey Farrell c8a521b6c8 Replace direct checks of option_debug with DEBUG_ATLEAST macro.
Checking option_debug directly is incorrect as it ignores file/module
specific debug settings.  This system-wide change replaces nearly all
direct checks for option_debug with the DEBUG_ATLEAST macro.

Change-Id: Ic342d4799a945dbc40ac085ac142681094a4ebf0
2018-03-07 16:03:01 -06:00
Alexander Traud 797747afa7 chan_ooh323: Avoid typecasting an int to unsigned short.
clang 5.0 warned about this.

ASTERISK-27577

Change-Id: I898fe4255023138a9e8b579fe4482fcf582f2b78
2018-01-12 11:03:38 +01:00
Alexander Traud f0c8f04c73 chan_ooh323: Limit outgoinglimit to positive values as intended.
ASTERISK-27552

Change-Id: Ifbf9d51e7374ca2e8b27ec568f6770050fc1a854
2018-01-05 08:02:21 -06:00
Sean Bright fd0ca1c3f9 Remove as much trailing whitespace as possible.
Change-Id: I873c1c6d00f447269bd841494459efccdd2c19c0
2017-12-22 09:23:22 -05:00
Corey Farrell 58d032112b Fix compiler warnings on Fedora 26 / GCC 7.
GCC 7 has added capability to produce warnings, this fixes most of those
warnings.  The specific warnings are disabled in a few places:

* app_voicemail.c: truncation of paths more than 4096 chars in many places.
* chan_mgcp.c: callid truncated to 80 chars.
* cdr.c: two userfields are combined to cdr copy, fix would break ABI.
* tcptls.c: ignore use of deprecated method SSLv3_client_method().

ASTERISK-27156 #close

Change-Id: I65f280e7d3cfad279d16f41823a4d6fddcbc4c88
2017-08-01 15:42:38 -06:00
Corey Farrell 824a4e84d1 Refactor usage pattern of xmldoc info tag.
This updates func_channel.c and main/message.c to use a generic xpointer
include instead of including info from each channel driver.  Now the
name attribute of info is CHANNEL or CHANNEL_EXAMPLES to be included in
documentation for func_channel.  Setting the name attribute of info to
MessageToInfo or MessageFromInfo causes it to be included in the
MessageSend application and AMI action.

Change-Id: I89fd8276a3250824241a618009714267d3a8d1ea
2016-08-16 10:42:46 -05:00
Matt Jordan ddab42e296 func_channel: Reorganize documentation
* Following the example of the PJSIP channel driver, the channel
  technology specific documentation has been moved to the respective
  channel drivers that provide that functionality. This has the benefit
  of locating the documentation of items with those modules that provide
  it.

* Examples of using the CHANNEL function for both standard items as well
  as for PJSIP have been added.

* The 'max_forwards' standard item has been documented.

Change-Id: Ifaa79a232c8ac99cf8da6ef6cc7815d398b1b79b
2016-08-15 07:39:19 -05:00
Alexander Traud cf79b62778 ast_format_cap_get_names: To display all formats, the buffer was increased.
ASTERISK-25533 #close

Change-Id: Ie1a9d1a6511b3f1a56b93d04475fbf8a4e40010a
2015-11-09 16:58:52 +01:00
Alexander Anikin d2106c0b21 chan_ooh323: call ast_rtp_instance_stop on ooh323_destroy
Call ast_rtp_instance_stop on ooh323_destroy to free resources
    allocated by rtp instance

    ASTERISK-25299 #close
    Report by: Alexandr Dranchuk

Change-Id: I455096bd7da016b871afe90af86067c2c7c9f33f
2015-09-07 13:48:08 -05:00
Rodrigo Ramírez Norambuena eec010829a AST_MODULE_INFO: Format corrections to the usages of AST_MODULE_INFO macro.
Change-Id: Icf88f9f861c6b2a16e5f626ff25795218a6f2723
2015-05-13 16:34:23 -05:00
Alexandr Anikin 90c98d384b chan_ooh323: fix rtptimeout general value checking
correct condition to check rtptimeout in [general] config section

ASTERISK-24393 #close
Reported by:  Dmitry Melekhov
Tested by:  Dmitry Melekhov
Patches:
  ASTERISK-24393.patch
........

Merged revisions 425547 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 425548 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 425589 from http://svn.asterisk.org/svn/asterisk/branches/12
........

Merged revisions 425590 from http://svn.asterisk.org/svn/asterisk/branches/13


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@425591 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-10-15 10:03:05 +00:00
Richard Mudgett 0165c5f95a chan_pjsip: Fix deadlock when masquerading PJSIP channels.
Performing a directed call pickup resulted in a deadlock when PJSIP
channels were involved.

A masquerade needs to hold onto the channel locks while it swaps channel
information between the two channels involved in the masquerade.  With
PJSIP channels, the fixup routine needed to push a fixup task onto the
PJSIP channel's serializer.  Unfortunately, if the serializer was also
processing a task that needed to lock the channel, you get deadlock.

* Added a new control frame that is used to notify the channels that a
masquerade is about to start and when it has completed.

* Added the ability to query taskprocessors if the current thread is the
taskprocessor thread.

* Added the ability to suspend/unsuspend the PJSIP serializer thread so a
masquerade could fixup the PJSIP channel without using the serializer.

ASTERISK-24356 #close
Reported by: rmudgett

Review: https://reviewboard.asterisk.org/r/4034/
........

Merged revisions 424471 from http://svn.asterisk.org/svn/asterisk/branches/12
........

Merged revisions 424472 from http://svn.asterisk.org/svn/asterisk/branches/13


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@424473 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-10-03 17:47:42 +00:00
Walter Doekes 37179a2b1f core: Don't allow free to mean ast_free (and malloc, etc..).
This gets rid of most old libc free/malloc/realloc and replaces them
with ast_free and friends. When compiling with MALLOC_DEBUG you'll
notice it when you're mistakenly using one of the libc variants. For
the legacy cases you can define WRAP_LIBC_MALLOC before including
asterisk.h.

Even better would be if the errors were also enabled when compiling
without MALLOC_DEBUG, but that's a slightly more invasive header
file change.

Those compiling addons/format_mp3 will need to rerun
./contrib/scripts/get_mp3_source.sh.

ASTERISK-24348 #related
Review: https://reviewboard.asterisk.org/r/4015/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@423978 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-09-26 14:41:38 +00:00
Mark Michelson dcf1ad14da Add module support level to ast_module_info structure. Print it in CLI "module show" .
ASTERISK-23919 #close
Reported by Malcolm Davenport

Review: https://reviewboard.asterisk.org/r/3802



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@419592 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-07-25 16:47:17 +00:00
Jason Parker 7e7ba07936 Don't cause Asterisk to exit if ooh323.conf not found.
(closes issue ASTERISK-23814)
........

Merged revisions 419374 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 419375 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 419376 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@419377 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-07-24 16:52:00 +00:00
Kinsey Moore 9056c23bbd Fix more dev-mode build issues
........

Merged revisions 419129 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 419162 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 419163 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@419175 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-07-22 14:22:00 +00:00
Matthew Jordan a2c912e997 media formats: re-architect handling of media for performance improvements
In the old times media formats were represented using a bit field. This was
fast but had a few limitations.
 1. Asterisk was limited in how many formats it could handle.
 2. Formats, being a bit field, could not include any attribute information.
    A format was strictly its type, e.g., "this is ulaw".
This was changed in Asterisk 10 (see
https://wiki.asterisk.org/wiki/display/AST/Media+Architecture+Proposal for
notes on that work) which led to the creation of the ast_format structure.
This structure allowed Asterisk to handle attributes and bundle information
with a format.

Additionally, ast_format_cap was created to act as a container for multiple
formats that, together, formed the capability of some entity. Another
mechanism was added to allow logic to be registered which performed format
attribute negotiation. Everywhere throughout the codebase Asterisk was
changed to use this strategy.

Unfortunately, in software, there is no free lunch. These new capabilities
came at a cost.

Performance analysis and profiling showed that we spend an inordinate
amount of time comparing, copying, and generally manipulating formats and
their related structures. Basic prototyping has shown that a reasonably
large performance improvement could be made in this area. This patch is the
result of that project, which overhauled the media format architecture
and its usage in Asterisk to improve performance.

Generally, the new philosophy for handling formats is as follows:
 * The ast_format structure is reference counted. This removed a large amount
   of the memory allocations and copying that was done in prior versions.
 * In order to prevent race conditions while keeping things performant, the
   ast_format structure is immutable by convention and lock-free. Violate this
   tenet at your peril!
 * Because formats are reference counted, codecs are also reference counted.
   The Asterisk core generally provides built-in codecs and caches the
   ast_format structures created to represent them. Generally, to prevent
   inordinate amounts of module reference bumping, codecs and formats can be
   added at run-time but cannot be removed.
 * All compatibility with the bit field representation of codecs/formats has
   been moved to a compatibility API. The primary user of this representation
   is chan_iax2, which must continue to maintain its bit-field usage of formats
   for interoperability concerns.
 * When a format is negotiated with attributes, or when a format cannot be
   represented by one of the cached formats, a new format object is created or
   cloned from an existing format. That format may have the same codec
   underlying it, but is a different format than a version of the format with
   different attributes or without attributes.
 * While formats are reference counted objects, the reference count maintained
   on the format should be manipulated with care. Formats are generally cached
   and will persist for the lifetime of Asterisk and do not explicitly need
   to have their lifetime modified. An exception to this is when the user of a
   format does not know where the format came from *and* the user may outlive
   the provider of the format. This occurs, for example, when a format is read
   from a channel: the channel may have a format with attributes (hence,
   non-cached) and the user of the format may last longer than the channel (if
   the reference to the channel is released prior to the format's reference).

For more information on this work, see the API design notes:
  https://wiki.asterisk.org/wiki/display/AST/Media+Format+Rewrite

Finally, this work was the culmination of a large number of developer's
efforts. Extra thanks goes to Corey Farrell, who took on a large amount of the
work in the Asterisk core, chan_sip, and was an invaluable resource in peer
reviews throughout this project.

There were a substantial number of patches contributed during this work; the
following issues/patch names simply reflect some of the work (and will cause
the release scripts to give attribution to the individuals who work on them).

Reviews:
 https://reviewboard.asterisk.org/r/3814
 https://reviewboard.asterisk.org/r/3808
 https://reviewboard.asterisk.org/r/3805
 https://reviewboard.asterisk.org/r/3803
 https://reviewboard.asterisk.org/r/3801
 https://reviewboard.asterisk.org/r/3798
 https://reviewboard.asterisk.org/r/3800
 https://reviewboard.asterisk.org/r/3794
 https://reviewboard.asterisk.org/r/3793
 https://reviewboard.asterisk.org/r/3792
 https://reviewboard.asterisk.org/r/3791
 https://reviewboard.asterisk.org/r/3790
 https://reviewboard.asterisk.org/r/3789
 https://reviewboard.asterisk.org/r/3788
 https://reviewboard.asterisk.org/r/3787
 https://reviewboard.asterisk.org/r/3786
 https://reviewboard.asterisk.org/r/3784
 https://reviewboard.asterisk.org/r/3783
 https://reviewboard.asterisk.org/r/3778
 https://reviewboard.asterisk.org/r/3774
 https://reviewboard.asterisk.org/r/3775
 https://reviewboard.asterisk.org/r/3772
 https://reviewboard.asterisk.org/r/3761
 https://reviewboard.asterisk.org/r/3754
 https://reviewboard.asterisk.org/r/3753
 https://reviewboard.asterisk.org/r/3751
 https://reviewboard.asterisk.org/r/3750
 https://reviewboard.asterisk.org/r/3748
 https://reviewboard.asterisk.org/r/3747
 https://reviewboard.asterisk.org/r/3746
 https://reviewboard.asterisk.org/r/3742
 https://reviewboard.asterisk.org/r/3740
 https://reviewboard.asterisk.org/r/3739
 https://reviewboard.asterisk.org/r/3738
 https://reviewboard.asterisk.org/r/3737
 https://reviewboard.asterisk.org/r/3736
 https://reviewboard.asterisk.org/r/3734
 https://reviewboard.asterisk.org/r/3722
 https://reviewboard.asterisk.org/r/3713
 https://reviewboard.asterisk.org/r/3703
 https://reviewboard.asterisk.org/r/3689
 https://reviewboard.asterisk.org/r/3687
 https://reviewboard.asterisk.org/r/3674
 https://reviewboard.asterisk.org/r/3671
 https://reviewboard.asterisk.org/r/3667
 https://reviewboard.asterisk.org/r/3665
 https://reviewboard.asterisk.org/r/3625
 https://reviewboard.asterisk.org/r/3602
 https://reviewboard.asterisk.org/r/3519
 https://reviewboard.asterisk.org/r/3518
 https://reviewboard.asterisk.org/r/3516
 https://reviewboard.asterisk.org/r/3515
 https://reviewboard.asterisk.org/r/3512
 https://reviewboard.asterisk.org/r/3506
 https://reviewboard.asterisk.org/r/3413
 https://reviewboard.asterisk.org/r/3410
 https://reviewboard.asterisk.org/r/3387
 https://reviewboard.asterisk.org/r/3388
 https://reviewboard.asterisk.org/r/3389
 https://reviewboard.asterisk.org/r/3390
 https://reviewboard.asterisk.org/r/3321
 https://reviewboard.asterisk.org/r/3320
 https://reviewboard.asterisk.org/r/3319
 https://reviewboard.asterisk.org/r/3318
 https://reviewboard.asterisk.org/r/3266
 https://reviewboard.asterisk.org/r/3265
 https://reviewboard.asterisk.org/r/3234
 https://reviewboard.asterisk.org/r/3178

ASTERISK-23114 #close
Reported by: mjordan
  media_formats_translation_core.diff uploaded by kharwell (License 6464)
  rb3506.diff uploaded by mjordan (License 6283)
  media_format_app_file.diff uploaded by kharwell (License 6464) 
  misc-2.diff uploaded by file (License 5000)
  chan_mild-3.diff uploaded by file (License 5000) 
  chan_obscure.diff uploaded by file (License 5000) 
  jingle.diff uploaded by file (License 5000) 
  funcs.diff uploaded by file (License 5000) 
  formats.diff uploaded by file (License 5000) 
  core.diff uploaded by file (License 5000) 
  bridges.diff uploaded by file (License 5000) 
  mf-codecs-2.diff uploaded by file (License 5000) 
  mf-app_fax.diff uploaded by file (License 5000) 
  mf-apps-3.diff uploaded by file (License 5000) 
  media-formats-3.diff uploaded by file (License 5000) 

ASTERISK-23715
  rb3713.patch uploaded by coreyfarrell (License 5909)
  rb3689.patch uploaded by mjordan (License 6283)
  
ASTERISK-23957
  rb3722.patch uploaded by mjordan (License 6283) 
  mf-attributes-3.diff uploaded by file (License 5000) 

ASTERISK-23958
Tested by: jrose
  rb3822.patch uploaded by coreyfarrell (License 5909) 
  rb3800.patch uploaded by jrose (License 6182)
  chan_sip.diff uploaded by mjordan (License 6283) 
  rb3747.patch uploaded by jrose (License 6182)

ASTERISK-23959 #close
Tested by: sgriepentrog, mjordan, coreyfarrell
  sip_cleanup.diff uploaded by opticron (License 6273)
  chan_sip_caps.diff uploaded by mjordan (License 6283) 
  rb3751.patch uploaded by coreyfarrell (License 5909) 
  chan_sip-3.diff uploaded by file (License 5000) 

ASTERISK-23960 #close
Tested by: opticron
  direct_media.diff uploaded by opticron (License 6273) 
  pjsip-direct-media.diff uploaded by file (License 5000) 
  format_cap_remove.diff uploaded by opticron (License 6273) 
  media_format_fixes.diff uploaded by opticron (License 6273) 
  chan_pjsip-2.diff uploaded by file (License 5000) 

ASTERISK-23966 #close
Tested by: rmudgett
  rb3803.patch uploaded by rmudgetti (License 5621)
  chan_dahdi.diff uploaded by file (License 5000) 
  
ASTERISK-24064 #close
Tested by: coreyfarrell, mjordan, opticron, file, rmudgett, sgriepentrog, jrose
  rb3814.patch uploaded by rmudgett (License 5621) 
  moh_cleanup.diff uploaded by opticron (License 6273) 
  bridge_leak.diff uploaded by opticron (License 6273) 
  translate.diff uploaded by file (License 5000) 
  rb3795.patch uploaded by rmudgett (License 5621) 
  tls_fix.diff uploaded by mjordan (License 6283) 
  fax-mf-fix-2.diff uploaded by file (License 5000) 
  rtp_transfer_stuff uploaded by mjordan (License 6283) 
  rb3787.patch uploaded by rmudgett (License 5621) 
  media-formats-explicit-translate-format-3.diff uploaded by file (License 5000) 
  format_cache_case_fix.diff uploaded by opticron (License 6273) 
  rb3774.patch uploaded by rmudgett (License 5621) 
  rb3775.patch uploaded by rmudgett (License 5621) 
  rtp_engine_fix.diff uploaded by opticron (License 6273) 
  rtp_crash_fix.diff uploaded by opticron (License 6273) 
  rb3753.patch uploaded by mjordan (License 6283) 
  rb3750.patch uploaded by mjordan (License 6283) 
  rb3748.patch uploaded by rmudgett (License 5621) 
  media_format_fixes.diff uploaded by opticron (License 6273) 
  rb3740.patch uploaded by mjordan (License 6283) 
  rb3739.patch uploaded by mjordan (License 6283) 
  rb3734.patch uploaded by mjordan (License 6283) 
  rb3689.patch uploaded by mjordan (License 6283) 
  rb3674.patch uploaded by coreyfarrell (License 5909) 
  rb3671.patch uploaded by coreyfarrell (License 5909) 
  rb3667.patch uploaded by coreyfarrell (License 5909) 
  rb3665.patch uploaded by mjordan (License 6283) 
  rb3625.patch uploaded by coreyfarrell (License 5909) 
  rb3602.patch uploaded by coreyfarrell (License 5909) 
  format_compatibility-2.diff uploaded by file (License 5000) 
  core.diff uploaded by file (License 5000) 
  


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@419044 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-07-20 22:06:33 +00:00
Alexandr Anikin c63bf80c38 chan_ooh323: fix loading module failure if there no accessible h323_log or ooh323 config file
change return 1 to return AST_MODULE_LOAD_FAILURE on module load routine
few cosmetic changes

ASTERISK-23814 #close

(closes issue ASTERISK-23814)

Reported by: Igor Goncharovsky
Patches:
	ASTERISK-23814-ast11.patch
........

Merged revisions 415599 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 415602 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@415630 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-06-10 09:28:55 +00:00
Alexandr Anikin a35ce3924b process stack command even if gatekeeper client isn't register
don't destroy gatekeeper client if it is not started
don't destroy gatekeeper client in some sort of gatekeeper errors
signal rtp create condition when call cleared before rtp structure created

(closes issue ASTERISK-23460)

Reported by: Dmitry Melekhov
Patches:
	ASTERISK-23460-2.patch

Tested by: Dmitry Melekhov
........

Merged revisions 411531 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 411532 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@411533 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-03-28 18:00:18 +00:00
Scott Griepentrog 80ef9a21b9 uniqueid: channel linkedid, ami, ari object creation with id's
Much needed was a way to assign id to objects on creation, and
much change was necessary to accomplish it.  Channel uniqueids
and linkedids are split into separate string and creation time
components without breaking linkedid propgation.  This allowed
the uniqueid to be specified by the user interface - and those
values are now carried through to channel creation, adding the
assignedids value to every function in the chain including the
channel drivers. For local channels, the second channel can be
specified or left to default to a ;2 suffix of first.  In ARI,
bridge, playback, and snoop objects can also be created with a
specified uniqueid.

Along the way, the args order to allocating channels was fixed
in chan_mgcp and chan_gtalk, and linkedid is no longer lost as
masquerade occurs.

(closes issue ASTERISK-23120)
Review: https://reviewboard.asterisk.org/r/3191/
........

Merged revisions 410157 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@410158 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-03-07 15:47:55 +00:00
Alexandr Anikin 11ac08296b ignore AST_CONTROL_PVT_CAUSE_CODE without any messages
(closes issue ASTERISK-23336)
Reported by: Alexander Semych
........

Merged revisions 408838 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 408839 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@408840 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-02-22 18:01:20 +00:00
Richard Mudgett 3ccd5dee18 udptl: Dead code elimination. ast_udptl_bridge was not used.
Removing dead code starting with ast_udptl_bridge() eliminated the code in
this change.

Note: This code has actually been dead since Asterisk v1.4 when it was
first put in.

Review: https://reviewboard.asterisk.org/r/3079/
........

Merged revisions 404354 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404355 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-19 17:13:53 +00:00
Alexandr Anikin 1370d40559 Handle temporary failures on gk registration
Introduce new 'stopped' state for gk client and restart gk client
on failures
Remove ooh323 stack command lock as it is not need now.
(closes issue ASTERISK-21960)
Reported by: Dmitry Melekhov
Patches:
	ASTERISK-21960.patch
	ASTERISK-21960-stacklockup-2.patch
Tested by: Dmitry Melekhov
........

Merged revisions 404318 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 404320 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404321 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-19 08:35:28 +00:00
Kevin Harwell 28c0cb28d0 channel locking: Add locking for channel snapshot creation
Original commit message by mmichelson (asterisk 12 r403311):

"This adds channel locks around calls to create channel snapshots as well
as other functions which operate on a channel and then end up
creating a channel snapshot. Functions that expect the channel to be
locked prior to being called have had their documentation updated to
indicate such."

The above was initially committed and then reverted at r403398.  The problem
was found to be in core_local.c in the publish_local_bridge_message function.
The ast_unreal_lock_all function locks and adds a reference to the returned
channels and while they were being unlocked they were not being unreffed when
no longer needed.  Fixed by unreffing the channels.

Also in bridge.c a lock was obtained on "other->chan", but then an attempt was
made to unlock "other" and not the previously locked channel.  Fixed by
unlocking "other->chan"

(closes issue ASTERISK-22709)
Reported by: John Bigelow
........

Merged revisions 404237 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404260 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-18 20:33:37 +00:00
Alexandr Anikin 86b5e11607 Introduce new config option 'aniasdni'. If yes then asterisk set dialed number as own id back to the caller
on incoming h.323 calls. Option can be set globally or per user section.

(closes issue ASTERISK-22020)
Reported by: Ross Beer



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404211 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-18 19:36:39 +00:00
Joshua Colp e2630fcd51 channels: Return allocated channels locked.
This change makes ast_channel_alloc return allocated channels
locked. By doing so no other thread can acquire, lock, and manipulate
the channel before it is completely set up.

(closes issue AST-1256)

Review: https://reviewboard.asterisk.org/r/3067/
........

Merged revisions 404204 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404210 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-18 19:28:05 +00:00
Alexandr Anikin e23b8d19a4 Implement module reload command for chan_ooh323
(close issue ASTERISK-22817)

Patches:
	ooh323_module_reload.patch



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404198 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-18 19:10:42 +00:00
David M. Lee 1212906351 Reverting r403311. It's causing ARI tests to hang.
........

Merged revisions 403398 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403404 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-05 22:10:20 +00:00
Mark Michelson 8e8b329e14 Add channel locking for channel snapshot creation.
This adds channel locks around calls to create channel snapshots as well
as other functions which operate on a channel and then end up
creating a channel snapshot. Functions that expect the channel to be
locked prior to being called have had their documentation updated to
indicate such.
........

Merged revisions 403311 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403314 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-03 17:07:29 +00:00
Alexandr Anikin 879bd7aad9 Check and reject non-digits e164 values on peers and general sections in ooh323.conf
Regenerate e164 endpoint list on reload ooh323
(issue ASTERISK-22901)
Reported by: Cyril CONSTANTIN
Patches:
	ASTERISK-22901.patch
........

Merged revisions 403288 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 403290 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403292 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-02 18:12:57 +00:00
Mark Michelson ee21eee7e0 Cache string values of formats on ast_format_cap() to save processing.
Channel snapshots have string representations of the channel's native formats.
Prior to this change, the format strings were re-created on ever channel snapshot
creation. Since channel native formats rarely change, this was very wasteful.
Now, string representations of formats may optionally be stored on the ast_format_cap
for cases where string representations may be requested frequently. When formats
are altered, the string cache is marked as invalid. When strings are requested, the
cache validity is checked. If the cache is valid, then the cached strings are copied.
If the cache is invalid, then the string cache is rebuilt and copied, and the cache
is marked as being valid again.

Review: https://reviewboard.asterisk.org/r/2879
........

Merged revisions 400356 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400363 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-03 14:58:16 +00:00
Matthew Jordan 6258bbe7bd Update Asterisk's CDRs for the new bridging framework
This patch is the initial push to update Asterisk's CDR engine for the new
bridging framework. This patch guts the existing CDR engine and builds the new
on top of messages coming across Stasis. As changes in channel state and bridge
state are detected, CDRs are built and dispatched accordingly. This
fundamentally changes CDRs in a few ways.
(1) CDRs are now *very* reflective of the actual state of channels and bridges.
    This means CDRs track well with what an actual channel is doing - which
    is useful in transfer scenarios (which were previously difficult to pin
    down). It does, however, mean that CDRs cannot be 'fooled'. Previous
    behavior in Asterisk allowed for CDR applications, channels, and other
    properties to be spoofed in parts of the code - this no longer works.
(2) CDRs have defined behavior in multi-party scenarios. This behavior will not
    be what everyone wants, but it is a defined behavior and as such, it is
    predictable.
(3) The CDR manipulation functions and applications have been overhauled. Major
    changes have been made to ResetCDR and ForkCDR in particular. Many of the
    options for these two applications no longer made any sense with the new
    framework and the (slightly) more immutable nature of CDRs.

There are a plethora of other changes. For a full description of CDR behavior,
see the CDR specification on the Asterisk wiki.

(closes issue ASTERISK-21196)

Review: https://reviewboard.asterisk.org/r/2486/



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@391947 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-06-17 03:00:38 +00:00
Alexandr Anikin 12548000dc Multiple revisions 390228-390229
........
  r390228 | may | 2013-05-31 14:19:52 +0400 (Fri, 31 May 2013) | 14 lines
  
  reject call attempts when gatekeeper is configured but not registered
  
  (closes issue ASTERISK-21800)
  Reported by: Dmitry Melekhov
  Patches:
          ASTERISK-21800-1.patch
  Tested by: Dmitry Melekhov
  ........
  
  Merged revisions 390181 from http://svn.asterisk.org/svn/asterisk/branches/1.8
  ........
  
  Merged revisions 390223 from http://svn.asterisk.org/svn/asterisk/branches/10
........
  r390229 | may | 2013-05-31 14:34:20 +0400 (Fri, 31 May 2013) | 4 lines
  
  remove unnecessary declarations
  (issue ASTERISK-21800)
........

Merged revisions 390228-390229 from http://svn.asterisk.org/svn/asterisk/branches/11


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@390230 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-31 10:42:19 +00:00
Richard Mudgett 3d63833bd6 Merge in the bridge_construction branch to make the system use the Bridging API.
Breaks many things until they can be reworked.  A partial list:
chan_agent
chan_dahdi, chan_misdn, chan_iax2 native bridging
app_queue
COLP updates
DTMF attended transfers
Protocol attended transfers


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389378 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-21 18:00:22 +00:00
Alexandr Anikin 62e64134fa add ast_publish_channel_state according new event framework
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@389180 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-05-19 20:52:34 +00:00
Alexandr Anikin cb525e5c38 remove ALREADYGONE flag on ooh323 call data by ooh323_indicate
(CONGESTION/BUSY) due to call hasn't gone there really.
This indication arrive from asterisk core not h.323 stack

(closes issue ASTERISK-19308)
Reported by: Dmitry Melekhov
Patches:
        ASTERISK-19308.patch
........

Merged revisions 371089 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 371090 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@371091 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-08-10 16:49:27 +00:00
Alexandr Anikin 7709885125 Introdue 'ooh323 show gk' cli command that show status of connection
to H.323 Gatekeeper (GkClient state)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@371043 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-08-09 21:35:24 +00:00
Alexandr Anikin fa10f3f8a8 Added direct media support to ooh323 channel driver
options are documented in config sample
sample config rename to proper name - ooh323.conf

To change media address ooh323 send empty TCS if there was 
completed TCS exchange or send facility forwardedelements 
with new fast start proposal if not.
Then close transmit logical channels and renew TCS exchange.

If new fast start proposal is received then ooh323 stack call back
channel driver routine to change rtp address in the rtp instance.
If empty TCS is received then close transmit logical channels and
renew TCS exchange

Review: https://reviewboard.asterisk.org/r/1607/



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@369613 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-07-04 21:42:05 +00:00
Alexandr Anikin 5db7a15a0b use right definition for channel name
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@369141 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-06-20 11:20:05 +00:00