Age | Commit message (Collapse) | Author |
|
|
|
injection" into 13
|
|
sanitize_tdata was assuming all URIs were SIP URIs so when a non
SIP uri was in the From, To or Contact headers, the unconditional
cast of a non-pjsip_sip_uri structure to pjsip_sip_uri caused
a segfault when trying to access uri->other_param.
* Added PJSIP_URI_SCHEME_IS_SIP(uri) || PJSIP_URI_SCHEME_IS_SIPS(uri)
checks before attempting to cast or use the returned uri.
ASTERISK-27152
Reported-by: Ross Beer
Change-Id: Id380df790e6622c8058a96035f8b8f4aa0b8551f
|
|
An admin can configure app_minivm with an externnotify program to be run
when a voicemail is received. The app_minivm application MinivmNotify
uses ast_safe_system() for this purpose which is vulnerable to command
injection since the Caller-ID name and number values given to externnotify
can come from an external untrusted source.
* Add ast_safe_execvp() function. This gives modules the ability to run
external commands with greater safety compared to ast_safe_system().
Specifically when some parameters are filled by untrusted sources the new
function does not allow malicious input to break argument encoding. This
may be of particular concern where CALLERID(name) or CALLERID(num) may be
used as a parameter to a script run by ast_safe_system() which could
potentially allow arbitrary command execution.
* Changed app_minivm.c:run_externnotify() to use the new ast_safe_execvp()
instead of ast_safe_system() to avoid command injection.
* Document code injection potential from untrusted data sources for other
shell commands that are under user control.
ASTERISK-27103
Change-Id: I7552472247a84cde24e1358aaf64af160107aef1
|
|
This change moves the logic which learns a new source address
for RTP so it only occurs in the learning state. The learning
state is entered on initial allocation of RTP or if we are
told that the remote address for the media has changed. While
in the learning state if we continue to receive media from
the original source we restart the learning process. It is
only once we receive a sufficient number of RTP packets from
the new source that we will switch to it. Once this is done
the closed state is entered where all packets that do not
originate from the expected source are dropped.
The learning process has also been improved to take into
account the time between received packets so a flood of them
while in the learning state does not cause media to be switched.
Finally RTCP now drops packets which are not for the learned
SSRC if strict RTP is enabled.
ASTERISK-27013
Change-Id: I56a96e993700906355e79bc880ad9d4ad3ab129c
|
|
|
|
Change-Id: I1e33290929e1aa7c5b9cb513f8254f2884974de8
|
|
|
|
If an SDP answer hasn't been sent yet, it's legal to change it.
This is required for PJSIP_DTMF_MODE to work correctly, and can
also have use in the future for updating codecs too.
ASTERISK-27209 #close
Change-Id: Idbbfb7cb3f72fbd96c94d10d93540f69bd51e7a1
|
|
fetch_access_token calls func_curl via ast_func_read. The latter returns 0 upon
success and -1 if the function is not available.
This commit inverts the return code check so that an error is printed if the
module is not loaded and not if it is loaded.
ASTERISK-27207 #close
Change-Id: I9ef903f80702d1218e8701f65a4e5e918e6548fb
|
|
When looking for recurring events, use the correct end time based on the
configured 'timeframe.'
ASTERISK-27174 #close
Reported by: Mark Thompson
Change-Id: Id90c3cfc79d561a5521d79be176683e225f2edef
|
|
* Check that the contact's reg_server matches the host's name before
deleting any prune_on_boot contacts. We don't want to delete reliable
transport contacts made with other servers if the ps_contacts database
table is shared with other servers.
Thanks to Ross Beer for pointing out that the original prune logic would
delete reliable transport contacts from other servers.
ASTERISK-27147
Change-Id: I8e439d0d1c266ffdfd7b73d1e5e466180a689bd0
|
|
|
|
Add ability to use tokens instead of passwords according to Google OAuth 2.0
protocol.
ASTERISK-27169
Reported by: Andrey Egorov
Tested by: Andrey Egorov
Change-Id: I07f7052a502457ab55010a4d3686653b60f4c8db
|
|
The fix for the issue is broken up into three parts.
This is part three which handles the client side of REGISTER requests.
The registered contact may no longer be valid on the server when the
transport used is reliable and the connection is broken.
* Re-REGISTER our contact if the reliable transport is broken after
registration completes. We attempt to re-REGISTER immediately to minimize
the time we are unreachable. Time may have already passed between the
connection being broken and the loss being detected.
* Reorder sip_outbound_registration_state_alloc() so the STATSD_GUAGE's
are still correct if an allocation failure happens.
ASTERISK-27147
Change-Id: I3668405b1ee75dfefb07c0d637826176f741ce83
|
|
The fix for the issue is broken up into three parts.
This is part two which handles the server side of REGISTER requests when
rewrite_contact is enabled. Any registered reliable transport contact
becomes invalid when the transport connection becomes disconnected.
* Monitor the rewrite_contact's reliable transport REGISTER contact for
shutdown. If it is shutdown then the contact must be removed because it
is no longer valid. Otherwise, when the client attempts to re-REGISTER it
may be blocked because the invalid contact is there. Also if we try to
send a call to the endpoint using the invalid contact then the endpoint is
not likely to see the request. The endpoint either won't be listening on
that port for new connections or a NAT/firewall will block it.
* Prune any rewrite_contact's registered reliable transport contacts on
boot. The reliable transport no longer exists so the contact is invalid.
* Websockets always rewrite the REGISTER contact address and the transport
needs to be monitored for shutdown.
* Made the websocket transport set a unique name since that is what we use
as the ao2 container key. Otherwise, we would not know which transport we
find when one of them shuts down. The names are also used for PJPROJECT
debug logging.
* Made the websocket transport post the PJSIP_TP_STATE_CONNECTED state
event. Now the global keep_alive_interval option, initially idle shutdown
timer, and the server REGISTER contact monitor can work on wetsocket
transports.
* Made the websocket transport set the PJSIP_TP_DIR_INCOMING direction.
Now initially idle websockets will automatically shutdown.
ASTERISK-27147
Change-Id: I397a5e7d18476830f7ffe1726adf9ee6c15964f4
|
|
The fix for the issue is broken up into three parts.
This is part one which refactors the transport state monitor code to allow
more modules to be able to monitor transports.
* Pull the management of PJPROJECT's transport state callback code from
res_pjsip_transport_management.c into res_pjsip. Now other modules can
dynamically add and remove themselves from transport monitoring without
worrying about breaking PJPROJECT's callback chain.
* Add the ability for other modules to get a callback whenever a specific
transport is shutdown.
ASTERISK-27147
Change-Id: I7d9a31371eb1487c9b7050cf82a9af5180a57912
|
|
* Use monitored instead of the misleading keepalive name.
Change-Id: I9e5bcbb4ab2b82d49bcd0f06dfe85d15e0b552b6
|
|
|
|
When handling an incoming SIP MESSAGE, PJSIP
attaches the IP address that the message was
received from to the message in the variable
PJSIP_RECVADDR. When the IP address is IPv6
the :PORT appended results in an unparseable
mess. By using an additional bit flag on the
pj_sockaddr_print call, the conventional use
of brackets around the address is achieved.
ASTERISK-27193 #close
Change-Id: I12342521f2ce87a5b6e4883d480a3fd957aa9fd9
|
|
|
|
|
|
into 13
|
|
|
|
|
|
Asterisk wasn't generating or forwarding RTCP packets when native
bridge was activated. Also the stats weren't available via
CHANNEL(qos). Now the RTCP stats are always calculated.
ASTERISK-27158 #close
Change-Id: I46fb8f61c95e836b9d2dda6054b0cf205c16037b
|
|
A change was made long ago where the session was kept around
until the underlying INVITE session had been destroyed. This
had the side effect of also keeping the underlying media resources
around for this time as well.
This change ensures that when we know the session is ending we
release the media resources immediately.
ASTERISK-27110
Change-Id: I643e431d5c3bf05cda220c1d39e824a505a29b82
|
|
|
|
Support building the Asterisk httpd with version 3.0 of gmime as
well as earlier versions of that library.
ASTERISK-27173
Change-Id: I7e13dd05a3083ccb0df2dabf83110223f6a9fa8f
|
|
|
|
Introduce a new property to rtp-engine to make it aware of
the desire for assymetric codecs or not. If asymmetric codecs
is not allowed, the bridge will compare read/write formats
and shut down the p2p bridge if needed
ASTERISK-26745 #close
Change-Id: I0d9c83e5356df81661e58d40a8db565833501a6f
|
|
Change-Id: Ib5a19bfd597f63d9021baeb645fc11153b3afa57
|
|
* Remove unnecessary CMP_STOP.
* In handle_client_registration() use DEBUG_ATLEAST() to only do work
needed for the debug log message when the debug log message is needed.
* In sip_outbound_registration_state_destroy() check state->registration
for NULL.
Change-Id: I656d0fa11dda0b00048103efb1558e67a426fd80
|
|
Change-Id: I6279b0d723bc3b75b8d65e81e02da9ea9bc0c3da
|
|
Most uses of CMP_STOP are superfluous and are only respected when
OBJ_MULTIPLE is used to search the container.
Change-Id: I20571a202ec0aa1098bb2749eeba18de7ca110b8
|
|
This reverts commit 98709642d640b490f327d220fdcdea6d45fd65d7.
See the 15 branch review.
Change-Id: I8476b3cdacaad5157fa36b6247d0e4cdf1e8d5c6
|
|
A change was made long ago where the session was kept around
until the underlying INVITE session had been destroyed. This
had the side effect of also keeping the underlying media resources
around for this time as well.
This change ensures that when we know the session is ending we
release the media resources immediately.
ASTERISK-27110
Change-Id: I3c6a82fe7d2c50b9dc9197cb12ef22f20d337501
|
|
This change fixes PIDF content generation when the underlying device
state is considered in use. Previously it was incorrectly marked
as closed meaning they were offline/unavailable. The code now
correctly marks them as open.
Additionally:
* Generate an XML element for our activity instead of a using a text
node.
* Consider every extension state other than "unavailable" to be 'open'
status.
* Update the XML namespaces and structure to reflect those
documented in RFC 4480
* Use 'on-the-phone' (defined in RFC 4880) instead of 'busy' as the
"in use" activity. This change results in eyeBeam using the
appropriate icon for the watched user.
This was tested on eyeBeam 1.5.20.2 build 59030 on Windows.
ASTERISK-26659 #close
Reported by: Abraham Liebsch
patches:
ASTERISK-26659.diff submitted by snuffy (license 5024)
Change-Id: I6e5ad450f91106029fb30517b8c0ea0c2058c810
|
|
The "external_media_address" option on transports is now
resolved using dnsmgr. This allows it to be automatically
refreshed regularly if refreshes are enabled in dnsmgr.
If the system is using a dynamic IP address a dynamic DNS
hostname can be provided to keep the IP address up to
date.
Change-Id: Ia54771720dff0105bde55d5bbb81a3ba437e05b2
|
|
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
|
|
This function is a replica of SIPDtmfMode, allowing the DTMF mode of a
PJSIP call to be modified on a per-call basis
ASTERISK-27085 #close
Change-Id: I20eef5da3e5d1d3e58b304416bc79683f87e7612
|
|
Change-Id: Ia578ede1a55b21014581793992a429441903278b
|
|
Case scenario with Applications ARI:
* Once you subscribe to deviceState with Applications REST API, it will be
added into subscription pool.
* When you unsubscribe it will remove from the device_state_subscription
hash table but not from the subscription pool.
* When you subscribe again, it will add it to pool again.
* Now you will have two subscriptions and you will receive same event
twice.
This fix should now remove deviceState subscription from pool and it
should fix unsubscribe on deviceState.
ASTERISK-27130 #close
Change-Id: I718b70d770a086e39b4ddba4f69a3c616d4476c4
|
|
into 13
|
|
This change makes it so that if an RTCP packet is being sent
the RTP ICE component is used for sending if RTCP-MUX is in use.
ASTERISK-27133
Change-Id: I6200f611ede709602ee9b89501720c29545ed68b
|
|
Currently when rtp is paused, no packets are written to the
recorded audio file, causing the silence to be skipped and recording
not properly time aligned. The read handler as been adapted to
return a silence frame of the correct size.
ASTERISK-27128 #close
Change-Id: I2d7f60650457860b9c70907b14426756b058a844
|
|
|
|
By default, when res_musiconhold reloads or unloads, it sends a HUP
signal to custom applications (and all descendants), waits 100ms,
then sends a TERM signal, waits 100ms, then finally sends a KILL
signal. An application which is interacting with an external
device and/or spawns children of its own may not be able to exit
cleanly in the default times, expecially if sent a KILL signal, or
if it's children are getting signals directly from
res_musiconhoild.
* To allow extra time, the 'kill_escalation_delay'
class option can be used to set the number of milliseconds
res_musiconhold waits before escalating kill signals, with the
default being the current 100ms.
* To control to whom the signals are sent, the "kill_method" class
option can be set to "process_group" (the default, existing
behavior), which sends signals to the application and its
descendants directly, or "process" which sends signals only to the
application itself.
Change-Id: Iff70a1a9405685a9021a68416830c0db5158603b
|
|
into 13
|
|
If the from_user field contains certain characters (like @, {, ^, etc.),
PJSIP will return a null value for the URI when attempting to parse it.
This causes a crash when trying to dial out through a trunk that contains
these invalid characters in its from_user field.
This change checks the configuration and ensures that an endpoint will
not be created if the from_user contains an invalid character. It also
adds a null check to the PJSIP URI parsing as a backup.
ASTERISK-27036 #close
Reported by: Maxim Vasilev
Change-Id: I0396fdb5080604e0bdf1277464d5c8a85db913d0
|