Moodle APIs 4.3
Moodle 4.3.6 (Build: 20240812)
auth_oauth2

Namespaces

namespace  auth_oauth2
 Class for loading/storing oauth2 linked logins from the DB.
 
namespace  auth_oauth2\output
 Output rendering for the plugin.
 
namespace  auth_oauth2\privacy
 Privacy class for requesting user data for auth_oauth2.
 

Classes

class  auth_oauth2\api
 Static list of api methods for auth oauth2 configuration. More...
 
class  auth_oauth2\auth
 Plugin for oauth2 authentication. More...
 
class  auth_oauth2\linked_login
 Class for loading/storing issuer from the DB. More...
 
class  auth_oauth2\output\renderer
 Implements the plugin renderer. More...
 
class  auth_oauth2\privacy\provider
 Privacy provider for auth_oauth2. More...
 
class  auth_plugin_oauth2
 Plugin for oauth2 authentication. More...
 

Functions

 auth_oauth2_extend_navigation_user_settings (navigation_node $useraccount, stdClass $user, context_user $context, stdClass $course, context_course $coursecontext)
 Navigation hook to add to preferences page.
 
 auth_oauth2_pre_user_delete ($user)
 Callback to remove linked logins for deleted users.
 
 xmldb_auth_oauth2_upgrade ($oldversion)
 Upgrade function.
 

Variables

 $capabilities
 
 $observers
 This file definies observers needed by the plugin.
 
 $plugin = 2023100400
 
$plugin component = 'auth_oauth2'
 
$plugin version = 2023100900
 

Detailed Description

Function Documentation

◆ auth_oauth2_extend_navigation_user_settings()

auth_oauth2_extend_navigation_user_settings ( navigation_node $useraccount,
stdClass $user,
context_user $context,
stdClass $course,
context_course $coursecontext )

Navigation hook to add to preferences page.

Parameters
navigation_node$useraccount
stdClass$user
context_user$context
stdClass$course
context_course$coursecontext

◆ auth_oauth2_pre_user_delete()

auth_oauth2_pre_user_delete ( $user)

Callback to remove linked logins for deleted users.

Parameters
stdClass$user

◆ xmldb_auth_oauth2_upgrade()

xmldb_auth_oauth2_upgrade ( $oldversion)

Upgrade function.

Parameters
int$oldversionthe version we are upgrading from
Return values
boolresult

Variable Documentation

◆ $capabilities

$capabilities
Initial value:
= [
'auth/oauth2:managelinkedlogins' => array(
'captype' => 'write',
'contextlevel' => CONTEXT_USER,
'archetypes' => array(
'user' => CAP_ALLOW
)
),
]
const CONTEXT_USER
User context level - one instance for each user describing what others can do to user.
Definition accesslib.php:124
const CAP_ALLOW
Allow permission, overrides CAP_PREVENT defined in parent contexts.
Definition accesslib.php:115

◆ $observers

$observers
Initial value:
= [
[
'eventname' => '\core\event\user_deleted',
'callback' => '\auth_oauth2\api::user_deleted',
],
]

This file definies observers needed by the plugin.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later