File modules/cms/auth/GuestAuth.class.php
Last commit: Sun Nov 29 21:46:57 2020 +0100 Jan Dankert Auth modules should only use the Auth::STATUS_* constants as return value.
1 <?php 2 3 namespace cms\auth; 4 5 use cms\auth\Auth; 6 use cms\base\Configuration; 7 8 /** 9 * Authentifizierung als Gast-User. 10 * 11 * Falls konfiguriert, wird der Gast-Benutzer voreingestellt. 12 * 13 * @author dankert 14 */ 15 class GuestAuth implements Auth 16 { 17 public function username() 18 { 19 $guestConf = Configuration::subset(['security','guest']); 20 21 if ($guestConf->is('enable',true)) 22 return $guestConf->get('user'); 23 else 24 return null; 25 } 26 27 28 /** 29 * Ueberpruefen des Kennwortes ist über Ident nicht möglich. 30 */ 31 public function login($user, $password, $token) 32 { 33 return Auth::STATUS_FAILED; 34 } 35 }
Downloadmodules/cms/auth/GuestAuth.class.php
History Sun, 29 Nov 2020 21:46:57 +0100 Jan Dankert Auth modules should only use the Auth::STATUS_* constants as return value. Sun, 1 Nov 2020 03:08:55 +0100 Jan Dankert Replaced the calls to "Configuration::rawConfig()" with the OO style calls; Cleanup LoginAction. Sat, 26 Sep 2020 10:32:02 +0200 Jan Dankert Refactoring: No global $conf array any more. Sun, 23 Feb 2020 04:49:34 +0100 Jan Dankert Refactoring with Namespaces for the cms modules, part 2. Sun, 23 Feb 2020 04:01:30 +0100 Jan Dankert Refactoring with Namespaces for the cms modules, part 1: moving.