Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

Infected file report

Author: Nathan Nguyen <nathannguyen@catalyst-au.net>
Copyright: Catalyst IT
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 172 lines (6 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class


Class: provider  - X-Ref

Infected file report

get_metadata(collection $collection)   X-Ref
This plugin stores the userid of infected users.

return: collection The populated collection.
param: collection $collection the collection object to add data to.

get_contexts_for_userid(int $userid)   X-Ref
This function gets the contexts containing data for a userid.

return: request\contextlist the context list for the user.
param: int $userid The userid to get contexts for.

export_user_data(request\approved_contextlist $contextlist)   X-Ref
This function exports user data on infected files from the contextlist provided.

return: void
param: request\approved_contextlist $contextlist

delete_data_for_all_users_in_context(\context $context)   X-Ref
As this report tracks potential attempted security violations,
This data should not be deleted at request. This would allow for an
avenue for a malicious user to cover their tracks. This function deliberately
does no deletes.

return: void
param: \context $context the context to delete for.

delete_data_for_user(request\approved_contextlist $contextlist)   X-Ref
As this report tracks potential attempted security violations,
This data should not be deleted at request. This would allow for an
avenue for a malicious user to cover their tracks. This function deliberately
does no deletes.

return: void
param: \core_privacy\local\request\approved_contextlist $contextlist the contextlist to delete for.

get_users_in_context(request\userlist $userlist)   X-Ref
This gets the list of users inside of the provided context. In this case, its only system context
which contains users.

return: void
param: \core_privacy\local\request\userlist $userlist

delete_data_for_users(request\approved_userlist $userlist)   X-Ref
As this report tracks potential attempted security violations,
This data should not be deleted at request. This would allow for an
avenue for a malicious user to cover their tracks. This function deliberately
does no deletes.

return: void
param: request\approved_userlist $userlist