| 1 |
install plugin pam soname 'auth_pam_v1.so'; |
| 2 |
create user test_pam identified via pam using 'mariadb_mtr'; |
| 3 |
grant all on test.* to test_pam; |
| 4 |
create user pam_test; |
| 5 |
grant all on test.* to pam_test; |
| 6 |
grant proxy on pam_test to test_pam; |
| 7 |
# |
| 8 |
# athentication is successful, challenge/pin are ok |
| 9 |
# note that current_user() differs from user() |
| 10 |
# |
| 11 |
Challenge input first. |
| 12 |
Enter: ************************* |
| 13 |
Now, the magic number! |
| 14 |
PIN: 9225 |
| 15 |
select user(), current_user(), database(); |
| 16 |
user() current_user() database() |
| 17 |
test_pam@localhost pam_test@% test |
| 18 |
# |
| 19 |
# athentication is unsuccessful |
| 20 |
# |
| 21 |
Challenge input first. |
| 22 |
Enter: ************************* |
| 23 |
Now, the magic number! |
| 24 |
PIN: 9224 |
| 25 |
# |
| 26 |
# athentication is successful |
| 27 |
# |
| 28 |
Now, the magic number! |
| 29 |
PIN: 9212 |
| 30 |
select user(), current_user(), database(); |
| 31 |
user() current_user() database() |
| 32 |
test_pam@localhost pam_test@% test |
| 33 |
# |
| 34 |
# athentication is unsuccessful |
| 35 |
# |
| 36 |
Now, the magic number! |
| 37 |
PIN: 9212 |
| 38 |
drop user test_pam; |
| 39 |
drop user pam_test; |
| 40 |
uninstall plugin pam; |