Skip to content
Snippets Groups Projects
Commit 01adbd88 authored by Laurent's avatar Laurent
Browse files

hotline #87312 remove not used Skilleos file

parent 66cf2612
3 merge requests!3297WIP: Master,!3047Hotline,!3012Hotline#87312 des cles valides lekiosk sont dans le code source
- ticket #87312 : Des clés valides LeKiosk sont dans le code source!
\ No newline at end of file
<?php
/**
* Copyright (c) 2012-2014, Agence Française Informatique (AFI). All rights reserved.
*
* BOKEH is free software; you can redistribute it and/or modify
* it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE as published by
* the Free Software Foundation.
*
* There are special exceptions to the terms and conditions of the AGPL as it
* is applied to this software (see README file).
*
* BOKEH is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU AFFERO GENERAL PUBLIC LICENSE for more details.
*
* You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE
* along with BOKEH; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
class Skilleos_Link extends Skilleos_LinkAbstract {
const ROOT_URL = 'http://skilleos.com/sigb/sso/';
protected $_mail;
protected $_base_url;
public function __construct($mail) {
$this->_mail = ($mail) ? $mail : Class_Profil::getPortail()->getMailSiteOrPortail();
}
public function url($album = null) {
$url = static::ROOT_URL
. $this->baseUrl()
. '&AccessHash=' . $this->accessHash();
if (!$album)
return $url;
return $url . '&ReturnUrl=' . $this->_getReturnURL($album);
}
protected function accessHash() {
return sha1($this->baseUrl() . static::SHA1_KEY);
}
protected function baseUrl() {
if (null === $this->_base_url)
$this->_base_url = static::BASE_URL
. 'id_resource=' . $this->cryptedMail()
. '&id=' . Skilleos_Config::getInstance()->getAdminVar('ID')
;
return $this->_base_url;
}
protected function cryptedMail() {
return bin2hex(openssl_encrypt($this->_mail, 'aes-128-cbc', static::AES_KEY, true, static::AES_KEY));
}
}
?>
\ No newline at end of file
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment