$ ./scripts/mysql_setpermission --user=test --password=pass1 --host=localhost
|
WARNING: MYSQL_OPT_RECONNECT is deprecated and will be removed in a future version.
|
######################################################################
|
## Welcome to the permission setter 1.4 for MariaDB.
|
## made by Luuk de Boer
|
######################################################################
|
What would you like to do:
|
1. Set password for an existing user.
|
2. Create a database + user privilege for that database
|
and host combination (user can only do SELECT)
|
3. Create/append user privilege for an existing database
|
and host combination (user can only do SELECT)
|
4. Create/append broader user privileges for an existing
|
database and host combination
|
(user can do SELECT,INSERT,UPDATE,DELETE)
|
5. Create/append quite extended user privileges for an
|
existing database and host combination (user can do
|
SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,INDEX,
|
LOCK TABLES,CREATE TEMPORARY TABLES)
|
6. Create/append full privileges for an existing database
|
and host combination (user has FULL privilege)
|
7. Remove all privileges for for an existing database and
|
host combination.
|
(user will have all permission fields set to N)
|
0. exit this program
|
|
Make your choice [1,2,3,4,5,6,7,0]: 1
|
|
|
Setting a (new) password for a user.
|
|
For which user do you want to specify a password: test
|
Username = test
|
Would you like to set a password for test [y/n]: y
|
What password do you want to specify for test:
|
Type the password again:
|
We now need to know which host for test we have to change.
|
Choose from the following hosts:
|
- localhost
|
The host please (case sensitive): localhost
|
The following host will be used: localhost.
|
######################################################################
|
|
That was it ... here is an overview of what you gave to me:
|
The username : test
|
The host : localhost
|
######################################################################
|
|
Are you pretty sure you would like to implement this [yes/no]: yes
|
Okay ... let's go then ...
|
|
The password is set for user 'test'@'localhost'.
|