Compare commits

..

68 Commits

Author SHA1 Message Date
Eloy Lafuente (stronk7) 25fd679aaf Moodle release 3.1.8 2017-09-09 22:48:00 +02:00
Eloy Lafuente (stronk7) 93cca9afbe Merge branch 'install_31_STABLE' of https://git.in.moodle.com/amosbot/moodle-install into MOODLE_31_STABLE 2017-09-09 22:47:57 +02:00
David Mudrák 26663756fb MDL-59969 admin: Warn admins if a development libs directory exists
We can't really control the direct web access to directories in dirroot,
that is part of the server setup. So we at least warn admins as they may
not realize the risks of having directories like vendor or node_modules
exposed.

Credit goes to Petr Škoda for mentioning the PHPUnit issue CVE-2017-9841
to me.
2017-09-05 21:59:01 +08:00
Marina Glancy e404606458 MDL-59972 mod_feedback: escape subject when showing the contact form 2017-09-04 11:31:15 +08:00
Jake Dallimore 68b925e274 MDL-58953 user: additional test case for user_can_view_profile() 2017-08-30 10:35:51 +08:00
Jake Dallimore 0a8190569f MDL-58953 user: fix course checking logic in user_can_view_profile()
Make sure to check that $user in enrolled in $course before checking
whether the current user has capabilities in that course, and make sure
that we don't check user context caps when handling a specific course.
2017-08-30 10:35:51 +08:00
AMOS bot d95fb5245b Automatically generated installer lang files 2017-08-29 00:08:35 +08:00
AMOS bot fcea6de794 Automatically generated installer lang files 2017-08-28 00:10:01 +08:00
AMOS bot e5b89df732 Automatically generated installer lang files 2017-08-26 00:07:44 +08:00
AMOS bot 67ea841f41 Automatically generated installer lang files 2017-08-25 00:06:23 +08:00
AMOS bot a64872eb59 Automatically generated installer lang files 2017-08-25 00:06:23 +08:00
AMOS bot 5d20a3ed14 Automatically generated installer lang files 2017-08-17 00:09:03 +08:00
Simey Lameze 39aacd1dfe MDL-59776 core_calendar: unit tests of module events deletion 2017-08-15 11:34:25 +08:00
Simey Lameze bc312c648a MDL-59776 core_calendar: prevent deletion of module events 2017-08-15 11:34:25 +08:00
AMOS bot b545f830d0 Automatically generated installer lang files 2017-08-14 00:09:03 +08:00
AMOS bot 5325b4efe1 Automatically generated installer lang files 2017-07-31 00:10:57 +08:00
AMOS bot c6d38b89dc Automatically generated installer lang files 2017-07-29 00:11:21 +08:00
AMOS bot 73e0775d26 Automatically generated installer lang files 2017-07-26 00:08:17 +08:00
AMOS bot e4eb50ae15 Automatically generated installer lang files 2017-07-23 00:09:26 +08:00
AMOS bot 34e60f0dbf Automatically generated installer lang files 2017-07-22 00:08:38 +08:00
AMOS bot 5f2a1f0c36 Automatically generated installer lang files 2017-07-21 00:07:28 +08:00
Juan Leyva 1357976049 MDL-58762 core: Get full course objects on navigation
The course object passed as parameter to extend_navigation_user
callback contained only a few parameters, some parameters like
showgrades or showreports were missing.
The callback should receive a full course object.
2017-07-20 20:23:43 +08:00
Juan Leyva 9f7af133fd MDL-58762 report: Check group permissions in course user reports
Teachers were able to see any student report even with forced separated
groups and capability moodle/course:accessallgroups off.
2017-07-20 20:23:43 +08:00
Dan Poltawski 0faa1175fe weekly release 3.1.7+ 2017-07-20 13:21:01 +01:00
Dan Poltawski f3fe4f52e1 Merge branch 'install_31_STABLE' of https://git.in.moodle.com/amosbot/moodle-install into MOODLE_31_STABLE 2017-07-20 13:21:00 +01:00
Andrew Nicols 45a405014e Merge branch 'wip-MDL-57649-31-fix2' of git://github.com/abgreeve/moodle into MOODLE_31_STABLE 2017-07-20 10:24:43 +08:00
Adrian Greeve b77e45119c MDL-57649 mod_lesson: Improvement to upgrade query.
We only need one record for each filearea that we
are removing.
2017-07-20 10:03:29 +08:00
AMOS bot 9a3855aa00 Automatically generated installer lang files 2017-07-20 00:07:29 +08:00
Dan Poltawski f06abbd040 Merge branch 'wip-MDL-57649-31-fix' of git://github.com/abgreeve/moodle into MOODLE_31_STABLE 2017-07-19 09:33:31 +01:00
Adrian Greeve 9e1375fac0 MDL-57649 mod_lesson: Additional refinement to upgrade script. 2017-07-19 15:48:59 +08:00
Dani Palou 62be5f6154 MDL-59068 lesson: Revert MDL-54849
MDL-54859 made the 'wrong jump' setting useless, since clicking 'No' always sends the user to the next page.
2017-07-17 10:10:22 +02:00
Dan Poltawski 5db085f0a7 Merge branch 'wip-MDL-57649-31' of git://github.com/abgreeve/moodle into MOODLE_31_STABLE 2017-07-17 09:01:12 +01:00
Adrian Greeve 734fb0f015 MDL-57649 mod_lesson: Delete answer files correctly.
The files associated with answers and responses were
not being deleted due to the fact that the wrong itemid
was being used.
2017-07-17 09:20:40 +08:00
AMOS bot 0fd90e2044 Automatically generated installer lang files 2017-07-17 00:07:23 +08:00
Dan Poltawski ab4afd711a weekly release 3.1.7+ 2017-07-14 11:46:55 +01:00
Dan Poltawski 4fc794b7ef Merge branch 'install_31_STABLE' of https://git.in.moodle.com/amosbot/moodle-install into MOODLE_31_STABLE 2017-07-14 11:46:54 +01:00
Eloy Lafuente (stronk7) f883e31728 Merge branch 'MDL-57432-31' of git://github.com/danpoltawski/moodle into MOODLE_31_STABLE 2017-07-11 10:18:31 +02:00
AMOS bot c2e08a97c1 Automatically generated installer lang files 2017-07-11 00:07:01 +08:00
Dan Poltawski cd7cd469ae MDL-57432 environment: raise Moodle requirement
Due to Moodle 2.7 and Moodle 3.4 not having a common compatible php version
between them to upgrade from Moodle 3.4 from Moodle 2.7 you'll need to upgrade
to a higher version first or upgrade php at the same time as upgrade,
this encourages the former.
2017-07-10 09:22:51 +01:00
Dan Poltawski 43d1a8695c MDL-57432 environment: raise Moodle 3.4 requirements
1) PHP minimum version raised to 7.0.0
2) Intl extension raised from optional to required
2017-07-10 09:22:51 +01:00
Dan Poltawski 499e619868 MDL-57432 environment: 3.4 base information
This is a direct copy of the 3.3 branch to
have changes under control easier in next commits.
2017-07-10 09:22:51 +01:00
Eloy Lafuente (stronk7) 914ce2602e Moodle release 3.1.7 2017-07-08 20:43:29 +02:00
AMOS bot 43663a70af Automatically generated installer lang files 2017-07-08 00:16:44 +08:00
Jake Dallimore c072f462c6 weekly release 3.1.6+ 2017-07-07 12:10:24 +08:00
Jake Dallimore 99b4c8bb10 Merge branch 'install_31_STABLE' of https://git.in.moodle.com/amosbot/moodle-install into MOODLE_31_STABLE 2017-07-07 12:10:22 +08:00
AMOS bot 6e1f0e9527 Automatically generated installer lang files 2017-07-07 00:06:52 +08:00
Simey Lameze bd83aa0cd6 MDL-59456 auth_cas: patch phpCAS auth bypass vulnerability 2017-07-06 09:36:17 +01:00
Marina Glancy c7a89d2009 MDL-59409 admin: set admin user in unittest 2017-07-04 11:05:41 +08:00
Ankit Agarwal 548c5fa21e MDL-56565: core_message\helper was not present in 3.1, remove it 2017-07-04 10:11:39 +08:00
Ankit Agarwal 106fa63926 MDL-56565 forum: Add sitename as heading when there is nothing to display 2017-07-04 10:11:39 +08:00
Ankit Agarwal 5176a91648 MDL-56565 forum: Make sure userfullname is not disclosed 2017-07-04 10:11:39 +08:00
Jake Dallimore 540a38d586 MDL-56565 navigation: fix for cap checks in nav and context header
Fix to:
- Make sure we properly check both user and course contexts in
the load_for_user function in navigation lib and user the
user_can_view_profile function for same-course access checks.
- Use user_can_view_profile in the renderer's context_header to
properly decide whether a user can view another user's picture
and messaging options in the page header.
2017-07-04 10:11:39 +08:00
Jake Dallimore 47f81ef27f MDL-56565 navigation: fix user details disclosure in nav tree
Fixes a bug in which a user's full name might be disclosed via the
nav tree. Nav generation now checks the current user's access to the
user before adding the node, else adds a dummy node.
2017-07-04 10:11:39 +08:00
Jake Dallimore d4fa90b0e9 MDL-56565 core: fix user details disclosure in page context header
Fixes a bug with context_header function in which user details were
displayed regardless of the current user's capabilities.
2017-07-04 10:11:39 +08:00
Marina Glancy 033429a51c MDL-59409 admin: check access to every setting in category 2017-07-04 10:06:01 +08:00
AMOS bot 3c8e25328c Automatically generated installer lang files 2017-06-26 00:12:32 +08:00
AMOS bot bd08b92fcb Automatically generated installer lang files 2017-06-23 00:08:21 +08:00
AMOS bot 13add2b85c Automatically generated installer lang files 2017-06-11 00:06:40 +08:00
AMOS bot e42fa42955 Automatically generated installer lang files 2017-06-04 00:07:40 +08:00
AMOS bot bbbaa37cc5 Automatically generated installer lang files 2017-06-04 00:07:40 +08:00
AMOS bot 7c26a6bd77 Automatically generated installer lang files 2017-06-03 00:08:20 +08:00
AMOS bot ebbf9851c8 Automatically generated installer lang files 2017-06-01 00:12:59 +08:00
AMOS bot 65cd459455 Automatically generated installer lang files 2017-05-23 00:06:03 +08:00
AMOS bot df91963a70 Automatically generated installer lang files 2017-05-18 00:07:35 +08:00
AMOS bot eb58b204ff Automatically generated installer lang files 2017-05-16 00:07:39 +08:00
AMOS bot 11106c1bcc Automatically generated installer lang files 2017-05-14 00:05:09 +08:00
AMOS bot 6e76ce1689 Automatically generated installer lang files 2017-05-13 00:04:59 +08:00
AMOS bot bbe6b470aa Automatically generated installer lang files 2017-05-11 00:05:01 +08:00
64 changed files with 703 additions and 262 deletions
+1 -1
View File
@@ -89,7 +89,7 @@ if ($PAGE->user_allowed_editing()) {
$savebutton = false;
$outputhtml = '';
foreach ($settingspage->children as $childpage) {
if ($childpage->is_hidden()) {
if ($childpage->is_hidden() || !$childpage->check_access()) {
continue;
}
if ($childpage instanceof admin_externalpage) {
+176
View File
@@ -2081,4 +2081,180 @@
</CUSTOM_CHECK>
</CUSTOM_CHECKS>
</MOODLE>
<MOODLE version="3.4" requires="3.0">
<UNICODE level="required">
<FEEDBACK>
<ON_ERROR message="unicoderequired" />
</FEEDBACK>
</UNICODE>
<DATABASE level="required">
<VENDOR name="mariadb" version="5.5.31" />
<VENDOR name="mysql" version="5.5.31" />
<VENDOR name="postgres" version="9.3" />
<VENDOR name="mssql" version="10.0" />
<VENDOR name="oracle" version="10.2" />
</DATABASE>
<PHP version="7.0.0" level="required">
</PHP>
<PCREUNICODE level="optional">
<FEEDBACK>
<ON_CHECK message="pcreunicodewarning" />
</FEEDBACK>
</PCREUNICODE>
<PHP_EXTENSIONS>
<PHP_EXTENSION name="iconv" level="required">
<FEEDBACK>
<ON_ERROR message="iconvrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="mbstring" level="optional">
<FEEDBACK>
<ON_CHECK message="mbstringrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="curl" level="required">
<FEEDBACK>
<ON_ERROR message="curlrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="openssl" level="required">
<FEEDBACK>
<ON_ERROR message="opensslrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="tokenizer" level="optional">
<FEEDBACK>
<ON_CHECK message="tokenizerrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="xmlrpc" level="optional">
<FEEDBACK>
<ON_CHECK message="xmlrpcrecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="soap" level="optional">
<FEEDBACK>
<ON_CHECK message="soaprecommended" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="ctype" level="required">
<FEEDBACK>
<ON_ERROR message="ctyperequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="zip" level="required">
<FEEDBACK>
<ON_ERROR message="ziprequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="zlib" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="gd" level="required">
<FEEDBACK>
<ON_ERROR message="gdrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="simplexml" level="required">
<FEEDBACK>
<ON_ERROR message="simplexmlrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="spl" level="required">
<FEEDBACK>
<ON_ERROR message="splrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="pcre" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="dom" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="xml" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="xmlreader" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="intl" level="required">
<FEEDBACK>
<ON_ERROR message="intlrequired" />
</FEEDBACK>
</PHP_EXTENSION>
<PHP_EXTENSION name="json" level="required">
</PHP_EXTENSION>
<PHP_EXTENSION name="hash" level="required"/>
<PHP_EXTENSION name="fileinfo" level="required"/>
</PHP_EXTENSIONS>
<PHP_SETTINGS>
<PHP_SETTING name="memory_limit" value="96M" level="required">
<FEEDBACK>
<ON_ERROR message="settingmemorylimit" />
</FEEDBACK>
</PHP_SETTING>
<PHP_SETTING name="file_uploads" value="1" level="optional">
<FEEDBACK>
<ON_CHECK message="settingfileuploads" />
</FEEDBACK>
</PHP_SETTING>
<PHP_SETTING name="opcache.enable" value="1" level="optional">
<FEEDBACK>
<ON_CHECK message="opcacherecommended" />
</FEEDBACK>
</PHP_SETTING>
</PHP_SETTINGS>
<CUSTOM_CHECKS>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_database_storage_engine" level="required">
<FEEDBACK>
<ON_ERROR message="unsupporteddbstorageengine" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="question/engine/upgrade/upgradelib.php" function="quiz_attempts_upgraded" level="required">
<FEEDBACK>
<ON_ERROR message="quizattemptsupgradedmessage" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_slasharguments" level="optional">
<FEEDBACK>
<ON_CHECK message="slashargumentswarning" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_database_tables_row_format" level="optional">
<FEEDBACK>
<ON_CHECK message="unsupporteddbtablerowformat" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_unoconv_version" level="optional">
<FEEDBACK>
<ON_CHECK message="unoconvwarning" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_libcurl_version" level="optional">
<FEEDBACK>
<ON_CHECK message="libcurlwarning" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_mysql_file_format" level="required">
<FEEDBACK>
<ON_ERROR message="unsupporteddbfileformat" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_mysql_file_per_table" level="required">
<FEEDBACK>
<ON_ERROR message="unsupporteddbfilepertable" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_mysql_large_prefix" level="required">
<FEEDBACK>
<ON_ERROR message="unsupporteddblargeprefix" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_is_https" level="optional">
<FEEDBACK>
<ON_CHECK message="ishttpswarning" />
</FEEDBACK>
</CUSTOM_CHECK>
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_mysql_incomplete_unicode_support" level="optional">
<FEEDBACK>
<ON_CHECK message="incompleteunicodesupport" />
</FEEDBACK>
</CUSTOM_CHECK>
</CUSTOM_CHECKS>
</MOODLE>
</COMPATIBILITY_MATRIX>
+8 -1
View File
@@ -852,10 +852,17 @@ $cachewarnings = cache_helper::warnings();
// Check if there are events 1 API handlers.
$eventshandlers = $DB->get_records_sql('SELECT DISTINCT component FROM {events_handlers}');
// Check if a directory with development libraries exists.
if (is_dir($CFG->dirroot.'/vendor') || is_dir($CFG->dirroot.'/node_modules')) {
$devlibdir = true;
} else {
$devlibdir = false;
}
admin_externalpage_setup('adminnotifications');
$output = $PAGE->get_renderer('core', 'admin');
echo $output->admin_notifications_page($maturity, $insecuredataroot, $errorsdisplayed, $cronoverdue, $dbproblems,
$maintenancemode, $availableupdates, $availableupdatesfetch, $buggyiconvnomb,
$registered, $cachewarnings, $eventshandlers);
$registered, $cachewarnings, $eventshandlers, null, $devlibdir);
+23 -1
View File
@@ -276,12 +276,15 @@ class core_admin_renderer extends plugin_renderer_base {
* @param int|null $availableupdatesfetch timestamp of the most recent updates fetch or null (unknown)
* @param string[] $cachewarnings An array containing warnings from the Cache API.
* @param array $eventshandlers Events 1 API handlers.
* @param bool $ignored Forward-compatible placeholder for the themedesignermode.
* @param bool $devlibdir Warn about development libs directory presence.
*
* @return string HTML to output.
*/
public function admin_notifications_page($maturity, $insecuredataroot, $errorsdisplayed,
$cronoverdue, $dbproblems, $maintenancemode, $availableupdates, $availableupdatesfetch,
$buggyiconvnomb, $registered, array $cachewarnings = array(), $eventshandlers = 0) {
$buggyiconvnomb, $registered, array $cachewarnings = array(), $eventshandlers = 0,
$ignored = false, $devlibdir = false) {
global $CFG;
$output = '';
@@ -290,6 +293,7 @@ class core_admin_renderer extends plugin_renderer_base {
$output .= $this->legacy_log_store_writing_error();
$output .= empty($CFG->disableupdatenotifications) ? $this->available_updates($availableupdates, $availableupdatesfetch) : '';
$output .= $this->insecure_dataroot_warning($insecuredataroot);
$output .= $this->development_libs_directories_warning($devlibdir);
$output .= $this->display_errors_warning($errorsdisplayed);
$output .= $this->buggy_iconv_warning($buggyiconvnomb);
$output .= $this->cron_overdue_warning($cronoverdue);
@@ -519,6 +523,24 @@ class core_admin_renderer extends plugin_renderer_base {
}
}
/**
* Render a warning that a directory with development libs is present.
*
* @param bool $devlibdir True if the warning should be displayed.
* @return string
*/
protected function development_libs_directories_warning($devlibdir) {
if ($devlibdir) {
$moreinfo = new moodle_url('/report/security/index.php');
$warning = get_string('devlibdirpresent', 'core_admin', ['moreinfourl' => $moreinfo->out()]);
return $this->warning($warning, 'error');
} else {
return '';
}
}
/**
* Render an appropriate message if dataroot is insecure.
* @param bool $errorsdisplayed
+12 -12
View File
@@ -3187,6 +3187,18 @@ class CAS_Client
false/*$no_response*/, true/*$bad_response*/, $text_response
);
$result = false;
} else if ( $tree_response->getElementsByTagName("authenticationFailure")->length != 0) {
// authentication failed, extract the error code and message and throw exception
$auth_fail_list = $tree_response
->getElementsByTagName("authenticationFailure");
throw new CAS_AuthenticationException(
$this, 'Ticket not validated', $validate_url,
false/*$no_response*/, false/*$bad_response*/,
$text_response,
$auth_fail_list->item(0)->getAttribute('code')/*$err_code*/,
trim($auth_fail_list->item(0)->nodeValue)/*$err_msg*/
);
$result = false;
} else if ($tree_response->getElementsByTagName("authenticationSuccess")->length != 0) {
// authentication succeded, extract the user name
$success_elements = $tree_response
@@ -3227,18 +3239,6 @@ class CAS_Client
$result = true;
}
}
} else if ( $tree_response->getElementsByTagName("authenticationFailure")->length != 0) {
// authentication succeded, extract the error code and message
$auth_fail_list = $tree_response
->getElementsByTagName("authenticationFailure");
throw new CAS_AuthenticationException(
$this, 'Ticket not validated', $validate_url,
false/*$no_response*/, false/*$bad_response*/,
$text_response,
$auth_fail_list->item(0)->getAttribute('code')/*$err_code*/,
trim($auth_fail_list->item(0)->nodeValue)/*$err_msg*/
);
$result = false;
} else {
throw new CAS_AuthenticationException(
$this, 'Ticket not validated', $validate_url,
+1
View File
@@ -2,3 +2,4 @@ Description of phpCAS 1.3.4 library import
* downloaded from http://downloads.jasig.org/cas-clients/php/current/
* MDL-59456 phpCAS library has been patched because of an authentication bypass security vulnerability.
+4 -3
View File
@@ -58,9 +58,11 @@ if (!$course) {
$PAGE->set_context(context_system::instance()); //TODO: wrong
}
$title = get_string('deleteevent', 'calendar');
// Check the user has the required capabilities to edit an event
if (!calendar_edit_event_allowed($event)) {
print_error('nopermissions');
if (!calendar_edit_event_allowed($event) || !empty($event->modulename)) {
print_error('nopermissions', 'error', $PAGE->url, $title);
}
// Count the repeats, do we need to consider the possibility of deleting repeats
@@ -88,7 +90,6 @@ if ($confirm) {
}
// Prepare the page to show the confirmation form
$title = get_string('deleteevent', 'calendar');
$strcalendar = get_string('calendar', 'calendar');
$PAGE->navbar->add($strcalendar, $viewcalendarurl);
+3 -2
View File
@@ -81,8 +81,9 @@ class core_calendar_external extends external_api {
$eventobj = calendar_event::load($event['eventid']);
// Let's check if the user is allowed to delete an event.
if (!calendar_edit_event_allowed($eventobj)) {
throw new moodle_exception("nopermissions");
if (!empty($eventobj->modulename) || !calendar_edit_event_allowed($eventobj)) {
throw new moodle_exception("nopermissions", 'error', '',
get_string('deleteevent', 'calendar'));
}
// Time to do the magic.
$eventobj->delete($event['repeat']);
+23
View File
@@ -506,4 +506,27 @@ class core_calendar_externallib_testcase extends externallib_advanced_testcase {
$this->assertEquals(1, count($eventsret['events']));
$this->assertEquals(2, count($eventsret['warnings']));
}
/**
* Test for deleting module events.
*/
public function test_delete_calendar_events_for_modules() {
$this->resetAfterTest();
$this->setAdminUser();
$course = $this->getDataGenerator()->create_course();
$nexttime = time() + DAYSECS;
$this->getDataGenerator()->create_module('assign', ['course' => $course->id, 'duedate' => $nexttime]);
$events = calendar_get_events(time(), $nexttime, true, true, true);
$this->assertCount(1, $events);
$params = [];
foreach($events as $event) {
$params[] = [
'eventid' => $event->id,
'repeat' => false
];
}
$this->setExpectedException('moodle_exception');
core_calendar_external::delete_calendar_events($params);
}
}
+34
View File
@@ -0,0 +1,34 @@
<?php
// This file is part of Moodle - http://moodle.org/
//
// Moodle is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// Moodle is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
/**
* Automatically generated strings for Moodle installer
*
* Do not edit this file manually! It contains just a subset of strings
* needed during the very first steps of installation. This file was
* generated automatically by export-installer.php (which is part of AMOS
* {@link http://docs.moodle.org/dev/Languages/AMOS}) using the
* list of strings defined in /install/stringnames.txt.
*
* @package installer
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
$string['thisdirection'] = 'ltr';
$string['thislanguage'] = 'Bislama';
+3 -5
View File
@@ -35,12 +35,10 @@ $string['cliansweryes'] = 'j';
$string['cliincorrectvalueerror'] = 'Fejl, "{$a->value}" er en forkert værdi for "{$a->option}"';
$string['cliincorrectvalueretry'] = 'Forkert værdi, prøv igen!';
$string['clitypevalue'] = 'tast værdi';
$string['clitypevaluedefault'] = 'tast værdi eller brug standardværdien ({$a}) ved at trykke Enter';
$string['cliunknowoption'] = 'Ukendte options:
$string['clitypevaluedefault'] = 'tast værdi, tryk på Enter for at bruge standardværdien ({$a})';
$string['cliunknowoption'] = 'Ukendte optioner:
{$a}
Brug venligst --help option.';
Brug optionen --help.';
$string['cliyesnoprompt'] = 'j (betyder ja) og n (betyder nej)';
$string['environmentrequireinstall'] = 'skal være installeret og aktiveret';
$string['environmentrequireversion'] = 'minimumskravet er version {$a->needed} og du kører {$a->current}';
+10 -18
View File
@@ -35,7 +35,7 @@ $string['availablelangs'] = 'Tilgængelige sprogpakker';
$string['chooselanguagehead'] = 'Vælg et sprog';
$string['chooselanguagesub'] = 'Vælg et sprog til brug under installationen. Dette sprog vil også blive brugt som standardsprog på webstedet, men det kan altid ændres til et andet sprog.';
$string['clialreadyconfigured'] = 'Konfigurationsfilen config.php eksisterer allerede. Benyt venigst admin/cli/install_database.php til at installere Moodle for dette site.';
$string['clialreadyinstalled'] = 'Filen config.php eksisterer allerede, brug venligst admin/cli/install_database.php hvis du ønsker at opgradere dette websted.';
$string['clialreadyinstalled'] = 'Filen config.php eksisterer allerede, brug admin/cli/install_database.php hvis du ønsker at opgradere dette websted.';
$string['cliinstallheader'] = 'Moodle {$a} kommandolinje-installationsprogram';
$string['databasehost'] = 'Databasevært';
$string['databasename'] = 'Databasenavn';
@@ -52,20 +52,15 @@ $string['installation'] = 'Installation';
$string['langdownloaderror'] = 'Sproget "{$a}" blev desværre ikke installeret. Installationen vil fortsætte på engelsk.';
$string['memorylimithelp'] = '<p>Den mængde hukommelse PHP kan bruge, er sat til {$a}.</p>
<p>Dette kan forårsage at der opstår problemer senere, især hvis du har mange moduler aktiveret eller mange brugere.</p>
<p>Det kan forårsage at der opstår problemer senere, især hvis du har mange moduler aktiveret eller mange brugere.</p>
<p>Vi anbefaler at du konfigurerer PHP med mere hukommelse, f.eks. 40M.
Der er flere måder hvorpå du kan rette det.</p>
<p>Vi anbefaler at du konfigurerer PHP med mere hukommelse, f.eks. 40M. Der er flere måder hvorpå du kan ændre det.</p>
<ol>
<li>Hvis du har mulighed for det, kan du rekompilere PHP med <i>--enable-memory-limit</i>.
Det vil tillade at Moodle selv kan definere hvor meget hukommelse der er brug for.</li>
<li>Hvis du har mulighed for det, kan du rekompilere PHP med <i>--enable-memory-limit</i>. Det vil tillade at Moodle selv kan definere hvor meget hukommelse der er brug for.</li>
<li>Hvis du har adgang til php.ini filen kan du ændre <b>memory_limit</b>-indstillingen til noget i retning af 40M. Hvis du ikke har direkte adgang til den kan du bede systemadministratoren om at gøre det for dig.</li>
<li>På nogle servere kan du oprette en \'.htaccess\'-fil og gemme den i moodle-mappen med linjen: <blockquote><div>php_value memory_limit 40M</div></blockquote>
<li>Hvis du har adgang til php.ini filen kan du ændre <b>memory_limit</b>-indstillingen til noget i retning af 40M.
Hvis du ikke har direkte adgang til den kan du bede systemadministratoren om at gøre det for dig.</li>
<li>På nogle servere kan du oprette en \'.htaccess\' fil og gemme den i moodle-mappen med linjen:
<blockquote><div>php_value memory_limit 40M</div></blockquote>
<p>Det kan dog på nogle servere forhindre <b>alle</b> PHP-siderne i at virke (du vil se fejl når du ser på siderne). I så fald kan du blive nødt til at fjerne \'.htaccess\' filen igen.</p></li> </ol>';
<p>Det kan dog på nogle servere forhindre <b>alle</b> PHP-siderne i at virke (du vil se fejl når du ser på siderne). I så fald kan du blive nødt til at fjerne \'.htaccess\'filen igen.</p></li> </ol>';
$string['paths'] = 'Stier';
$string['pathserrcreatedataroot'] = 'Datamappen ({$a->dataroot}) kan ikke oprettes af installationsprogrammet.';
$string['pathshead'] = 'Bekræft stier';
@@ -76,7 +71,7 @@ $string['pathssubdataroot'] = '<p>En mappe hvori Moodle kan gemme uploadede file
<p>Webserver-brugeren (som regel \'www-data\', \'nobody\', eller \'apache\') skal have læse- og skriveadgang til den.</p>
<p>Mappen må ikke være tilgængelig direkte fra internettet.</p>
<p>Hvis ikke den allerede eksisterer, vil Installationsprogrammet forsøge at oprette den</p>';
$string['pathssubdirroot'] = '<p>Den fulde sti mappen med til Moodlekoden.</p>';
$string['pathssubdirroot'] = '<p>Den fulde sti til mappen med Moodlekoden.</p>';
$string['pathssubwwwroot'] = '<p>Moodles fulde web-adresse, dvs. adressen som den skal stå i browserens adressefelt for at komme ind på Moodle.</p>
<p>Moodle kan ikke bruges fra flere adresser. Hvis dit websted kan tilgås fra flere adresser, skal du vælge den enkleste og opsætte permanent viderestilling for hver af de øvrige.</p>
<p>Hvis dit websted er tilgængeligt fra både internettet og et internt net (nogen gange kaldet intranet), skal du bruge den offentlige adresse her</p>
@@ -84,11 +79,8 @@ $string['pathssubwwwroot'] = '<p>Moodles fulde web-adresse, dvs. adressen som de
$string['pathsunsecuredataroot'] = 'Datamappen er ikke sikret';
$string['pathswrongadmindir'] = 'Adminmappe eksisterer ikke';
$string['phpextension'] = '{$a} PHP-extension';
$string['phpversion'] = 'PHP version';
$string['phpversionhelp'] = '<p>Moodle kræver mindst PHP version 4.3.0. eller 5.1.0 (5.0.x er behæftet med fejl).</p>
<p>Webserveren bruger i øjeblikket version {$a}</p>
<p>Du bliver nødt til at opdatere PHP eller flytte systemet over på en anden webserver der har en nyere version af PHP!</p>
(Har du ver. 5.0.x kan du også nedgradere til 4.4.x)</p>';
$string['phpversion'] = 'PHP-version';
$string['phpversionhelp'] = '<p>Moodle kræver mindst PHP version 5.4.4 (7.0.x har visse begrænsninger).</p> <p>Du bruger i øjeblikket version {$a}</p> <p>Du bliver nødt til at opgradere PHP eller flytte systemet over på en webserver med en nyere version af PHP!</p>';
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
$string['welcomep20'] = 'Du ser denne side fordi du har installeret og åbnet pakken <strong>{$a->packname} {$a->packversion}</strong> på din computer.
Tillykke med det!';
+1
View File
@@ -30,5 +30,6 @@
defined('MOODLE_INTERNAL') || die();
$string['parentlanguage'] = '';
$string['thisdirection'] = 'ltr';
$string['thislanguage'] = 'Dansk';
+5 -5
View File
@@ -31,13 +31,13 @@
defined('MOODLE_INTERNAL') || die();
$string['cannotcreatedboninstall'] = '<p>Die Datenbank konnte nicht angelegt werden.</p><p>Die angegebene Datenbank existiert nicht und das genannten Nutzerkonto hat keine Rechte, die Datenbank neu anzulegen. Die Datenbank-Konfiguration muss überprüft werden.</p>';
$string['cannotcreatelangdir'] = 'Verzeichnis \'lang\' wurde nicht angelegt';
$string['cannotcreatetempdir'] = 'Das Verzeichnis \'temp\' wurde nicht angelegt';
$string['cannotcreatelangdir'] = 'Das Verzeichnis \'lang\' wurde nicht angelegt.';
$string['cannotcreatetempdir'] = 'Das Verzeichnis \'temp\' wurde nicht angelegt.';
$string['cannotdownloadcomponents'] = 'Einige Komponenten können nicht geladen werden.';
$string['cannotdownloadzipfile'] = 'ZIP-Datei kann nicht heruntergeladen werden.';
$string['cannotfindcomponent'] = 'Komponente wurde nicht gefunden';
$string['cannotsavemd5file'] = 'Die md5-Datei wurde nicht gespeichert';
$string['cannotsavezipfile'] = 'Die ZIP-Datei wurde nicht gespeichert';
$string['cannotfindcomponent'] = 'Die Komponente kann nicht gefunden werden.';
$string['cannotsavemd5file'] = 'Die md5-Datei wurde nicht gespeichert.';
$string['cannotsavezipfile'] = 'Die ZIP-Datei wurde nicht gespeichert.';
$string['cannotunzipfile'] = 'Die Datei kann nicht entpackt werden';
$string['componentisuptodate'] = 'Die Komponente ist aktuell.';
$string['dmlexceptiononinstall'] = '<p>Ein Datenbankfehler ist aufgetreten [{$a->errorcode}]. <br />{$a->debuginfo}</p>';
+3 -4
View File
@@ -73,10 +73,9 @@ $string['pathsunsecuredataroot'] = 'Der Speicherort des Verzeichnisses \'dataroo
$string['pathswrongadmindir'] = 'Das Admin-Verzeichnis existiert nicht';
$string['phpextension'] = 'PHP-Extension {$a}';
$string['phpversion'] = 'PHP-Version';
$string['phpversionhelp'] = '<p>Moodle erwartet als PHP-Version mindestens 4.3.0/4.4.0 oder 5.1.0 (5.0.x weist eine Reihe bekannter Fehler auf).</p>
<p>Sie nutzen momentan die Version {$a}.</p>
<p>Sie müssen Ihre PHP-Version aktualisieren oder auf einen Rechner wechseln, der eine neuere Version von PHP nutzt.<br />
(Im Falle von 5.0.x könnten Sie auch zu einer Version 4.3.x/4.4.x downgraden)</p>';
$string['phpversionhelp'] = '<p>Moodle benötigt mindestens die PHP-Version 5.4.4 (7.0.x weist einige Einschränkungen auf).</p>
<p>Sie nutzen im Moment die Version {$a}.</p>
<p>Sie müssen Ihre PHP-Version aktualisieren oder auf einen Server mit einer neueren PHP-Version wechseln.<br />';
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
$string['welcomep20'] = 'Sie haben das Paket <strong>{$a->packname} {$a->packversion}</strong> erfolgreich auf Ihrem Computer installiert.';
$string['welcomep30'] = 'Diese Version von <strong>{$a->installername}</strong> enthält folgende Anwendungen, mit denen Sie <strong>Moodle</strong> ausführen können:';
+34
View File
@@ -0,0 +1,34 @@
<?php
// This file is part of Moodle - http://moodle.org/
//
// Moodle is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// Moodle is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
/**
* Automatically generated strings for Moodle installer
*
* Do not edit this file manually! It contains just a subset of strings
* needed during the very first steps of installation. This file was
* generated automatically by export-installer.php (which is part of AMOS
* {@link http://docs.moodle.org/dev/Languages/AMOS}) using the
* list of strings defined in /install/stringnames.txt.
*
* @package installer
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
$string['parentlanguage'] = 'de';
$string['thislanguage'] = 'Dolnoserbski';
+1
View File
@@ -31,6 +31,7 @@
defined('MOODLE_INTERNAL') || die();
$string['language'] = 'Γλώσσα';
$string['moodlelogo'] = 'Λογότυπο Moodle';
$string['next'] = 'Επόμενο';
$string['previous'] = 'Προηγούμενο';
$string['reload'] = 'Eπαναφόρτωση';
+2 -2
View File
@@ -33,13 +33,13 @@ defined('MOODLE_INTERNAL') || die();
$string['clianswerno'] = 'n';
$string['cliansweryes'] = 's';
$string['cliincorrectvalueerror'] = 'Error, valor incorrecto "{$a->value}" para "{$a->option}"';
$string['cliincorrectvalueretry'] = 'Valor incorrecto, por favor, inténtelo de nuevo';
$string['cliincorrectvalueretry'] = 'Valor incorrecto, por favor, intente de nuevo';
$string['clitypevalue'] = 'valor del tipo';
$string['clitypevaluedefault'] = 'valor del tipo, pulse Enter para utilizar el valor por defecto ({$a})';
$string['cliunknowoption'] = 'Opciones no reconocidas:
{$a}
Por favor, utilice la opción Ayuda.';
$string['cliyesnoprompt'] = 'escriba s (sí) o n (no)';
$string['cliyesnoprompt'] = 'escriba s (para sí) o n (para no)';
$string['environmentrequireinstall'] = 'debe estar instalado/activado';
$string['environmentrequireversion'] = 'versión {$a->needed} es obligatoria y está ejecutando {$a->current}';
$string['upgradekeyset'] = 'Clave de actualización (dejar en blanco para no establecerla)';
+2 -3
View File
@@ -85,10 +85,9 @@ $string['pathsunsecuredataroot'] = 'La ubicación de dataroot no es segura';
$string['pathswrongadmindir'] = 'El directorio admin no existe';
$string['phpextension'] = 'Extensión PHP {$a}';
$string['phpversion'] = 'Versión PHP';
$string['phpversionhelp'] = '<p>Moodle requiere al menos una versión de PHP 4.3.0 o 5.1.0 ((5.0.x tiene una serie de problemas conocidos).</p>
$string['phpversionhelp'] = '<p>Moodle requiere al menos una versión de PHP al menos de 5.4.4 (7.0.x tienealgunas limitaciones del motor.</p>
<p>En este momento está ejecutando la versión {$a}</p>
<p>¡Debe actualizar PHP o trasladarse a otro servidor con una versión más reciente de PHP!<br />
(En caso de 5.0.x podría también revertir a la versión 4.4.x)</p>';
<p>¡Debe actualizar PHP o trasladarse a otro servidor con una versión más reciente de PHP!</p>';
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
$string['welcomep20'] = 'Si está viendo esta página es porque ha podido instalar y ejecutar exitosamente el paquete <strong>{$a->packname} {$a->packversion}</strong> en su computadora. !Enhorabuena!';
$string['welcomep30'] = 'Esta versión de <strong>{$a->installername}</strong> incluye las aplicaciones necesarias para que <strong>Moodle</strong> funcione en su computadora, principalmente:';
+1 -1
View File
@@ -31,4 +31,4 @@
defined('MOODLE_INTERNAL') || die();
$string['parentlanguage'] = 'es_mx';
$string['thislanguage'] = 'Español de México para niños';
$string['thislanguage'] = 'Español - México para niños';
+2 -2
View File
@@ -67,10 +67,10 @@ Horrek Moodle-k berak memoria-muga ezartzea ahalbidetzen du.</li>
(orriak ikustean erroreak ere ikusiko dituzu). Kasu horretan, .htaccess fitxategia ezabatu beharko duzu.</p></li>
</ol>';
$string['paths'] = 'Bideak';
$string['pathserrcreatedataroot'] = 'Instalatzaileak ezin du datuen karpeta ({$a->dataroot}) sortu.';
$string['pathserrcreatedataroot'] = 'Instalatzaileak ezin du datu-karpeta ({$a->dataroot}) sortu.';
$string['pathshead'] = 'Egiaztatu bideak';
$string['pathsrodataroot'] = 'Dataroot direktorioa ez da idazteko modukoa.';
$string['pathsroparentdataroot'] = 'Goragoko direktorioan ({$a->parent}) ezin da idatzi. Instalatzaileak ezin du datuen karpeta ({$a->dataroot}) sortu.';
$string['pathsroparentdataroot'] = 'Goragoko karpeta ({$a->parent}) ez da idazteko modukoa. Instalatzaileak ezin du datu-karpeta ({$a->dataroot}) sortu.';
$string['pathssubadmindir'] = 'Web ostalari gutxi batzuk /admin URL berezi gisa erabiltzen dute kontrol-panel edo antzekora sarbidea emateko. Zoritxarrez, honek Moodle-ren kudeatze-orrien berezko kokapenarekin gatazka sortzen du. Hau konpondu dezakezu zure instalazioko admin karpeta berrizendatuz, eta izen berria hemen sartuta. Adibidez <em>moodleadmin</em>. Honek Moodle-ko admin estekak konponduko du.';
$string['pathssubdataroot'] = '<p>Moodle-k erabiltzaileek igotako fitxategien edukiak bilduko dituen direktorio bat.</p>
<p>Direktorio honetan web-zerbitzariaren erabiltzaileak irakurtzeko eta idazteko baimena izan beharko ditu (normalean \'www-data\', \'nobody\', edo \'apache\').</p>
+7
View File
@@ -43,4 +43,11 @@ $string['cannotsavezipfile'] = 'نمی‌توانم فایل ZIP را ذخیره
$string['cannotunzipfile'] = 'فایل نمی‌تواند unzip شود';
$string['componentisuptodate'] = 'کامپوننت به‌روز است';
$string['dmlexceptiononinstall'] = '<p>یک خطای پایگاه داده رخ داد [{$a->errorcode}].<br />{$a->debuginfo}</p>';
$string['downloadedfilecheckfailed'] = 'بررسی فایل دریافت‌شده ناموفق بود';
$string['invalidmd5'] = 'متغیر بررسی نادرست بود - دوباره تلاش کنید';
$string['missingrequiredfield'] = 'بعضی از فیلدهای ضروری خالی است';
$string['remotedownloaderror'] = '<p>دانلود کامپوننت بر روی کارگزار شما ناموفق بود. لطفا تنظیمات پروکسی را بررسی کنید؛ افزونهٔ پی‌اچ‌پی cURL بسیار توصیه می‌شود.</p>
<p>باید به‌صورت دستی فایل <a href="{$a->url}">{$a->url}</a> را دریافت کنید، آن را در «{$a->dest}» در کارگزار خود کپی کنید و آنجا از حالت فشرده خارج کنید.</p>';
$string['wrongdestpath'] = 'مسیر مقصد اشتباه';
$string['wrongsourcebase'] = 'آدرس اینترنتی پایهٔ اشتباه';
$string['wrongzipfilename'] = 'نام فایل ZIP اشتباه';
+2 -2
View File
@@ -66,7 +66,7 @@ $string['pathsrodataroot'] = 'Le dossier de données n\'est pas accessible en é
$string['pathsroparentdataroot'] = 'Le dossier parent ({$a->parent}) n\'est pas accessible en écriture. Le dossier de données ({$a->dataroot}) ne peut pas être créé par l\'installeur.';
$string['pathssubadmindir'] = 'Quelques rares hébergeurs utilisent « /admin » comme URL spéciale pour l\'accès à un tableau de bord ou d\'autres fonctionnalités. Malheureusement ceci entre en conflit avec l\'emplacement standard des pages d\'administration de Moodle. Vous pouvez corriger ceci en renommant le dossier admin de votre installation Moodle et en plaçant le nouveau nom choisi dans ce champ. Par exemple, <em>moodleadmin</em>. Ceci modifiera tous les liens de l\'administration de Moodle.';
$string['pathssubdataroot'] = '<p>Un dossier dans lequel Moodle stockera tous les fichiers qui seront déposés par les utilisateurs.</p>
<p>Ce dossier doit être accessible en lecture et en écriture par le serveur web (dénomé « nobody » ou « apache » ou encore « www-data »).</p>
<p>Ce dossier doit être accessible en lecture et en écriture par l\'utilisateur système du serveur web (habituellement nommé « www-data », « nobody » ou encore « apache »).</p>
<p>Il ne doit pas être accessible directement via le web.</p>
<p>Si ce dossier n\'existe pas encore, Moodle tentera de le créer au cours du processus d\'installation.</p>';
$string['pathssubdirroot'] = '<p>Le chemin d\'accès complet au dossier contenant le code source de Moodle.</p>';
@@ -78,7 +78,7 @@ $string['pathsunsecuredataroot'] = 'L\'emplacement du dossier de données n\'est
$string['pathswrongadmindir'] = 'Le dossier d\'administration n\'existe pas';
$string['phpextension'] = 'Extension PHP {$a}';
$string['phpversion'] = 'Version de PHP';
$string['phpversionhelp'] = '<p>Moodle nécessite au minimum la version 4.3.0 ou 5.1.0 (5.0.x a bon nombre de problèmes).</p><p>Vous utilisez actuellement la version {$a}.</p><p>Pour que Moodle fonctionne, vous devez mettre à jour PHP ou aller chez un hébergeur ayant une version récente de PHP.<br />(Si vous avez une version 5.0.x, vous pouvez aussi re-passer à la version 4.4.x)</p>';
$string['phpversionhelp'] = '<p>Moodle nécessite au minimum la version 5.4.4 de PHP (la version 7.0.x a quelques limitations avec certains moteurs).</p><p>Vous utilisez actuellement la version {$a}.</p><p>Vous devez mettre à jour PHP ou aller chez un hébergeur ayant une version plus récente de PHP.';
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
$string['welcomep20'] = 'Vous voyez cette page, car vous avez installé Moodle correctement et lancé le logiciel <b>{$a->packname} {$a->packversion}</b> sur votre ordinateur. Félicitations !';
$string['welcomep30'] = 'Cette version de <b>{$a->installername}</b> comprend des logiciels qui créent un environnement dans lequel <b>Moodle</b> va fonctionner, à savoir :';
+1 -1
View File
@@ -84,7 +84,7 @@ $string['pathssubdataroot'] = '<p>Necesitase un lugar no que Moodle poida gardar
<p>Se non existe o instalador tentará crealo.</p>';
$string['pathssubdirroot'] = '<p>Ruta completa do directorio de instalación de Moodle.</p>';
$string['pathssubwwwroot'] = 'Enderezo web completo para acceder a Moodle.
Non é posíbel acceder a Moodle empregando enderezos múltiplos.
Non é posíbel acceder a Moodle empregando enderezos múltiples.
Se o seu sitio ten varios enderezos públicos debe configurar encamiñamentos permanentes en todos eles, agás neste.
Se o seu sitio web é accesíbel tanto desde unha Intranet como desde Internet, escriba aquí o enderezo público e configure o DNS para que os usuarios da Intranet poidan empregar tamén o enderezo público.
Se o enderezo non é correcto, cambie o URL no seu navegador para reiniciar a instalación cun valor diferente.';
+1 -1
View File
@@ -42,4 +42,4 @@ $string['cliunknowoption'] = 'אפשרויות לא מוכרות :
אנא השתמש באפשרות העזרה.';
$string['cliyesnoprompt'] = 'רשום y (שפרושו כן) או n (שפרושו לא)';
$string['environmentrequireinstall'] = 'נדרש להתקין ולאפשר הרחבה זו';
$string['environmentrequireversion'] = ירסה {$a->needed} נדרשת אך הגירסה הנוכחית היא {$a->current}';
$string['environmentrequireversion'] = 'גרסה {$a->needed} נדרשת אך הגרסה הנוכחית היא {$a->current}';
+2 -2
View File
@@ -33,7 +33,7 @@ defined('MOODLE_INTERNAL') || die();
$string['admindirname'] = 'Adminディレクトリ';
$string['availablelangs'] = '利用可能な言語パック';
$string['chooselanguagehead'] = '言語を選択してください。';
$string['chooselanguagesub'] = 'インストールのみ使用する言語を選択してください。この言語はサイトのデフォルト言語としても使用されます。後でサイト言語を変更することができます。';
$string['chooselanguagesub'] = 'インストールのみ使用する言語を選択してください。この言語はサイトのデフォルト言語としても使用されます。後でサイト言語を変更することができます。';
$string['clialreadyconfigured'] = '設定ファイルconfig.phpはすでに登録されています。このサイトをインストールする場合、admin/cli/install_database.phpを使用してください。';
$string['clialreadyinstalled'] = '設定ファイルconfig.phpは、すでに登録されています。このサイトをアップグレードする場合、admin/cli/upgrade.phpを使用してください。';
$string['cliinstallheader'] = 'Moodle {$a} コマンドラインインストールプログラム';
@@ -91,7 +91,7 @@ $string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
$string['welcomep20'] = 'インストールが正常に完了して、あなたのコンピュータで <strong>{$a->packname} {$a->packversion}</strong> パッケージが起動されたため、このページが表示されています。おめでとうございます!';
$string['welcomep30'] = 'このリリース <strong>{$a->installername}</strong> には<strong>Moodle</strong>で環境を作成するアプリケーションが含まれています。すなわち:';
$string['welcomep40'] = 'パッケージには <strong>Moodle {$a->moodlerelease} ({$a->moodleversion})</strong> も含まれています。';
$string['welcomep50'] = 'このパッケージ内のすべてのアプリケーションの使用は個のライセンスによって規定されています。全体の<strong>{$a->installername}</strong>パッケージは<a href="http://www.opensource.org/docs/definition_plain.html">オープンソース</a>であり、<a href="http://www.gnu.org/copyleft/gpl.html">GPL</a>ライセンスの下で配布されています。';
$string['welcomep50'] = 'このパッケージ内のすべてのアプリケーションの使用は個のライセンスによって規定されています。全体の<strong>{$a->installername}</strong>パッケージは<a href="http://www.opensource.org/docs/definition_plain.html">オープンソース</a>であり、<a href="http://www.gnu.org/copyleft/gpl.html">GPL</a>ライセンスの下で配布されています。';
$string['welcomep60'] = '次からのページはあなたのコンピュータに<strong>Moodle</strong>を簡単に設定およびセットアップする手順にしたがって進みます。あなたはデフォルトの設定を使用することも、必要に応じて任意で設定を変更することもできます。';
$string['welcomep70'] = '<strong>Moodle</strong>のセットアップを続けるには「次へ」ボタンをクリックしてください。';
$string['wwwroot'] = 'ウェブアドレス';
+33
View File
@@ -0,0 +1,33 @@
<?php
// This file is part of Moodle - http://moodle.org/
//
// Moodle is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// Moodle is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
/**
* Automatically generated strings for Moodle installer
*
* Do not edit this file manually! It contains just a subset of strings
* needed during the very first steps of installation. This file was
* generated automatically by export-installer.php (which is part of AMOS
* {@link http://docs.moodle.org/dev/Languages/AMOS}) using the
* list of strings defined in /install/stringnames.txt.
*
* @package installer
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
$string['availablelangs'] = 'ಲಭ್ಯವಿರುವ ಭಾಷಾ ಪೊಟ್ಟಣಗಳು';
+1 -1
View File
@@ -38,7 +38,7 @@ $string['clialreadyconfigured'] = 'Het configuratiebestand config.php bestaat al
$string['clialreadyinstalled'] = 'Het configuratiebestand config.php bestaat al. Maak aub gebruik van admin/cli/install_database.php als je Moodle voor deze site wenst te upgraden.';
$string['cliinstallheader'] = 'Moodle {$a} command line installatieprogramma';
$string['databasehost'] = 'Databank host:';
$string['databasename'] = 'Datanbanknaam:';
$string['databasename'] = 'Databanknaam:';
$string['databasetypehead'] = 'Kies databankdriver';
$string['dataroot'] = 'Gegevensmap';
$string['datarootpermission'] = 'Toestemming datamappen';
+3 -3
View File
@@ -66,9 +66,9 @@ $string['pathshead'] = 'Bekreft stier';
$string['pathsrodataroot'] = 'Dataroot katalog er ikke skrivbar.';
$string['pathsroparentdataroot'] = 'Overordnet katalog ({$a->parent}) er ikke skrivbar. Datakatalogen ({$a->dataroot}) kan ikke opprettes av installasjonsprogrammet.';
$string['pathssubadmindir'] = 'Noen ganske få webhoteller bruker /admin som en egen url for å få tilgang til et kontrollpanel. Dessverre kommer det i konflikt med standard lokalisering av Moodle sine admin-sider. Du kan fikse dette ved å endre navn på admin-mappen og deretter oppgi dette navnet her. F.eks. <em>moodleadmin</em>. Dette vil fikse adminlenkene i Moodle.';
$string['pathssubdataroot'] = '<p>En mappe der Moodle vil lagre alle filer lastet opp av brukerne.</p>
<p>Denne mappen må være med lese og skriverettigheter for webserver-brukeren (vanligvis \'www-data\', \'nobody\' eller \'apache\').</p>
<p>Denne mappen må IKKE være direkte tilgjengelig via web.</p> <p>Installasjonsprogrammet vil forsøke å opprette den om den ikke finnes fra før.</p>';
$string['pathssubdataroot'] = '<p>Du trenger et sted hvor Moodle kan lagre opplastede filer. </p>
<p>Denne mappen må være med lese og skriverettigheter for webserver-brukeren (veldig ofte \'nobody\' eller \'apache\'), men denne mappen må IKKE være direkte tilgjengelig via web.</p>
<p> Installasjonsprogrammet vil forsøke å opprette den om den ikke finnes fra før.</p>';
$string['pathssubdirroot'] = '<p>Full mappesti til moodleinstallasjonen.</p>';
$string['pathssubwwwroot'] = '<p>Full webadresse til der hvor Moodle skal vises, altså den addressen som brukere skriver inn i adresselinjen i nettlseren sin.</p>
<p>Det er ikke mulig å bruke Moodle med mer enn en adresse. Dersom portalen din har flere webadresser bør du oppgi den enkleste av de her, og bruke videresending for hver av de andre adressene.</p>
+2 -2
View File
@@ -33,7 +33,7 @@ defined('MOODLE_INTERNAL') || die();
$string['admindirname'] = 'Pasta de administração';
$string['availablelangs'] = 'Pacotes linguísticos disponíveis';
$string['chooselanguagehead'] = 'Selecione um idioma';
$string['chooselanguagesub'] = 'Selecione o idioma a utilizar durante a instalação. Poderá depois selecionar um outro idioma para o site e para os utilizadores.';
$string['chooselanguagesub'] = 'Selecione o idioma a utilizar durante a instalação. Poderá depois selecionar outro(s) idioma(s) para o site e para os utilizadores.';
$string['clialreadyconfigured'] = 'O ficheiro config.php já existe, use admin/cli/install_database.php para instalar o Moodle para este site.';
$string['clialreadyinstalled'] = 'O ficheiro config.php já existe, use admin/cli/install_database.php para atualizar o Moodle para este site.';
$string['cliinstallheader'] = 'Programa para instalação do Moodle <b>{$a}</b> através da linha de comandos';
@@ -61,7 +61,7 @@ $string['pathssubdataroot'] = '<p>Uma diretoria em que o Moodle irá armazenar t
<p>Não deve ser diretamente acessível através da web.</p>
<p> Se a diretoria não existir atualmente, o processo de instalação tentará criá-la.</p>';
$string['pathssubdirroot'] = 'Caminho completo para a diretoria que contém o código Moodle.';
$string['pathssubwwwroot'] = 'Endereço web completo de acesso ao Moodle. Não é possível aceder ao Moodle usando mais do que um endereço. Se o site tiver mais do que um endereço público, devem ser configurados redirecionamentos permanentes em todos eles, à exceção deste. Se o site pode ser acedido a partir da Internet e de Intranet, então use o endereço público aqui. Se o endereço atual não está correto, então altere o endereço indicado na barra de endereço do seu navegador e reinicie a instalação.';
$string['pathssubwwwroot'] = 'Endereço web completo de acesso ao Moodle. Não é possível aceder ao Moodle usando mais do que um endereço. Se o site tiver mais do que um endereço público, devem ser configurados redirecionamentos permanentes em todos eles, à exceção deste. Se o site pode ser acedido a partir da Internet e de Intranet, então use o endereço público aqui. Se o endereço atual não está correto, altere o endereço indicado na barra de endereço do seu navegador e reinicie a instalação.';
$string['pathsunsecuredataroot'] = 'A localização da pasta de dados não é segura';
$string['pathswrongadmindir'] = 'A pasta <b>admin</b> não existe';
$string['phpextension'] = 'Extensão <b>{$a}</b> do PHP';
+1 -1
View File
@@ -46,7 +46,7 @@ $string['dmlexceptiononinstall'] = '<p> Ocorreu um erro no banco de dados [{$a->
$string['downloadedfilecheckfailed'] = 'A verificação do arquivo baixado falhou';
$string['invalidmd5'] = 'A variável de verificação estava errada - tente novamente';
$string['missingrequiredfield'] = 'Faltam informações obrigatórias';
$string['remotedownloaderror'] = '<p>O download do componente falhou, por favor verifique as configurações do proxy. A extensão cURL do PHP é altamente recomendada.<p/><p>Você precisar baixar o <a href="{$a->url}">arquivo</a> manualmente, copiar para "{$a->dest}" e descompactar lá.<p/>';
$string['remotedownloaderror'] = '<p>O download do componente falhou, por favor verifique as configurações do proxy. A extensão cURL do PHP é altamente recomendada.</p><p>Você precisar baixar o <a href="{$a->url}">arquivo</a> manualmente, copiar para "{$a->dest}" e descompactar lá.</p>';
$string['wrongdestpath'] = 'Caminho do destino errado';
$string['wrongsourcebase'] = 'URL do recurso errada';
$string['wrongzipfilename'] = 'Nome do arquivo ZIP errado';
+3 -3
View File
@@ -69,10 +69,10 @@ $string['pathshead'] = 'Confirme os caminhos';
$string['pathsrodataroot'] = 'O diretório de dados raiz não pode ser acessado para escrita.';
$string['pathsroparentdataroot'] = 'O diretório pai ({$a->parent}) não pode ser escrito. O diretório de dados ({$a->dataroot}) não pode ser criado pelo instalador.';
$string['pathssubadmindir'] = 'Alguns poucos webhosts usam /admin como um URL especial para acesso ao painel de controle ou outras coisas. Infelizmente isto conflita com a localizaçao padrão das páginas do administrador Moodle. Você pode corrigir isso renomeando a pasta admin na sua instalação, e colocando esse novo nome aqui. Por exemplo: <em>moodleadmin</em>. Isto irá corrigir os links das páginas do administrador Moodle.';
$string['pathssubdataroot'] = '<p>Um diretório em que Moodle pode armazenar todo o conteúdo de arquivos enviados pelos usuários. </p>
<p>Este diretório deve ser legível e gravável tanto pelo usuário do servidor web (geralmente "www-data \',\' nobody \', ou\' apache\'). </p>
$string['pathssubdataroot'] = '<p>Um diretório em que Moodle armazenará todo o conteúdo de arquivos enviados pelos usuários. </p>
<p>Este diretório deve ser legível e gravável pelo usuário do servidor web (geralmente "www-data \',\' nobody \', ou\' apache\'). </p>
<p>Não deve ser diretamente acessível através da web. </p>
<p>Se o diretório não existir atualmente, o processo de instalação irá tentar criá-la. </p>';
<p>Se o diretório não existir atualmente, o processo de instalação tentará criá-lo. </p>';
$string['pathssubdirroot'] = '<p>Caminho completo do diretório para instalação do Moddle.</p>';
$string['pathssubwwwroot'] = '<p>O endereço completo em que Moodle pode ser acessado ou seja, o endereço que os usuários vão digitar na barra de endereços do seu navegador para acessar Moodle. </p>
<p>Não é possível acessar Moodle usando múltiplos endereços. Se o seu site é acessível através de múltiplos endereços, em seguida, escolher o mais fácil e configurar um redirecionamento permanente para cada um dos outros endereços. </p>
+1
View File
@@ -31,6 +31,7 @@
defined('MOODLE_INTERNAL') || die();
$string['language'] = 'Jazyk';
$string['moodlelogo'] = 'Moodle logo';
$string['next'] = 'Ďalší';
$string['previous'] = 'Predchádzajúci';
$string['reload'] = 'Reload';
+4
View File
@@ -30,6 +30,9 @@
defined('MOODLE_INTERNAL') || die();
$string['cannotcreatedboninstall'] = '<p>Podatkovne zbirke ni bilo mogoče ustvariti.</p>
<p>Navedena podatkovna zbirka ne obstaja in navedeni uporabnik nima dovoljenja, da ustvari podatkovno zbirko.</p>
<p>Skrbnik spletnega mesta mora potrditi konfiguracijo podatkovne zbirke.</p>';
$string['cannotcreatelangdir'] = 'Imenika jezika ni možno ustvariti.';
$string['cannotcreatetempdir'] = 'Začasnega imenika ni možno ustvariti.';
$string['cannotdownloadcomponents'] = 'Komponent ni možno prenesti.';
@@ -39,6 +42,7 @@ $string['cannotsavemd5file'] = 'Datoteke MD5 ni možno shraniti.';
$string['cannotsavezipfile'] = 'Datoteke ZIP ni možno shraniti.';
$string['cannotunzipfile'] = 'Datoteke ni možno razširiti (unzip).';
$string['componentisuptodate'] = 'Komponenta je posodobljena.';
$string['dmlexceptiononinstall'] = '<p>Prišlo je do napake podatkovne zbirke [{$a->errorcode}].<br />{$a->debuginfo}</p>';
$string['downloadedfilecheckfailed'] = 'Preverjanje prenesene datoteke je spodletelo.';
$string['invalidmd5'] = 'Neveljaven MD5';
$string['missingrequiredfield'] = 'Eno izmed zahtevanih polj manjka';
+5 -6
View File
@@ -33,7 +33,7 @@ defined('MOODLE_INTERNAL') || die();
$string['admindirname'] = 'Администраторски директоријум';
$string['availablelangs'] = 'Доступни језички пакети';
$string['chooselanguagehead'] = 'Изаберите језик';
$string['chooselanguagesub'] = 'Молимо изаберите језик који ће се користити током инсталације. Овај језик ће, такође, бити коришћен на нивоу сајта као подразумевани, мада то накнадно може бити промењено.';
$string['chooselanguagesub'] = 'Изаберите језик који ће се користити током инсталације. Овај језик ће, такође, бити коришћен на нивоу сајта као подразумевани, иако то накнадно може да се промени.';
$string['clialreadyconfigured'] = 'Датотека config.php већ постоји. Молимо, користите admin/cli/install_database.php ако желите да инсталирате Moodle на овом серверу.';
$string['clialreadyinstalled'] = 'Датотека config.php већ постоји. Молимо користите admin/cli/upgrade.php ако желите да надоградите Moodle на овом серверу.';
$string['cliinstallheader'] = 'Moodle {$a} програм за инсталацију из командне линије';
@@ -73,17 +73,16 @@ $string['pathssubdataroot'] = '<p>Директоријум где ће Moodle ч
<p>Уколико овај директоријум не постоји процес инсталације ће покушати да га креира.</p>';
$string['pathssubdirroot'] = '<p>Пуна путања до директоријума који садржи кôд Moodlea.</p>';
$string['pathssubwwwroot'] = '<p>Пуна адреса путем које ће се приступати Moodleu, тј. адреса коју ће корисници унети у адресну траку својих веб читача како би приступили Moodleu.</p>
<p>Није могуће приступати Moodleu коришћењем више адреса Ако се вашем сајту може приступити са више адреса, онда изаберите најлакшу, а за све остале адресе подесите перманентну редирекцију.</p>
<p>Ако се вашем сајту може приступити са интернета али и са унутрашње мреже (која се понекад назив интранет), онда овде употребите јавну адресу.</p>
<p>Није могуће приступати Moodleu коришћењем више адреса. Ако се вашем сајту може приступити са више адреса, онда изаберите најлакшу, а за све остале адресе подесите перманентну редирекцију.</p>
<p>Ако се вашем сајту може приступити како са интернета, тако и из интерне мреже (која се понекад назив интранет), онда овде употребите јавну адресу.</p>
<p>Ако је текућа адреса нетачна, молимо вас, промените URL адресу у адресној траци свог веб читача и поново покрените инсталацију.</p>';
$string['pathsunsecuredataroot'] = 'Dataroot локација није безбедна';
$string['pathswrongadmindir'] = 'Админ директоријум не постоји';
$string['phpextension'] = '{$a} PHP екстензија';
$string['phpversion'] = 'PHP верзија';
$string['phpversionhelp'] = '<p>Moodle захтева најмање PHP верзију 4.3.0 или 5.1.0 (5.0.x има бројне уочене проблеме).</p>
$string['phpversionhelp'] = '<p>Moodle захтева најмање PHP верзију 5.4.4 или 7.1 (7.0.x има нека ограничења).</p>
<p>Тренутно користите верзију {$a}</p>
<p>Морате надоградити PHP или преместити Moodle на веб сервер са новијом верзијом PHP-a!</br>
(У случају верзије 5.0.x можете, такође, да се вратите на 4.4.x верзију)</p>';
<p>Морате да надоградите PHP или да преместити Moodle на веб сервер са новијом верзијом PHP-a.</p>';
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
$string['welcomep20'] = 'Ову страницу видите зато што сте успешно инсталирали и покренули <strong>{$a->packname} {$a->packversion}</strong> пакет на свом серверу. Честитамо!';
$string['welcomep30'] = 'Ово издање <strong>{$a->installername}</strong> укључује апликације за креирање окружења у којем ће <strong>Moodle</strong> успешно функционисати, конкретно:';
+4 -8
View File
@@ -33,7 +33,7 @@ defined('MOODLE_INTERNAL') || die();
$string['admindirname'] = 'Administratorski direktorijum';
$string['availablelangs'] = 'Dostupni jezički paketi';
$string['chooselanguagehead'] = 'Izaberite jezik';
$string['chooselanguagesub'] = 'Molimo izaberite jezik koji će se koristiti tokom instalacije. Ovaj jezik će, takođe, biti korišćen na nivou sajta kao podrazumevani, mada to naknadno može biti promenjeno.';
$string['chooselanguagesub'] = 'Izaberite jezik koji će se koristiti tokom instalacije. Ovaj jezik će, takođe, biti korišćen na nivou sajta kao podrazumevani, iako to naknadno može da se promeni.';
$string['clialreadyconfigured'] = 'Datoteka config.php već postoji. Molimo, koristite admin/cli/install_database.php ako želite da instalirate Moodle na ovom serveru.';
$string['clialreadyinstalled'] = 'Datoteka config.php već postoji. Molimo koristite admin/cli/upgrade.php ako želite da nadogradite Moodle na ovom serveru.';
$string['cliinstallheader'] = 'Moodle {$a} program za instalaciju iz komandne linije';
@@ -72,18 +72,14 @@ $string['pathssubdataroot'] = '<p>Direktorijum gde će Moodle čuvati datoteke i
<p>Direktorijum ne sme biti dostupan direktno preko veba. </p>
<p>Ukoliko ovaj direktorijum ne postoji proces instalacije će pokušati da ga kreira.</p>';
$string['pathssubdirroot'] = '<p>Puna putanja do direktorijuma koji sadrži kôd Moodlea.</p>';
$string['pathssubwwwroot'] = '<p>Puna adresa putem koje će se pristupati Moodleu, tj. adresa koju će korisnici uneti u adresnu traku svojih veb čitača kako bi pristupili Moodleu.</p>
<p>Nije moguće pristupati Moodleu korišćenjem više adresa Ako se vašem sajtu može pristupiti sa više adresa, onda izaberite najlakšu, a za sve ostale adrese podesite permanentnu redirekciju.</p>
<p>Ako se vašem sajtu može pristupiti sa interneta ali i sa unutrašnje mreže (koja se ponekad naziv intranet), onda ovde upotrebite javnu adresu.</p>
<p>Ako je tekuća adresa netačna, molimo vas, promenite URL adresu u adresnoj traci svog veb čitača i ponovo pokrenite instalaciju.</p>';
$string['pathssubwwwroot'] = '<p>Puna adresa putem koje će se pristupati Moodleu, tj. adresa koju će korisnici uneti u adresnu traku svojih veb čitača kako bi pristupili Moodleu.</p> <p>Nije moguće pristupati Moodleu korišćenjem više adresa. Ako se vašem sajtu može pristupiti sa više adresa, onda izaberite najlakšu, a za sve ostale adrese podesite permanentnu redirekciju.</p> <p>Ako se vašem sajtu može pristupiti kako sa interneta, tako i iz interne mreže (koja se ponekad naziv intranet), onda ovde upotrebite javnu adresu.</p> <p>Ako je tekuća adresa netačna, molimo vas, promenite URL adresu u adresnoj traci svog veb čitača i ponovo pokrenite instalaciju.</p>';
$string['pathsunsecuredataroot'] = 'Dataroot lokacija nije bezbedna';
$string['pathswrongadmindir'] = 'Admin direktorijum ne postoji';
$string['phpextension'] = '{$a} PHP ekstenѕija';
$string['phpversion'] = 'PHP verzija';
$string['phpversionhelp'] = '<p>Moodle zahteva najmanje PHP verziju 4.3.0 ili 5.1.0 (5.0.x ima brojne uočene probleme).</p>
$string['phpversionhelp'] = '<p>Moodle zahteva najmanje PHP verziju 5.4.4 ili 7.1 (7.0.x ima neka ograničenja).</p>
<p>Trenutno koristite verziju {$a}</p>
<p>Morate nadograditi PHP ili premestiti Moodle na veb server sa novijom verzijom PHP-a!</br>
(U slučaju verzije 5.0.x možete, takođe, da se vratite na 4.4.x verziju)</p>';
<p>Morate da nadogradite PHP ili da premestiti Moodle na veb server sa novijom verzijom PHP-a.</p>';
$string['welcomep10'] = '{$a->installername} ({$a->installerversion})';
$string['welcomep20'] = 'Ovu stranicu vidite zato što ste uspešno instalirali i pokrenuli <strong>{$a->packname} {$a->packversion}</strong> paket na svom serveru. Čestitamo!';
$string['welcomep30'] = 'Ovo izdanje <strong>{$a->installername}</strong> uključuje aplikacije za kreiranje okruženja u kojem će <strong>Moodle</strong> uspešno funkcionisati, konkretno:';
+3 -1
View File
@@ -46,7 +46,9 @@ $string['dmlexceptiononinstall'] = '<p>Bir veritabanı hatası oluştu [{$a->err
$string['downloadedfilecheckfailed'] = 'İndirilen dosya kontrolü hatası';
$string['invalidmd5'] = 'Kontrol değişkeni yanlış - yeniden deneyin';
$string['missingrequiredfield'] = 'Gerekli alanlardan bazıları eksik';
$string['remotedownloaderror'] = 'Bileşeni sunucunuza indirirken hata oluştu, lütfen proxy(vekil) ayarlarını kontrol edin. PHP cURL eklentisi şiddetle tavsiye edilir.<br /><br /><a href="{$a->url}">{$a->url}</a><br />dosyasını kendiniz indirmeli ve indirdiğiniz dosyayı sunucunuzundaki "{$a->dest}" klasörüne kaydetmeli ve zip arşivini açmalısınız.';
$string['remotedownloaderror'] = '<p>Bileşeni sunucunuza indirirken hata oluştu, lütfen proxy ayarlarını kontrol edin. PHP cURL eklentisi şiddetle tavsiye edilir.</p>
<p><a href="{$a->url}">{$a->url}</a> dosyasını kendiniz indirmeli ve indirdiğiniz dosyayı sunucunuzundaki "{$a->dest}" klasörüne kaydetmeli ve zip arşivini açmalısınız.
</p>';
$string['wrongdestpath'] = 'Yanlış hedef yolu';
$string['wrongsourcebase'] = 'Yanlış kaynak URL tabanı';
$string['wrongzipfilename'] = 'Yanlış ZIP dosya adı';
+2
View File
@@ -416,6 +416,7 @@ $string['deleteunconfirmed'] = 'Delete not fully setup users after';
$string['deleteuser'] = 'Delete user';
$string['density'] = 'Density';
$string['denyemailaddresses'] = 'Denied email domains';
$string['devlibdirpresent'] = 'Directories with development libraries such as <em>vendor</em> or <em>node_modules</em> should not be present on public sites. See the <a href="{$a->moreinfourl}">security overview report</a> for more details.';
$string['development'] = 'Development';
$string['devicedetectregex'] = 'Device detection regular expressions';
$string['devicedetectregex_desc'] = '<p>By default, Moodle can detect devices of the type default (desktop PCs, laptops, etc), mobile (phones and small hand held devices), tablet (iPads, Android tablets) and legacy (Internet Explorer 6 users). The theme selector can be used to apply separate themes to all of these. This setting allows regular expressions that allow the detection of extra device types (these take precedence over the default types).</p>
@@ -588,6 +589,7 @@ $string['indexdata'] = 'Index data';
$string['installhijacked'] = 'Installation must be finished from the original IP address, sorry.';
$string['installsessionerror'] = 'Can not initialise PHP session, please verify that your browser accepts cookies.';
$string['intlrecommended'] = 'Intl extension is used to improve internationalization support, such as locale aware sorting.';
$string['intlrequired'] = 'Intl extension is required to improve internationalization support, such as locale aware sorting and international domain names.';
$string['invalidsection'] = 'Invalid section.';
$string['invaliduserchangeme'] = 'Username "changeme" is reserved -- you cannot create an account with it.';
$string['ipblocked'] = 'This site is not available currently.';
+8 -4
View File
@@ -7397,21 +7397,25 @@ function admin_find_write_settings($node, $data) {
}
if ($node instanceof admin_category) {
$entries = array_keys($node->children);
foreach ($entries as $entry) {
$return = array_merge($return, admin_find_write_settings($node->children[$entry], $data));
if ($node->check_access()) {
$entries = array_keys($node->children);
foreach ($entries as $entry) {
$return = array_merge($return, admin_find_write_settings($node->children[$entry], $data));
}
}
} else if ($node instanceof admin_settingpage) {
if ($node->check_access()) {
foreach ($node->settings as $setting) {
$fullname = $setting->get_full_name();
if (array_key_exists($fullname, $data)) {
$return[$fullname] = $setting;
}
}
}
}
return $return;
}
+23 -3
View File
@@ -2167,8 +2167,28 @@ class global_navigation extends navigation_node {
return false;
}
// Add a branch for the current user.
$canseefullname = has_capability('moodle/site:viewfullnames', $coursecontext);
$usernode = $usersnode->add(fullname($user, $canseefullname), $userviewurl, self::TYPE_USER, null, 'user' . $user->id);
// Only reveal user details if $user is the current user, or a user to which the current user has access.
$viewprofile = true;
if (!$iscurrentuser) {
require_once($CFG->dirroot . '/user/lib.php');
if ($this->page->context->contextlevel == CONTEXT_USER && !has_capability('moodle/user:viewdetails', $usercontext) ) {
$viewprofile = false;
} else if ($this->page->context->contextlevel != CONTEXT_USER && !user_can_view_profile($user, $course, $usercontext)) {
$viewprofile = false;
}
if (!$viewprofile) {
$viewprofile = user_can_view_profile($user, null, $usercontext);
}
}
// Now, conditionally add the user node.
if ($viewprofile) {
$canseefullname = has_capability('moodle/site:viewfullnames', $coursecontext);
$usernode = $usersnode->add(fullname($user, $canseefullname), $userviewurl, self::TYPE_USER, null, 'user' . $user->id);
} else {
$usernode = $usersnode->add(get_string('user'));
}
if ($this->page->context->contextlevel == CONTEXT_USER && $user->id == $this->page->context->instanceid) {
$usernode->make_active();
}
@@ -2279,7 +2299,7 @@ class global_navigation extends navigation_node {
$reports = core_component::get_plugin_list('gradereport');
arsort($reports); // User is last, we want to test it first.
$userscourses = enrol_get_users_courses($user->id);
$userscourses = enrol_get_users_courses($user->id, false, '*');
$userscoursesnode = $usernode->add(get_string('courses'));
$count = 0;
+36 -23
View File
@@ -4137,16 +4137,16 @@ EOD;
*/
public function context_header($headerinfo = null, $headinglevel = 1) {
global $DB, $USER, $CFG;
require_once($CFG->dirroot . '/user/lib.php');
$context = $this->page->context;
// Make sure to use the heading if it has been set.
if (isset($headerinfo['heading'])) {
$heading = $headerinfo['heading'];
} else {
$heading = null;
}
$heading = null;
$imagedata = null;
$subheader = null;
$userbuttons = null;
// Make sure to use the heading if it has been set.
if (isset($headerinfo['heading'])) {
$heading = $headerinfo['heading'];
}
// The user context currently has images and buttons. Other contexts may follow.
if (isset($headerinfo['user']) || $context->contextlevel == CONTEXT_USER) {
if (isset($headerinfo['user'])) {
@@ -4155,29 +4155,42 @@ EOD;
// Look up the user information if it is not supplied.
$user = $DB->get_record('user', array('id' => $context->instanceid));
}
// If the user context is set, then use that for capability checks.
if (isset($headerinfo['usercontext'])) {
$context = $headerinfo['usercontext'];
}
// Use the user's full name if the heading isn't set.
if (!isset($heading)) {
$heading = fullname($user);
// Only provide user information if the user is the current user, or a user which the current user can view.
$canviewdetails = false;
if ($user->id == $USER->id || user_can_view_profile($user)) {
$canviewdetails = true;
}
$imagedata = $this->user_picture($user, array('size' => 100));
// Check to see if we should be displaying a message button.
if (!empty($CFG->messaging) && $USER->id != $user->id && has_capability('moodle/site:sendmessage', $context)) {
$userbuttons = array(
'messages' => array(
'buttontype' => 'message',
'title' => get_string('message', 'message'),
'url' => new moodle_url('/message/index.php', array('id' => $user->id)),
'image' => 'message',
'linkattributes' => message_messenger_sendmessage_link_params($user),
'page' => $this->page
)
);
$this->page->requires->string_for_js('changesmadereallygoaway', 'moodle');
if ($canviewdetails) {
// Use the user's full name if the heading isn't set.
if (!isset($heading)) {
$heading = fullname($user);
}
$imagedata = $this->user_picture($user, array('size' => 100));
// Check to see if we should be displaying a message button.
if (!empty($CFG->messaging) && $USER->id != $user->id && has_capability('moodle/site:sendmessage', $context)) {
$userbuttons = array(
'messages' => array(
'buttontype' => 'message',
'title' => get_string('message', 'message'),
'url' => new moodle_url('/message/index.php', array('id' => $user->id)),
'image' => 'message',
'linkattributes' => message_messenger_sendmessage_link_params($user),
'page' => $this->page
)
);
$this->page->requires->string_for_js('changesmadereallygoaway', 'moodle');
}
} else {
$heading = null;
}
}
+1
View File
@@ -152,6 +152,7 @@ class core_admintree_testcase extends advanced_testcase {
public function test_config_logging() {
global $DB;
$this->resetAfterTest();
$this->setAdminUser();
$DB->delete_records('config_log', array());
+1 -1
View File
@@ -267,7 +267,7 @@ if (!$students) {
echo '<legend class="ftoggler">'.get_string('send_message', 'feedback').'</legend>';
echo '<div>';
echo '<label for="feedback_subject">'.get_string('subject', 'feedback').'&nbsp;</label>';
echo '<input type="text" id="feedback_subject" size="50" maxlength="255" name="subject" value="'.$subject.'" />';
echo '<input type="text" id="feedback_subject" size="50" maxlength="255" name="subject" value="'.s($subject).'" />';
echo '</div>';
print_textarea(true, 15, 25, 30, 10, "message", $message);
print_string('formathtml');
+6 -24
View File
@@ -26,6 +26,7 @@
require_once(dirname(dirname(dirname(__FILE__))).'/config.php');
require_once($CFG->dirroot.'/mod/forum/lib.php');
require_once($CFG->dirroot.'/rating/lib.php');
require_once($CFG->dirroot.'/user/lib.php');
$courseid = optional_param('course', null, PARAM_INT); // Limit the posts to just this course
$userid = optional_param('id', $USER->id, PARAM_INT); // User id whose posts we want to view
@@ -134,29 +135,8 @@ if (empty($result->posts)) {
// In either case we need to decide whether we can show personal information
// about the requested user to the current user so we will execute some checks
// First check the obvious, its the current user, a specific course has been
// provided (require_login has been called), or they have a course contact role.
// True to any of those and the current user can see the details of the
// requested user.
$canviewuser = ($iscurrentuser || $isspecificcourse || empty($CFG->forceloginforprofiles) || has_coursecontact_role($userid));
// Next we'll check the caps, if the current user has the view details and a
// specific course has been requested, or if they have the view all details
$canviewuser = ($canviewuser || ($isspecificcourse && has_capability('moodle/user:viewdetails', $coursecontext) || has_capability('moodle/user:viewalldetails', $usercontext)));
// If none of the above was true the next step is to check a shared relation
// through some course
if (!$canviewuser) {
// Get all of the courses that the users have in common
$sharedcourses = enrol_get_shared_courses($USER->id, $user->id, true);
foreach ($sharedcourses as $sharedcourse) {
// Check the view cap within the course context
if (has_capability('moodle/user:viewdetails', context_course::instance($sharedcourse->id))) {
$canviewuser = true;
break;
}
}
unset($sharedcourses);
}
// TODO - Remove extra cap check once MDL-59172 is resolved.
$canviewuser = user_can_view_profile($user, null, $usercontext) || has_capability('moodle/user:viewalldetails', $usercontext);
// Prepare the page title
$pagetitle = get_string('noposts', 'mod_forum');
@@ -237,8 +217,10 @@ if (empty($result->posts)) {
$PAGE->set_title($pagetitle);
if ($isspecificcourse) {
$PAGE->set_heading($pageheading);
} else {
} else if ($canviewuser) {
$PAGE->set_heading(fullname($user));
} else {
$PAGE->set_heading($SITE->fullname);
}
echo $OUTPUT->header();
if (!$isspecificcourse) {
+1 -3
View File
@@ -210,9 +210,7 @@ if (!$result->correctanswer && !$result->noanswer && !$result->isessayquestion &
$url = new moodle_url('/mod/lesson/view.php', array('id'=>$cm->id, 'pageid'=>$result->newpageid));
if ($lesson->review && !$result->correctanswer && !$result->noanswer && !$result->isessayquestion && !$result->maxattemptsreached) {
// When the answer is wrong - the result->newpageid points back to the current question.
$newpageid = $lesson->get_next_page($page->nextpageid);
$url = new moodle_url('/mod/lesson/view.php', array('id'=>$cm->id, 'pageid'=>$newpageid));
// Button to continue the lesson (the page to go is configured by the teacher).
echo $OUTPUT->single_button($url, get_string('reviewquestioncontinue', 'lesson'));
} else {
// Normal continue button
+21
View File
@@ -387,5 +387,26 @@ function xmldb_lesson_upgrade($oldversion) {
// Moodle v3.1.0 release upgrade line.
// Put any upgrade step following this.
if ($oldversion < 2016052301) {
// Delete orphaned lesson answer and response files.
$sql = "SELECT DISTINCT f.contextid, f.component, f.filearea, f.itemid
FROM {files} f
LEFT JOIN {lesson_answers} la ON f.itemid = la.id
WHERE component = :component
AND (filearea = :fileareaanswer OR filearea = :filearearesponse)
AND la.id IS NULL";
$orphanedfiles = $DB->get_recordset_sql($sql, array('component' => 'mod_lesson', 'fileareaanswer' => 'page_answers',
'filearearesponse' => 'page_responses'));
$fs = get_file_storage();
foreach ($orphanedfiles as $file) {
$fs->delete_area_files($file->contextid, $file->component, $file->filearea, $file->itemid);
}
$orphanedfiles->close();
upgrade_mod_savepoint(true, 2016052301, 'lesson');
}
return true;
}
+9 -2
View File
@@ -2291,6 +2291,15 @@ abstract class lesson_page extends lesson_base {
$DB->delete_records("lesson_attempts", array("pageid" => $this->properties->id));
$DB->delete_records("lesson_branch", array("pageid" => $this->properties->id));
// Delete files related to answers and responses.
if ($answers = $DB->get_records("lesson_answers", array("pageid" => $this->properties->id))) {
foreach ($answers as $answer) {
$fs->delete_area_files($context->id, 'mod_lesson', 'page_answers', $answer->id);
$fs->delete_area_files($context->id, 'mod_lesson', 'page_responses', $answer->id);
}
}
// ...now delete the answers...
$DB->delete_records("lesson_answers", array("pageid" => $this->properties->id));
// ..and the page itself
@@ -2310,8 +2319,6 @@ abstract class lesson_page extends lesson_base {
// Delete files associated with this page.
$fs->delete_area_files($context->id, 'mod_lesson', 'page_contents', $this->properties->id);
$fs->delete_area_files($context->id, 'mod_lesson', 'page_answers', $this->properties->id);
$fs->delete_area_files($context->id, 'mod_lesson', 'page_responses', $this->properties->id);
// repair the hole in the linkage
if (!$this->properties->prevpageid && !$this->properties->nextpageid) {
@@ -115,49 +115,6 @@ Feature: In a lesson activity, students can not re-attempt a question more than
When I press "Submit"
Then I should see "Maximum number of attempts reached - Moving to next page"
Scenario: Check that we can move past a question we don't want to re-attempt
Given I log in as "teacher1"
And I am on site homepage
And I follow "Course 1"
And I follow "Test lesson name"
And I navigate to "Edit settings" in current page administration
And I expand all fieldsets
And I set the field "Provide option to try a question again" to "Yes"
And I set the field "Maximum number of attempts" to "3"
And I press "Save and display"
And I log out
And I log in as "student1"
And I am on site homepage
And I follow "Course 1"
And I follow "Test lesson name"
And I should see "First page contents"
And I press "Next page"
And I should see "The earth is round"
And I set the following fields to these values:
| False| 1 |
And I press "Submit"
And I should see "Wrong"
When I press "No, I just want to go on to the next question"
Then I should not see "The earth is round"
And I should see "Kermit is a frog"
And I set the following fields to these values:
| False | 1 |
And I press "Submit"
And I should see "Wrong"
And I press "Yes, I'd like to try again"
And I should see "Kermit is a frog"
And I set the following fields to these values:
| False | 1 |
And I press "Submit"
And I should see "Wrong"
And I press "Yes, I'd like to try again"
And I should see "Kermit is a frog"
And I set the following fields to these values:
| False | 1 |
And I press "Submit"
And I should not see "Yes, I'd like to try again"
And I should see "Continue"
@javascript @_bug_phantomjs
Scenario: Check that we can not click back on the browser at the last quiz result page and re-attempt the last question to get full marks
Given I log in as "student1"
+1 -1
View File
@@ -24,7 +24,7 @@
defined('MOODLE_INTERNAL') || die();
$plugin->version = 2016052300; // The current module version (Date: YYYYMMDDXX)
$plugin->version = 2016052301; // The current module version (Date: YYYYMMDDXX)
$plugin->requires = 2016051900; // Requires this Moodle version
$plugin->component = 'mod_lesson'; // Full name of the plugin (used for diagnostics)
$plugin->cron = 0;
+15 -10
View File
@@ -80,25 +80,30 @@ function report_completion_can_access_user_report($user, $course) {
}
if ($course->id != SITEID and !$course->enablecompletion) {
return;
return false;
}
$coursecontext = context_course::instance($course->id);
$personalcontext = context_user::instance($user->id);
if (has_capability('report/completion:view', $coursecontext)) {
return true;
}
if (has_capability('moodle/user:viewuseractivitiesreport', $personalcontext)) {
if ($user->id == $USER->id) {
if ($course->showreports and (is_viewing($coursecontext, $USER) or is_enrolled($coursecontext, $USER))) {
return true;
}
} else if (has_capability('moodle/user:viewuseractivitiesreport', $personalcontext)) {
if ($course->showreports and (is_viewing($coursecontext, $user) or is_enrolled($coursecontext, $user))) {
return true;
}
} else if ($user->id == $USER->id) {
if ($course->showreports and (is_viewing($coursecontext, $USER) or is_enrolled($coursecontext, $USER))) {
return true;
}
}
// Check if $USER shares group with $user (in case separated groups are enabled and 'moodle/site:accessallgroups' is disabled).
if (!groups_user_groups_visible($course, $user->id)) {
return false;
}
if (has_capability('report/completion:view', $coursecontext)) {
return true;
}
return false;
+1 -1
View File
@@ -45,7 +45,7 @@ if ($USER->id != $user->id and has_capability('moodle/user:viewuseractivitiesrep
require_login($course);
}
if (!report_completion_can_access_user_report($user, $course, true)) {
if (!report_completion_can_access_user_report($user, $course)) {
// this should never happen
print_error('nocapability', 'report_completion');
}
+1
View File
@@ -35,6 +35,7 @@ $string['log:view'] = 'View course logs';
$string['log:viewtoday'] = 'View today\'s logs';
$string['page'] = 'Page {$a}';
$string['logsformat'] = 'Logs format';
$string['nocapability'] = 'Can not access user log report';
$string['nologreaderenabled'] = 'No log reader enabled';
$string['page-report-log-x'] = 'Any log report';
$string['page-report-log-index'] = 'Course log report';
+15 -15
View File
@@ -89,6 +89,21 @@ function report_log_can_access_user_report($user, $course) {
$coursecontext = context_course::instance($course->id);
$personalcontext = context_user::instance($user->id);
if ($user->id == $USER->id) {
if ($course->showreports and (is_viewing($coursecontext, $USER) or is_enrolled($coursecontext, $USER))) {
return array(true, true);
}
} else if (has_capability('moodle/user:viewuseractivitiesreport', $personalcontext)) {
if ($course->showreports and (is_viewing($coursecontext, $user) or is_enrolled($coursecontext, $user))) {
return array(true, true);
}
}
// Check if $USER shares group with $user (in case separated groups are enabled and 'moodle/site:accessallgroups' is disabled).
if (!groups_user_groups_visible($course, $user->id)) {
return array(false, false);
}
$today = false;
$all = false;
@@ -99,21 +114,6 @@ function report_log_can_access_user_report($user, $course) {
$all = true;
}
if ($today and $all) {
return array(true, true);
}
if (has_capability('moodle/user:viewuseractivitiesreport', $personalcontext)) {
if ($course->showreports and (is_viewing($coursecontext, $user) or is_enrolled($coursecontext, $user))) {
return array(true, true);
}
} else if ($user->id == $USER->id) {
if ($course->showreports and (is_viewing($coursecontext, $USER) or is_enrolled($coursecontext, $USER))) {
return array(true, true);
}
}
return array($all, $today);
}
+4
View File
@@ -58,6 +58,10 @@ if ($USER->id != $user->id and has_capability('moodle/user:viewuseractivitiesrep
list($all, $today) = report_log_can_access_user_report($user, $course);
if (!$today && !$all) {
print_error('nocapability', 'report_log');
}
if ($mode === 'today') {
if (!$today) {
require_capability('report/log:viewtoday', $coursecontext);
@@ -26,6 +26,7 @@
$string['eventactivityreportviewed'] = 'Activity report viewed';
$string['eventoutlinereportviewed'] = 'Outline report viewed';
$string['neverseen'] = 'Never seen';
$string['nocapability'] = 'Can not access user outline report';
$string['nologreaderenabled'] = 'No log reader enabled';
$string['numviews'] = '{$a->numviews} by {$a->distinctusers} users';
$string['outline:view'] = 'View activity report';
+14 -9
View File
@@ -70,19 +70,24 @@ function report_outline_can_access_user_report($user, $course) {
$coursecontext = context_course::instance($course->id);
$personalcontext = context_user::instance($user->id);
if (has_capability('report/outline:view', $coursecontext)) {
return true;
}
if (has_capability('moodle/user:viewuseractivitiesreport', $personalcontext)) {
if ($user->id == $USER->id) {
if ($course->showreports and (is_viewing($coursecontext, $USER) or is_enrolled($coursecontext, $USER))) {
return true;
}
} else if (has_capability('moodle/user:viewuseractivitiesreport', $personalcontext)) {
if ($course->showreports and (is_viewing($coursecontext, $user) or is_enrolled($coursecontext, $user))) {
return true;
}
} else if ($user->id == $USER->id) {
if ($course->showreports and (is_viewing($coursecontext, $USER) or is_enrolled($coursecontext, $USER))) {
return true;
}
}
// Check if $USER shares group with $user (in case separated groups are enabled and 'moodle/site:accessallgroups' is disabled).
if (!groups_user_groups_visible($course, $user->id)) {
return false;
}
if (has_capability('report/outline:view', $coursecontext)) {
return true;
}
return false;
+2 -2
View File
@@ -55,8 +55,8 @@ if ($USER->id != $user->id and has_capability('moodle/user:viewuseractivitiesrep
}
$PAGE->set_url('/report/outline/user.php', array('id'=>$userid, 'course'=>$courseid, 'mode'=>$mode));
if (!report_outline_can_access_user_report($user, $course, true)) {
require_capability('report/outline:view', $coursecontext);
if (!report_outline_can_access_user_report($user, $course)) {
print_error('nocapability', 'report_outline');
}
$stractivityreport = get_string('activityreport');
@@ -80,6 +80,9 @@ $string['check_noauth_details'] = '<p>The <em>No authentication</em> plugin is n
$string['check_noauth_error'] = 'The No authentication plugin cannot be used on production sites.';
$string['check_noauth_name'] = 'No authentication';
$string['check_noauth_ok'] = 'No authentication plugin is disabled.';
$string['check_nodemodules_details'] = '<p>The directory <em>{$a->path}</em> contains Node.js modules and their dependencies, typically installed by the NPM utility. These modules may be required for Moodle development. They are not needed to run a Moodle site and they can contain potentially dangerous code exposing your site to remote attacks.</p><p>It is strongly recommended to remove the directory if the site is available via a public URL, or at least prohibit web access to it.</p>';
$string['check_nodemodules_info'] = 'The node_modules directory should not be present on public sites.';
$string['check_nodemodules_name'] = 'Node.js modules directory';
$string['check_openprofiles_details'] = 'Open user profiles can be abused by spammers. It is recommended that either <code>Force users to log in for profiles</code> or <code>Force users to log in</code> are enabled.';
$string['check_openprofiles_error'] = 'Anyone can may view user profiles without logging in.';
$string['check_openprofiles_name'] = 'Open user profiles';
@@ -116,6 +119,9 @@ $string['check_unsecuredataroot_error'] = 'Your dataroot directory <code>{$a}</c
$string['check_unsecuredataroot_name'] = 'Insecure dataroot';
$string['check_unsecuredataroot_ok'] = 'Dataroot directory must not be accessible via the web.';
$string['check_unsecuredataroot_warning'] = 'Your dataroot directory <code>{$a}</code> is in the wrong location and might be exposed to the web.';
$string['check_vendordir_details'] = '<p>The vendor directory <em>{$a->path}</em> contains various third-party libraries and their dependencies, typically installed by the PHP Composer. It may be needed for local development, such as for installing the PHPUnit framework. But it can also contain potentially dangerous code exposing your site to remote attacks.</p><p>It is strongly recommended to remove the directory if the site is available via a public URL, or at least prohibit web access to it.</p>';
$string['check_vendordir_info'] = 'The vendor directory should not be present on public sites.';
$string['check_vendordir_name'] = 'Vendor directory';
$string['check_webcron_details'] = '<p>Running the cron from a web browser can expose privileged information to anonymous users. It is recommended to only run the cron from the command line or set a cron password for remote access.</p>';
$string['check_webcron_warning'] = 'Anonymous users can access cron.';
$string['check_webcron_name'] = 'Web cron';
+65 -1
View File
@@ -41,6 +41,8 @@ function report_security_get_issue_list() {
return array(
'report_security_check_unsecuredataroot',
'report_security_check_displayerrors',
'report_security_check_vendordir',
'report_security_check_nodemodules',
'report_security_check_noauth',
'report_security_check_embed',
'report_security_check_mediafilterswf',
@@ -864,4 +866,66 @@ function report_security_check_webcron($detailed = false) {
}
return $result;
}
}
/**
* Check the presence of the vendor directory.
*
* @param bool $detailed Return detailed info.
* @return object Result data.
*/
function report_security_check_vendordir($detailed = false) {
global $CFG;
$result = (object)[
'issue' => 'report_security_check_vendordir',
'name' => get_string('check_vendordir_name', 'report_security'),
'info' => get_string('check_vendordir_info', 'report_security'),
'details' => null,
'status' => null,
'link' => null,
];
if (is_dir($CFG->dirroot.'/vendor')) {
$result->status = REPORT_SECURITY_WARNING;
} else {
$result->status = REPORT_SECURITY_OK;
}
if ($detailed) {
$result->details = get_string('check_vendordir_details', 'report_security', ['path' => $CFG->dirroot.'/vendor']);
}
return $result;
}
/**
* Check the presence of the node_modules directory.
*
* @param bool $detailed Return detailed info.
* @return object Result data.
*/
function report_security_check_nodemodules($detailed = false) {
global $CFG;
$result = (object)[
'issue' => 'report_security_check_nodemodules',
'name' => get_string('check_nodemodules_name', 'report_security'),
'info' => get_string('check_nodemodules_info', 'report_security'),
'details' => null,
'status' => null,
'link' => null,
];
if (is_dir($CFG->dirroot.'/node_modules')) {
$result->status = REPORT_SECURITY_WARNING;
} else {
$result->status = REPORT_SECURITY_OK;
}
if ($detailed) {
$result->details = get_string('check_nodemodules_details', 'report_security', ['path' => $CFG->dirroot.'/node_modules']);
}
return $result;
}
+14 -10
View File
@@ -78,19 +78,23 @@ function report_stats_can_access_user_report($user, $course) {
$coursecontext = context_course::instance($course->id);
$personalcontext = context_user::instance($user->id);
if (has_capability('report/stats:view', $coursecontext)) {
return true;
}
if (has_capability('moodle/user:viewuseractivitiesreport', $personalcontext)) {
if ($course->showreports and (is_viewing($coursecontext, $user) or is_enrolled($coursecontext, $user))) {
return true;
}
} else if ($user->id == $USER->id) {
if ($user->id == $USER->id) {
if ($course->showreports and (is_viewing($coursecontext, $USER) or is_enrolled($coursecontext, $USER))) {
return true;
}
} else if (has_capability('moodle/user:viewuseractivitiesreport', $personalcontext)) {
if ($course->showreports and (is_viewing($coursecontext, $user) or is_enrolled($coursecontext, $user))) {
return true;
}
}
// Check if $USER shares group with $user (in case separated groups are enabled and 'moodle/site:accessallgroups' is disabled).
if (!groups_user_groups_visible($course, $user->id)) {
return false;
}
if (has_capability('report/stats:view', $coursecontext)) {
return true;
}
return false;
+1 -1
View File
@@ -51,7 +51,7 @@ if ($USER->id != $user->id and has_capability('moodle/user:viewuseractivitiesrep
require_login($course);
}
if (!report_stats_can_access_user_report($user, $course, true)) {
if (!report_stats_can_access_user_report($user, $course)) {
// this should never happen
print_error('nocapability', 'report_stats');
}
+26 -16
View File
@@ -1100,10 +1100,15 @@ function user_mygrades_url($userid = null, $courseid = SITEID) {
}
/**
* Check if a user has the permission to viewdetails in a shared course's context.
* Check if the current user has permission to view details of the supplied user.
*
* This function supports two modes:
* If the optional $course param is omitted, then this function finds all shared courses and checks whether the current user has
* permission in any of them, returning true if so.
* If the $course param is provided, then this function checks permissions in ONLY that course.
*
* @param object $user The other user's details.
* @param object $course Use this course to see if we have permission to see this user's profile.
* @param object $course if provided, only check permissions in this course.
* @param context $usercontext The user context if available.
* @return bool true for ability to view this user, else false.
*/
@@ -1114,33 +1119,37 @@ function user_can_view_profile($user, $course = null, $usercontext = null) {
return false;
}
// If any of these four things, return true.
// Number 1.
// Current user can always view their profile.
if ($USER->id == $user->id) {
return true;
}
// Number 2.
// Do we need to be logged in?
if (empty($CFG->forceloginforprofiles)) {
return true;
}
if (empty($usercontext)) {
$usercontext = context_user::instance($user->id);
}
// Number 3.
if (has_capability('moodle/user:viewdetails', $usercontext)) {
return true;
}
// Number 4.
// Course contacts have visible profiles always.
if (has_coursecontact_role($user->id)) {
return true;
}
// If we're only checking the capabilities in the single provided course.
if (isset($course)) {
$sharedcourses = array($course);
// Confirm that $user is enrolled in the $course we're checking.
if (is_enrolled(context_course::instance($course->id), $user)) {
$sharedcourses = array($course);
}
} else {
// Else we're checking whether the current user can view $user's profile anywhere, so check user context first.
if (empty($usercontext)) {
$usercontext = context_user::instance($user->id);
}
if (has_capability('moodle/user:viewdetails', $usercontext) || has_capability('moodle/user:viewalldetails', $usercontext)) {
return true;
}
// No capability found in user context alone, so proceed to check all courses.
$sharedcourses = enrol_get_shared_courses($USER->id, $user->id, true);
}
@@ -1150,7 +1159,8 @@ function user_can_view_profile($user, $course = null, $usercontext = null) {
foreach ($sharedcourses as $sharedcourse) {
$coursecontext = context_course::instance($sharedcourse->id);
if (has_capability('moodle/user:viewdetails', $coursecontext)) {
if (has_capability('moodle/user:viewdetails', $coursecontext) ||
has_capability('moodle/user:viewalldetails', $coursecontext)) {
if (!groups_user_groups_visible($sharedcourse, $user->id)) {
// Not a member of the same group.
continue;
+5
View File
@@ -530,6 +530,11 @@ class core_userliblib_testcase extends advanced_testcase {
$this->getDataGenerator()->enrol_user($user4->id, $course3->id);
$this->getDataGenerator()->enrol_user($user5->id, $course3->id);
// User 3 should not be able to see user 1, either by passing their own course (course 2) or user 1's course (course 1).
$this->setUser($user3);
$this->assertFalse(user_can_view_profile($user1, $course2));
$this->assertFalse(user_can_view_profile($user1, $course1));
// Remove capability moodle/user:viewdetails in course 2.
assign_capability('moodle/user:viewdetails', CAP_PROHIBIT, $studentrole->id, $coursecontext);
$coursecontext->mark_dirty();
+2 -2
View File
@@ -29,11 +29,11 @@
defined('MOODLE_INTERNAL') || die();
$version = 2016052306.00; // 20160523 = branching date YYYYMMDD - do not modify!
$version = 2016052308.00; // 20160523 = branching date YYYYMMDD - do not modify!
// RR = release increments - 00 in DEV branches.
// .XX = incremental changes.
$release = '3.1.6 (Build: 20170508)'; // Human-friendly version name
$release = '3.1.8 (Build: 20170911)'; // Human-friendly version name
$branch = '31'; // This version's branch.
$maturity = MATURITY_STABLE; // This version's maturity level.