privileges.rst.txt 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. User management
  2. ===============
  3. User management is the process of controlling which users are allowed to
  4. connect to the MySQL server and what permissions they have on each database.
  5. phpMyAdmin does not handle user management, rather it passes the username and
  6. password on to MySQL, which then determines whether a user is permitted to
  7. perform a particular action. Within phpMyAdmin, administrators have full
  8. control over creating users, viewing and editing privileges for existing users,
  9. and removing users.
  10. Within phpMyAdmin, user management is controlled via the :guilabel:`Users` link
  11. from the main page. Users can be created, edited, and removed.
  12. Creating a new user
  13. -------------------
  14. To create a new user, click the :guilabel:`Add a new user` link near the bottom
  15. of the :guilabel:`Users` page (you must be a "superuser", e.g., user "root").
  16. Use the textboxes and drop-downs to configure the user to your particular
  17. needs. You can then select whether to create a database for that user and grant
  18. specific global privileges. Once you've created the user (by clicking Go), you
  19. can define that user's permissions on a specific database (don't grant global
  20. privileges in that case). In general, users do not need any global privileges
  21. (other than USAGE), only permissions for their specific database.
  22. Editing an existing user
  23. ------------------------
  24. To edit an existing user, simply click the pencil icon to the right of that
  25. user in the :guilabel:`Users` page. You can then edit their global- and
  26. database-specific privileges, change their password, or even copy those
  27. privileges to a new user.
  28. Deleting a user
  29. ---------------
  30. From the :guilabel:`Users` page, check the checkbox for the user you wish to
  31. remove, select whether or not to also remove any databases of the same name (if
  32. they exist), and click Go.
  33. Assigning privileges to user for a specific database
  34. ----------------------------------------------------
  35. Users are assigned to databases by editing the user record (from the
  36. :guilabel:`User accounts` link on the home page).
  37. If you are creating a user specifically for a given table
  38. you will have to create the user first (with no global privileges) and then go
  39. back and edit that user to add the table and privileges for the individual
  40. table.
  41. .. _configurablemenus:
  42. Configurable menus and user groups
  43. ----------------------------------
  44. By enabling :config:option:`$cfg['Servers'][$i]['usergroups']` and
  45. :config:option:`$cfg['Servers'][$i]['usergroups']` you can customize what users
  46. will see in the phpMyAdmin navigation.
  47. .. warning::
  48. This feature only limits what a user sees, he is still able to use all the
  49. functions. So this can not be considered as a security limitation. Should
  50. you want to limit what users can do, use MySQL privileges to achieve that.
  51. With this feature enabled, the :guilabel:`User accounts` management interface gains
  52. a second tab for managing :guilabel:`User groups`, where you can define what each
  53. group will view (see image below) and you can then assign each user to one of
  54. these groups. Users will be presented with a simplified user interface, which might be
  55. useful for inexperienced users who could be overwhelmed by all the features
  56. phpMyAdmin provides.
  57. .. image:: images/usergroups.png