![]() |
|
Think about Loose Coupling | |
PerlMonks |
Is this script safe?by mt2k (Hermit) |
on May 25, 2001 at 04:11 UTC ( #83179=perlquestion: print w/replies, xml ) | Need Help?? |
mt2k has asked for the wisdom of the Perl Monks concerning the following question:
I want to allow anyone to log into my account on a server. To accomplish this, I would have an account with a simple password. Then, in the .bash_profile file, I'd have this line:
The login.pl file would hold the following code:
The .admin file looks something like this:
To sum it up, if the user does not enter the first correct password, it allows the user to only use lynx. The reason for the encrypted passwords is because anyone can look at the source of the script using lynx... Just pressing "g -> /home/user/login.pl" allows them to do so. I added the while loop in there so that if after the first password is entered correctly, the user has no idea whether or not the next 4 passwords are right! (Of course, this sucks for me if I enter one wrong!) The question is, anyone can also view the .admin file... Is 5 passwords enough (they are all VERY different in style and length). All I want to know is, do I risk any danger with this method of protection if I change the 5 passwords every week?
Back to
Seekers of Perl Wisdom
|
|