class XnetSession
{
+ public function __construct()
+ {
+ self::init();
+ }
+
// {{{ function init
public static function init()
S::init();
+ if (!S::logged() && Get::has('auth')) {
+ XnetSession::doAuthX();
+ }
+
if (!S::logged()) {
// prevent connexion to be linked to deconnexion
if (($i = strpos($_SERVER['REQUEST_URI'], 'exit')) !== false)
public static function doAuthX()
{
- global $globals, $page;
+ global $globals;
if (md5('1'.S::v('challenge').$globals->xnet->secret.Get::i('uid').'1') != Get::v('auth')) {
Get::kill('auth');
- if (!$page) {
- require_once 'xnet.inc.php';
- new_skinned_page('platal/index.tpl');
- }
+ $page =& Platal::page();
$page->kill("Erreur d'authentification avec polytechnique.org !");
}