59 Commits

Author SHA1 Message Date
Juan Leyva
813320fbb6 MDL-57102 auth: Add new signup_is_enabled function
And apply the function in:
- login/signup.php
- blocks/login/block_login.php
2016-11-23 19:35:08 +00:00
Juan Leyva
83e4dc1796 MDL-56092 core_auth: New WS core_auth_confirm_user 2016-10-04 09:50:32 +01:00
Juan Leyva
574b9d86e9 MDL-56092 core_auth: Move signup code from form to authlib 2016-10-04 09:49:26 +01:00
Jakob
cffd0fa138 MDL-53306 auth: Add hook for auth plugins to access user object.
Add a hook for auth plugins to be able to modify or check a user, before
raising any authentication errors.

The auth plugin needs to add a public function like this:

/**
 * Pre user_login hook.
 * This method is called from authenticate_user_login() right after the user
 * object is generated. This gives the auth plugins an option to make adjustments
 * before the verification process starts.
 *
 * @param object $user user object, later used for $USER
*/
public function pre_user_login_hook(&$user) {
    // Override if needed.
}
2016-05-30 11:57:03 -07:00
Marina Glancy
0f7f30021a MDL-51217 auth: check if recaptcha enabled for current plugin 2015-09-16 15:30:04 +08:00
Charles Fulton
b6f28375b7 MDL-45113 auth: add is_configured method and convert auth_db to use it 2015-07-31 15:16:08 +00:00
Brendan Heywood
bf08e3f94c MDL-48887 An auth plugin hook enabling removal of redundant redirects
This introduces a new hook allowing an auth plugin to redirect to an
external login page directly without redundant redirects to the standard
login page first, or where possible to authenticate the user and simply
continue loading the page without any redirects. For some protocols such
as SAML reducing the number of redirects to the bare minimum greatly
speeds up the login process on high latency networks.
2015-04-02 11:08:20 +02:00
Vadim Dvorovenko
2fbd261d45 MDL-42172 Authentification: Adding alternate names to "Lock user fields"
Adding alternate name fields (firstnamephonetic, lastnamephonetic,
middlename, alternatename) to "Lock user fields" for all
authentification plugins. This is needed to sync alternate name fields
with external data sources and to lock them for editing.
2015-01-16 09:23:51 +07:00
Charles Fulton
65d7932ca3 MDL-46247 auth: Add new language for unauthorised external user 2014-07-07 10:16:09 -07:00
Simey Lameze
f9f9d187f8 MDL-40805 auth_cas : Method postlogout_hook created to be executed after user_loggedout event trigger. 2014-06-24 11:00:32 +08:00
Tim Hunt
5bcfd504df MDL-45618 Fix @since PHPdoc tags. 2014-05-19 17:03:04 +01:00
Ankit Agarwal
52dc1de746 MDL-42891 administration: Re-implement incorrect login notification, without using the logtable. 2014-04-01 17:18:15 +08:00
Brian King
c484af5aa6 MDL-43497 Language: Allow course language to be overridden 2014-03-07 09:11:18 +01:00
Ankit Agarwal
963cdce4e2 MDL-42097 auth: Auth plugins must check passwordurl before returning it 2013-12-03 14:17:42 +08:00
Petr Škoda
d79d5ac276 MDL-31501 rework user session architecture
List of changes:
 * New OOP API using PHP namespace \core\session\.
 * All handlers now update the sessions table consistently.
 * Experimental DB session support in Oracle.
 * Full support for session file handler (filesystem locking required).
 * New option for alternative session directory.
 * Official memcached session handler support.
 * Workaround for memcached version with non-functional gc.
 * Improved security - forced session id regeneration.
 * Improved compatibility with recent PHP releases.
 * Fixed borked CSS during install in debug mode.
 * Switched to file based sessions in new installs.
 * DB session setting disappears if DB does not support sessions.
 * DB session setting disappears if session handler specified in config.php.
 * Fast purging of sessions used in request only.
 * No legacy distinction -  file, database and memcached support the same functionality.
 * Session handler name included in performance info.
 * Fixed user_loggedin and user_loggedout event triggering.
 * Other minor bugfixing and improvements.
 * Fixed database session segfault if MUC disposed before $DB.

