Oppaitime's version of Gazelle
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

database_key.php 829B

1234567891011121314151617181920212223242526272829
  1. <?
  2. if (!check_perms('site_debug')) {
  3. error(403);
  4. }
  5. if (isset($_POST['dbkey'])) {
  6. authorize();
  7. apc_store('DBKEY', hash('sha512', $_POST['dbkey']));
  8. }
  9. View::show_header('Database Encryption Key');
  10. ?>
  11. <div class="header">
  12. <h2>Database Encryption Key</h2>
  13. </div>
  14. <div class="box pad slight_margin">
  15. <h4>There is <?=((apc_exists('DBKEY') && apc_fetch('DBKEY'))?"already a":"NO")?> key loaded</h4>
  16. <form class="create_form" name="db_key" action="" method="post">
  17. <input type="hidden" name="action" value="database_key" />
  18. <input type="hidden" name="auth" value="<?=$LoggedUser['AuthKey']?>" />
  19. <div style="display: flex;">
  20. <input type="text" name="dbkey" style="flex-grow: 1;" />
  21. <input type="submit" name="submit" value="Update key" />
  22. </div>
  23. </form>
  24. </div>
  25. <? View::show_footer(); ?>