Questo sito utilizza cookies solo per scopi di autenticazione sul sito e nient'altro. Nessuna informazione personale viene tracciata. Leggi l'informativa sui cookies.
Username: Password: oppure
Blowfish Tester

Blowfish Tester

  1. <?php
  2.   require_once('blowfish.php');
  3.   switch ($_POST['action']){
  4.       case 'decript':
  5.           $output = PMA_blowfish_decrypt($_REQUEST['text'],$_REQUEST['key']);
  6.           break;
  7.       case 'crypt':
  8.           $output = PMA_blowfish_encrypt($_REQUEST['text'],$_REQUEST['key']);
  9.           break;
  10.   }
  11.  
  12.   $output = blowfish_encrypt('come stai','166ac015a7c6aaaa');
  13. ?>
  14. <h2>Decrypt</h2>
  15. <form action="" method="post">
  16.     Key: <input type="text" name="key" value="166ac015a7c6aaaa"><br />
  17.     Textarea: <br />
  18.     <textarea name="text" cols="55" rows="15"></textarea><br />
  19.     <input type="hidden" value="decript" name="action" /><br />
  20.     <input type="submit" value="submit" />
  21. </form>
  22.  
  23. <h2>Crypt</h2>
  24. <form action="" method="post">
  25.     Key: <input type="text" name="key" value="166ac015a7c6aaaa"><br />
  26.     Textarea: <br />
  27.     <textarea name="text" cols="55" rows="15"></textarea><br />
  28.     <input type="hidden" value="crypt" name="action" /><br />
  29.     <input type="submit" value="submit" />
  30. </form>
  31.  
  32. <textarea cols="40" rows="25"><?= $output ?></textarea>