Limitations:
 * Session access time is now updated right after session start.
 * Support for $CFG->sessionlockloggedinonly was removed.
 * First request does not update userid in sessions table.
 * The timeouts may break badly if server hosting forces PHP.ini session settings.
 * The session GC is a lot slower, we do not rely on external session timeouts.
 * There cannot be any hooks triggered at the session write time.
 * File and memcached handlers do not support session lock acquire timeouts.
 * Some low level PHP session functions can not be used directly in Moodle code.
2013-09-21 13:11:56 +02:00
Rajesh Taneja
2b503e40f2 MDL-31560 Messages: Deprecated generate_email_supportuser
generate_email_supportuser was not creating user which can
be used by messaging system. core_user::get_support_user()
should be used to get support_user record.
2013-09-13 16:13:26 +08:00
Sam Hemelryk
e145762b17 Merge branch 'MDL-40934-master' of git://github.com/FMCorz/moodle
Conflicts:
	auth/tests/auth_test.php
2013-08-06 14:37:43 +12:00
Frederic Massart
d95db915ed MDL-40934 core: Moving \core_auth\event\user_loggedin to \core 2013-07-30 16:41:20 +08:00
Mark Nelson
9b29f68648 MDL-27953 auth: introduced new function can_be_manually_set() to the authentication base class 2013-07-29 17:06:08 +08:00
Frederic Massart
3b086e3094 MDL-32746 core: Implement new user_loggedin event 2013-07-23 11:36:35 +08:00
Rajesh Taneja
d836e3ed1f MDL-16982 Administration: Integrated Inaki's suggestions 2013-06-11 10:27:43 +08:00
Rajesh Taneja
57d135a1c6 MDL-16982 Administration: Cleaned whitespaces and alignment in orignal patch 2013-06-11 10:27:43 +08:00
Petr Škoda
b28247fe90 MDL-21342 add user login lockout 2013-01-04 15:12:31 +01:00
Dan Poltawski
b217edd265 MDL-34685 authlib - fix trailing whitespace 2012-08-07 09:55:02 +08:00
Michael Aherne
57d38adc58 MDL-34685 auth Allow auth plugins to override user signup form 2012-08-07 09:55:02 +08:00
Petr Skoda
e2bb3c9275 MDL-32094 some more E_STRICT fixes 2012-03-18 20:40:20 +01:00
Petr Skoda
7415aed103 MDL-11728 finally defining the exact meaning of is_internal() in auth plugins
internal means "uses password hash for user authentication", there is a new is_synchronised_with_external() method that indicates if moodle should automatically sync user info with external system after login; I have also improved the default for prevent_local_passwords() which is now defaulting to !is_internal()
2010-11-14 02:01:59 +00:00
Petr Skoda
99f9f85f00 MDL-23489 auth plugins can specify own edit profile url - patch submitted by Jay Knight + tweaking change password url to use new moodle_url at the same time, it is backwards compatible, custom plugins may still use string url for now 2010-08-18 22:07:00 +00:00
Petr Skoda
78bfb562a0 MDL-21249 improved php docs and adding direct access prevention in core libs 2010-07-25 13:35:05 +00:00
Petr Skoda
640df5d0df more typos in comments fixed 2010-05-22 19:00:48 +00:00
Petr Skoda
370f10b7eb MDL-22061 converting auths to pluginname and deprecating old method for getting auth names
AMOS START
 MOV [auth_castitle,auth_cas],[pluginname,auth_cas]
 MOV [auth_dbtitle,auth_db],[pluginname,auth_db]
 MOV [auth_emailtitle,auth_email],[pluginname,auth_email]
 MOV [auth_fctitle,auth_fc],[pluginname,auth_fc]
 MOV [auth_imaptitle,auth_imap],[pluginname,auth_imap]
 MOV [auth_ldaptitle,auth_ldap],[pluginname,auth_ldap]
 MOV [auth_manualtitle,auth_manul],[pluginname,auth_manul]
 MOV [auth_mnettitle,auth_mnet],[pluginname,auth_mnet]
 MOV [auth_nntptitle,auth_nntp],[pluginname,auth_nntp]
 MOV [auth_nologintitle,auth_nologin],[pluginname,auth_nologin]
 MOV [auth_nonetitle,auth_none],[pluginname,auth_none]
 MOV [auth_pamtitle,auth_pam],[pluginname,auth_pam]
 MOV [auth_pop3title,auth_pop3],[pluginname,auth_pop3]
 MOV [auth_radiustitle,auth_radius],[pluginname,auth_radius]
 MOV [auth_shibbolethtitle,auth_shibboleth],[pluginname,auth_shibboleth]
 MOV [auth_webservicetitle,auth_webservice],[pluginname,auth_webservice]
