Exemplo n.º 1
0
 public static function initialize()
 {
     global $config;
     if (!in_array('mcrypt', get_loaded_extensions())) {
         throw new \Exception('The PHP mcrypt extension is not installed');
     }
     if ((self::$resTd = mcrypt_module_open("rijndael-256", '', "cfb", '')) == false) {
         throw new \Exception('Error initializing encryption module');
     }
     self::$clesCryptage = $config["encryptKey"];
 }