AuthenticationPlugin.class.php 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. <?php
  2. /* vim: set expandtab sw=4 ts=4 sts=4: */
  3. /**
  4. * Abstract class for the authentication plugins
  5. *
  6. * @package PhpMyAdmin
  7. */
  8. if (! defined('PHPMYADMIN')) {
  9. exit;
  10. }
  11. /* This class extends the PluginObserver class */
  12. require_once 'PluginObserver.class.php';
  13. /**
  14. * Provides a common interface that will have to be implemented by all of the
  15. * authentication plugins.
  16. *
  17. * @package PhpMyAdmin
  18. */
  19. abstract class AuthenticationPlugin extends PluginObserver
  20. {
  21. /**
  22. * Displays authentication form
  23. *
  24. * @return boolean
  25. */
  26. abstract public function auth();
  27. /**
  28. * Gets advanced authentication settings
  29. *
  30. * @return boolean
  31. */
  32. abstract public function authCheck();
  33. /**
  34. * Set the user and password after last checkings if required
  35. *
  36. * @return boolean
  37. */
  38. abstract public function authSetUser();
  39. /**
  40. * User is not allowed to login to MySQL -> authentication failed
  41. *
  42. * @return boolean
  43. */
  44. abstract public function authFails();
  45. }
  46. ?>