• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Advanced Password Generator

G

GARMTECH

Guest
Here's one script that I wrote some time before. Maybe it can be useful for someone.

Advanced Password Generator v1.0

It's not highly "admin-friendly" script and you need to make some things in your cp to install it:
0. Login to ssh as root. And then
# cd ~/
1. Let's download file from www.garmtech.lv:
(for Linux)
# wget http://www.garmtech.lv/web/generator.php.txt
(for FreeBSD)
# fetch http://www.garmtech.lv/web/generator.php.txt
2. Move file to plesk directory:
# mv ~/generator.php.txt /usr/local/psa/admin/htdocs/
3. Login to Plesk as admin and go to Server > Custom buttons > Add New Button:
Button label: Password Generator
Location: Domain administration page
Priority: 100
Background image: (you can download one from http://www.sw-soft.com/r/upload/image006.gif and choose it here)
URL: https://YOUR_PANEL_LOGIN_ADDRESS:8443/generator.php
Include domain name - checked
Include client id - checked
Include client's contact name - checked
Context help tip contents: something like - Let you generate secure passwords for your hosting and mailboxes.
Open URL in the Control Panel - checked
Visible to all sub-logins - checked

If you have any questions feel free to ask. It's open-source, so you can feel free to redistribute it in any way, just please leave a note about origin.
 
Hi GARMTECH,
today I found your PW-Generator and its just what I was searching for! Many thanx.
I have one question (im not a PHP-pro):
Is it possible to turn of special-characters like & and % so that there are only letters and digits? Perhaps an option to select if this is wanted or not...
Would be a great thing!
Greetings,
ProfiTiger
 
Looks like all you would need to do (and please correct me Garmtech, if I am wrong) is to remove the special characters in the $salt definition near the top of the file.
 
Yes, totally rright :)

change "$salt.." string to

PHP:
$salt = "QAZWSXEDCqazwsxedc0123456789";
 
Thanx for your help :)
I had a little trouble after removing the characters from $alt and adding a few more letters because the numbers were not used anymore... I changed $num=rand() % 33 to the exact count of letters and numbers i use in $alt then it worked again fine. Hope this was correct....
Does the script use the values of domain, Id and so on use just for the layout (skinning)?
Greetings and tnx again,
ProfiTiger
 
Hi GARMTECH,

a little expansion for your installation guide:
-> rename generator.php.txt to generator.php....

I searched some time to fix this (as newbie.. :rolleyes:)

Greetings,
ProfiTiger
 
Back
Top