示例#1
0
 /**
  * permet de decrypter des données crypté par la function crypt
  *
  * @param string $data
  * @return string
  */
 function decrypt($data)
 {
     return Security::decrypt($data);
 }
示例#2
0
 /**
  * remove, supprime une entrée dans la table
  *
  * @param string $key
  *
  * @return self
  */
 public static function remove($key)
 {
     $old = null;
     if (static::has($key)) {
         if (!static::$isDecrypt[$key]) {
             $old = Security::decrypt($_COOKIE[$key]);
             unset(static::$isDecrypt[$key]);
         }
         static::add($key, null, -1000);
         unset($_COOKIE[$key]);
     }
     return $old;
 }