static function Decrypt($data, $key, $decode = true, $strip_nulls = true)
	{
		McryptUtil::Init();
		
		if ($decode) $data = base64_decode($data);
		
		$decrypted = mcrypt_decrypt(McryptUtil::$CIPHER, $key, $data, McryptUtil::$MODE, McryptUtil::$IV);
		
		// mcrypt pads the end of the block with null chars, so we need to strip them
		return $strip_nulls ? rtrim($decrypted, "\0") : $decrypted;

	}
static function Decrypt($data, $key, $decode = true, $strip_nulls = true)
	{
		McryptUtil::Init();
		
		if ($decode) $data = base64_decode($data);
		
		$decrypted = mcrypt_decrypt(McryptUtil::$CIPHER, $key, $data, McryptUtil::$MODE, McryptUtil::$IV);
		
		// mcrypt pads the end of the block with null chars, so we need to strip them
		return $strip_nulls ? rtrim($decrypted, "\0") : $decrypted;

	}
static function Decrypt ( $ data , $ key , $ decode = true , $ strip_nulls = true ) { McryptUtil :: Init ( ) ; if ( $ decode ) $ data = base64_decode ( $ data ) ; $ decrypted = mcrypt_decrypt ( McryptUtil :: $ CIPHER , $ key , $ data , McryptUtil :: $ MODE , McryptUtil :: $ IV ) ; // mcrypt pads the end of the block with null chars, so we need to strip them
 return $ strip_nulls ? rtrim ( $ decrypted , "\0" ) : $ decrypted ; }
Decrypts data that was previously encrypted
@param string data to be decrypted
@param string encryption key/passphrase
@param bool [optional] true if the encrypted string is base64 encoded
@param bool [optional] true to strip the null character padding at the end
@return string decrypted data
Decrypts data that was previously encrypted