moodle/lib
David Mudrák 39d2c68856 MDL-61742 messaging: Do not send messages from inactive providers
Before this patch, we only checked that the given provider has been
configured in the user or system preferences. However, if the provider's
component is disabled, it does not even appear in these preferences.
Additionally, there was no check that the message / notification
provider is among providers allowed to be consumed by the recipient.

The patch checks that the message origin is among providers returned by
the message_get_providers_for_user() so disabled plugins can't act as
sources of messages and users can't receive messages from providers they
do not have capability for. This mitigates the risk of abusing a plugin
as a source of spam, for example.

Unit test is fixed and extended. When the $CFG->messaging is disabled,
no messages between users should be sent (I can't understand why the
unit test was written in an opposite way). Added assertions for the
raised debugging message.
2018-08-31 12:15:30 +02:00
..
adodb MDL-58546 libraries: Patch ADOdb for PHP 7.2 compat 2017-10-03 15:52:18 +08:00
ajax
amd Merge branch 'MDL-63094-master' of git://github.com/andrewnicols/moodle 2018-08-28 23:53:58 +02:00
antivirus MDL-62478 upgrade: add 3.5.0 separation line to all upgrade scripts 2018-05-28 13:15:48 +02:00
behat MDL-55365 behat: Remove deprecated api's in behat_config_mananger.php 2018-07-20 09:34:26 +02:00
bennu Merge branch 'MDL-62914-master' of git://github.com/lameze/moodle 2018-08-28 23:15:36 +02:00
classes MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
db MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
ddl MDL-59596 ddl: Support MariaDB 10.2.4+ SQL_MODE new default value. 2018-03-26 23:12:36 +02:00
dml MDL-61702 dml: MariaDB 10.3 supports only the Barracuda file format. 2018-05-31 22:55:00 +02:00
dtl
editor MDL-57281 behat: deprecated step definition I navigate to node in 2018-08-20 12:53:26 +01:00
evalmath MDL-14274 lib/evalmath: support of conditional math in formulas. 2018-06-26 10:25:44 +02:00
external MDL-57259 external: fix page url debug in fragment loading 2017-08-02 04:47:41 +00:00
filebrowser MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
filestorage MDL-60819 core_files: fix exception thrown from generate_image_thumbnail 2018-06-11 10:44:51 +08:00
fonts
form MDL-57281 behat: deprecated step definition I navigate to node in 2018-08-20 12:53:26 +01:00
geopattern-php MDL-61657 block_myoverview: implement course images for the myoverview block 2018-04-23 23:21:06 +02:00
google
grade MDL-36255 core_grade: fix to ensure correct context used for filters 2018-08-22 17:55:50 +08:00
horde MDL-60390 libraries: annonate horde upgrade to 2.30.2 2017-10-23 10:22:49 +08:00
html2text MDL-60238 libraries: Upgrade HTML2Text to 4.1.0 2017-10-02 08:43:33 +05:30
htmlpurifier Merge branch 'wip-MDL-60337-master' of git://github.com/marinaglancy/moodle 2017-10-16 15:40:44 +08:00
jabber
jquery MDL-60195 lib: Update of JQuery lib to 3.2.1 2017-10-06 11:36:41 +08:00
lessphp
ltiprovider MDL-61110 LTIProvider: Store 'lis_course_section_sourcedid' value in DB 2018-07-07 00:50:02 +03:00
markdown MDL-60239 libraries: patch Markdown for PHP7.2 2017-10-02 15:32:11 +08:00
maxmind MDL-60291 libraries: bump readme to actual versions 2017-10-12 00:47:22 +02:00
minify MDL-58550 libraries: Upgrade matthiasmullie libraries 2017-09-21 16:46:24 +05:30
mlbackend MDL-62361 versions: bump all versions and requires near release 2018-05-09 02:46:30 +02:00
mustache MDL-60286 lib: Update mustache to 2.12.0 2017-10-09 09:43:47 +08:00
pear MDL-60281 forms: PHP7.2 deprecations in PEAR 2017-10-16 09:37:20 +08:00
php-css-parser MDL-58646 lib: import latest sabberworm/PHP-CSS-Parser 2017-06-02 07:45:57 +01:00
phpexcel
phpmailer MDL-60194 lib: Update to phpmailer 6.0.1 2017-10-09 09:30:00 +08:00
phpunit MDL-61742 messaging: Do not send messages from inactive providers 2018-08-31 12:15:30 +02:00
portfolio MDL-62233 portfolio: check caller parent class 2018-05-10 09:13:03 +08:00
requirejs MDL-60458 javascript: MathJax Workaround 2017-10-25 12:30:21 +08:00
rtlcss
scssphp MDL-61529 core: update lib scssphp to version 0.7.5 2018-03-16 10:36:40 +01:00
simplepie MDL-60236 libraries: Upgrade simplepie to 1.5.0 2017-09-28 10:19:33 +05:30
spout MDL-60288 libraries: Upgrade spout to 2.7.3 2017-10-12 11:32:15 +05:30
tcpdf MDL-60237 libraries: TCPDF apply patch for PHP7.2 2017-10-09 10:02:56 +08:00
templates MDL-62515 templates: Remove unnecessary button role for submit button 2018-05-21 09:32:56 +08:00
testing MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
tests MDL-61742 messaging: Do not send messages from inactive providers 2018-08-31 12:15:30 +02:00
typo3
userkey MDL-62047 core_userkey: Add privacy implementation 2018-04-19 15:30:10 +08:00
xhprof MDL-63031 administration: Allow plugins to define trace storage 2018-08-13 21:54:48 -06:00
xmldb MDL-62783 XMLDB: Generate PHP with [] arrays 2018-06-22 13:58:27 +01:00
yui MDL-60207 javascript: remove click handler in YUI modal initialiser 2018-05-29 10:05:00 +08:00
yuilib
accesslib.php MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
adminlib.php Merge branch 'MDL-59595-master-2' of git://github.com/snake/moodle 2018-08-02 00:21:23 +02:00
authlib.php MDL-40613 auth_ldap: removed usage of profile_load_custom_fields() 2018-01-03 18:13:01 +08:00
badgeslib.php MDL-55491 badges: Add cohort as badge criteria 2018-04-09 10:23:50 +02:00
blocklib.php MDL-61621 blocks: New API function 2018-04-06 13:12:30 +02:00
boxlib.php
cacert.pem
cacert.txt
clilib.php
completionlib.php MDL-37933 core_complete: fixed criteria/criterion naming confusion 2017-11-27 15:26:43 +08:00
componentlib.class.php
conditionlib.php
configonlylib.php
cookies.js
coursecatlib.php MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
cronlib.php MDL-61800 task: Reset the OUTPUT and PAGE on execution 2018-05-02 11:57:13 +08:00
csslib.php MDL-59148 css: Remove legacy param from php-doc 2017-06-28 18:24:50 +02:00
csvlib.class.php
customcheckslib.php
dataformatlib.php MDL-60443 dataformat lib: Change a wrong variable name 2017-12-06 19:53:34 +13:00
datalib.php MDL-36255 core_grade: fix to ensure correct context used for filters 2018-08-22 17:55:50 +08:00
ddllib.php
default.ttf
deprecatedlib.php MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
dmllib.php MDL-59581 database: remove mssql references from lib/ files 2018-04-09 02:00:09 +02:00
dtllib.php
editorlib.php
emptyfile.php
enrollib.php MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
environmentlib.php MDL-51080 env: warn when running MariaDB w/ wrong dbtype 2018-06-14 23:54:35 +02:00
excellib.class.php MDL-51419 core_files: Support for utf8 in file names in MS Edge 2018-06-22 10:29:23 +08:00
externallib.php MDL-63131 Web services: Callback to allow web service overrides 2018-08-20 15:32:34 +01:00
filelib.php MDL-36754 core_files: Add back missing baseurl line 2018-08-14 15:54:12 +08:00
filterlib.php Merge branch 'wip-nolink-bug' of https://gitlab.di.unito.it/rabellino/moodle 2018-07-04 14:37:14 +08:00
flickrclient.php MDL-59645 oauth1: Implement a new simple Flickr API client 2017-09-19 14:44:41 +02:00
flickrlib.php MDL-59645 flickrlib: Show debug notice when using legacy authentication 2017-09-19 14:44:41 +02:00
formslib.php MDL-63001 core_form: final deprecation of the submitlink element 2018-07-27 16:05:28 +08:00
gdlib.php
googleapi.php MDL-60733 core: B/C for google_oauth 2017-11-08 15:41:53 +08:00
gradelib.php MDL-63002 core: fixed incorrect calls to non-existent delete_record() 2018-07-30 20:59:42 +08:00
graphlib.php
grouplib.php MDL-60826 groups: deprecate groups_get_all_groups_for_courses function 2018-07-24 07:58:35 +08:00
index.html
installlib.php MDL-60108 registration: Redirect to registration form 2017-10-17 15:00:17 +08:00
javascript-static.js
javascript.php
jslib.php
ldaplib.php MDL-57558 ldap: fix ldap_get_entries_moodle() 2017-05-16 10:48:27 +01:00
lexer.php
licenselib.php
listlib.php MDL-61557 Lib: Add get_top_level_parent_id function 2018-03-05 13:34:08 +11:00
mathslib.php MDL-14274 lib/evalmath: support of conditional math in formulas. 2018-06-26 10:25:44 +02:00
messagelib.php MDL-61742 messaging: Do not send messages from inactive providers 2018-08-31 12:15:30 +02:00
modinfolib.php MDL-61876 modules: cm_info::set_content can accept formatted text 2018-05-07 11:27:56 +08:00
moodlelib.php MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
myprofilelib.php MDL-60548 profile: Show profile email when 'maildisplay' allows it. 2018-01-15 12:21:09 +00:00
navigationlib.php MDL-62742 core: rename coursecat->core_course_category 2018-08-28 11:36:23 +02:00
oauthlib.php MDL-59512 tool_oauth2: add option for basic authentication 2017-11-17 10:15:29 +01:00
odslib.class.php
outputactions.php
outputcomponents.php Merge branch 'MDL-62884-master' of git://github.com/damyon/moodle 2018-08-17 16:02:05 +08:00
outputfactories.php
outputfragmentrequirementslib.php
outputlib.php Merge branch 'MDL-59261-master' of git://github.com/ryanwyllie/moodle 2018-07-03 14:44:32 +08:00
outputrenderers.php MDL-36754 output: Support token pluginfiles in userpic 2018-08-14 07:08:29 +08:00
outputrequirementslib.php MDL-62712 Filepicker: Improve upload process 2018-07-10 15:18:45 +07:00
pagelib.php MDL-61601 cohort: Add theme support for cohorts 2018-04-06 08:28:01 +02:00
pdflib.php
phpminimumversionlib.php MDL-57432 environment: raise Moodle 3.4 requirements 2017-07-10 09:16:55 +01:00
plagiarismlib.php
portfoliolib.php MDL-62233 portfolio: check caller parent class 2018-05-10 09:13:03 +08:00
questionlib.php Merge branch 'wip-MDL-62742-master' of git://github.com/marinaglancy/moodle 2018-08-29 08:31:08 +08:00
recaptchalib.php
recaptchalib_v2.php MDL-61600 recaptcha: Create a script to display recaptcha 2018-03-14 10:31:09 +01:00
requirejs.php MDL-59431 requirejs: Prioritise errors 2017-07-12 10:05:59 +08:00
resourcelib.php
rsslib.php
searchlib.php MDL-46929 mod_forum: Fix for edge cases when searching 2017-04-11 08:30:09 +01:00
sessionkeepalive_ajax.php
sessionlib.php MDL-42834 admin: Remove loginhttps 2017-10-23 12:25:35 +08:00
setup.php MDL-55188 events: First deprecation of eventslib.php 2018-07-30 09:23:54 +08:00
setuplib.php MDL-60923 backup: Added $CFG->backuptempdir 2018-04-16 23:50:28 +02:00
soaplib.php
statslib.php MDL-50666 core: Add function get_viewable_roles to set role visibility 2017-12-19 13:53:23 +13:00
tablelib.php MDL-62618 user: Display full names consistently on users page 2018-07-05 10:08:33 +08:00
thirdpartylibs.xml MDL-61657 block_myoverview: implement course images for the myoverview block 2018-04-23 23:21:06 +02:00
tokeniserlib.php
upgrade.txt Merge branch 'MDL-62657-master' of git://github.com/junpataleta/moodle 2018-08-29 09:30:07 +08:00
upgradelib.php Merge branch 'MDL-56712-master' of git://github.com/mihailges/moodle 2018-07-30 17:47:51 +02:00
uploadlib.php
validateurlsyntax.php MDL-59255 core: Add rtmp:// support to validateUrlSyntax function. 2017-07-18 10:29:07 +01:00
webdavlib.php MDL-60281 general: function each() is deprecated in PHP7.2 2017-10-16 09:37:20 +08:00
weblib.php MDL-36754 output: Support token pluginfiles in group pic 2018-08-14 07:06:09 +08:00
wiki_to_markdown.php
womenslib.php
wordlist.txt
xhtml.xsl
xmlize.php MDL-61619 core: use empty string instead of null in xmlize 2018-03-12 11:12:00 +08:00
xsendfilelib.php