æåã«æ±ºãã¦ããã㨠以ä¸ã®æ å ±ã¯æå·åã«ããã¦ã復å·ã«ããã¦ãå¿ è¦ã«ãªããå ¨ã¦ãä¸è´ããªããã°å¾©å·ã¯ã§ããªãã éµï¼ä»¥ä¸ KEYï¼ æå·ã¢ã«ã´ãªãºã ï¼ä»¥ä¸ CIPHERï¼ â¦ (1) ãããã¯æå·ã®ã¢ã¼ãï¼ä»¥ä¸ MODEï¼â¦ (2) æå·å KEY, CIPHER, MODE ãç¨ãã¦ã¡ãã»ã¼ã¸ $msg ãæå·åããé¢æ° encrypt ã¯æ¬¡ã®ããã«ãªãï¼ããã¨åé·ãªæ¸ãæ¹ããã¦ããï¼ã function encrypt($msg) { //åæåãã¯ãã«ãçæ $ivSize = mcrypt_get_iv_size(CIPHER, MODE); $iv = mcrypt_create_iv($ivSize, MCRYPT_DEV_URANDOM); $dummyIV = str_repeat("x", $ivSize); //ã¡ãã»ã¼ã¸ã®æå·å ... (3) $cryptMsg
{{#tags}}- {{label}}
{{/tags}}