AMOS END
2010-04-11 21:31:36 +00:00
Petr Skoda
37f005b142 MDL-22061 removing unnecessary [[ tests 2010-04-11 20:50:37 +00:00
Penny Leach
b257d7c411 mnet MDL-21278 print a list of potential idps on the login page with links
this adds a new contract auth plugin method (implemented as empty in the base class)
2010-02-18 01:30:13 +00:00
Penny Leach
d61ffb0fca auth base class MDL-21457 make the base class user_exists method argument list match reality 2010-01-28 05:12:04 +00:00
Petr Skoda
edb5da8331 MDL-20934 'not cached' flag used in all auth plugins that do not need the password 2009-11-23 21:50:40 +00:00
Petr Skoda
117bd74897 MDL-20700 coding style cleanup - cvs keywords removed, closign php tag removed, trailing whitespace cleanup 2009-11-01 11:31:16 +00:00
samhemelryk
72dbdcead7 authlib.php MDL-19236 added phpdocs and copyrights 2009-05-22 02:17:29 +00:00
jerome
2a274f2a93 authentication MDL-18273 Custom Authentication Plugin title can be retrieved from specific language file, merged from 19 2009-05-14 07:03:27 +00:00
skodak
e8656befac MDL-17942 more session refactoring 2009-01-18 18:00:44 +00:00
skodak
88fdd846f6 MDL-17942 fixed gc regressions, added gc after deleting users and similar cases 2009-01-18 12:20:55 +00:00
skodak
b9a6636029 MDL-14679 towards /admin conversion 2008-05-31 10:43:51 +00:00
skodak
5d910388bb MDL-14679 towards /user conversion 2008-05-30 22:11:31 +00:00
skodak
be544ec380 MDL-14679 towards authlib conversion 2008-05-30 20:54:19 +00:00
skodak
ae040d4bcc MDL-14679 finished moodlelib conversion 2008-05-30 19:59:50 +00:00
dongsheng
5891220d1f "MDL-15031, fix order of the user fields, see tracker, merged from MOODLE_19_STABLE" 2008-05-28 07:41:23 +00:00
dongsheng
7f2f55a0e1 "MDL-12405, add webpage to user fields, merged from MOODLE_19_STABLE" 2008-05-28 01:39:05 +00:00
dongsheng
2f137aa130 "MDL-14129, fix print_error" 2008-05-20 02:53:46 +00:00
dongsheng
4105cafff9 MDL-12531, make the new member value available to all the affected plugins, thanks, Robert 2008-04-08 05:53:12 +00:00
dongsheng
5a2a53316f MDL-14129, remove all the other error() call 2008-04-04 02:54:20 +00:00
dongsheng
6f87ef52b9 MDL-14055, change to human-readable strings from hard-coded integer, thanks for Matt's patch. 2008-03-26 01:35:04 +00:00