Как посмотреть пароль на почтовый ящик в Plesk?

Поскольку клиенты хостинга часто забывчивы и рассеяны, довольно часто требуется узнать какой именно пароль установлен на почтовый ящик клиента. Если ваша панель управления хостингом называется Plesk, то с большой долей вероятности, все пароли от почтовых ящиков хранятся в обычном текстовом виде, внутри MySQL базы даных с именем psa.
В этом случае, вы можете воспользоваться утилитой командной строки mysql и выполнить запрос на получение пароля:
# mysql -u admin --password=`cat /etc/psa/.psa.shadow` psa
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 202860560
Server version: 5.0.95-log Source distribution
Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> SELECT CONCAT_WS('@',mail.mail_name,domains.name),accounts.id,accounts.password FROM domains,mail,accounts WHERE domains.id=mail.dom_id AND accounts.id=mail.account_id AND domains.name='mydomain.ru';
+--------------------------------------------+----+--------------+
| CONCAT_WS('@',mail.mail_name,domains.name) | id | password |
+--------------------------------------------+----+--------------+
| admin@mydomain.ru | 56 | 34koko-32mdV |
| postmaster@mydomain.ru | 49 | qwe12345QWE |
+--------------------------------------------+----+--------------+
3 rows in set (0.00 sec)
В данном примере мы можем просмотреть пароли на все ящики домена mydomain.ru, который вы можете заменить на нужный вам домен.
- Войдите на сайт для отправки комментариев
- 1438 просмотров