Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Password Protect Plugin for GS
#4
(2016-03-14, 00:36:43)Bigin Wrote: You should never keep unhashed passwords in database/files

instead of



Code:
$note->addCData($password);

at very least use:



Code:
$xml->addChild('password', sha1($password.$a_random_salt));
$xml->addChild(‘salt‘, $a_random_salt);

addCData not required in this case.

Or even better, use PHP function specially intended for that:
http://php.net/manual/en/function.password-hash.php

regards


Yes, In ordinary circumstances it is true that you should never store passwords in cleartext as I have done, but in this case it does not need to be encrypted or hashed due to the following reasons:
  • The password is supposed to be displayed in the page edit area. (Main reason why it is plain text)
  • It is only view-able to admins.
  • If someone gains access to your server (ftp, ssh or otherwise) you have bigger problems than a plaintext password protected page.
  • The password is specific to only the page it is applied on, knowing this password does not give you any further privileges into the system.
However, feel free to come up with an alternative solution.

(2016-03-13, 23:31:18)Charpy1 Wrote: Great idea!

I did a french lang file (http://get-simple.info/extend/plugin-lan...ugin/1023/ ), you may include it if you want.

Hmmm.. You are saving the password in clear text, aren't you?

Thanks!
I have included the translation in GitHub, will put it out into extend soon.
Web Developer
Plugins: GS Plugin Installer | Referrer Blocker | Password Protect
Reply


Messages In This Thread
Password Protect Plugin for GS - by HelgeSverre - 2016-03-13, 21:37:39
RE: Password Protect Plugin for GS - by Charpy1 - 2016-03-13, 23:31:18
RE: Password Protect Plugin for GS - by Bigin - 2016-03-14, 00:36:43
RE: Password Protect Plugin for GS - by HelgeSverre - 2016-03-14, 04:53:44
RE: Password Protect Plugin for GS - by Bigin - 2016-03-14, 05:25:35
RE: Password Protect Plugin for GS - by Charpy1 - 2016-03-14, 06:15:22
RE: Password Protect Plugin for GS - by shawn_a - 2016-03-14, 07:22:44
RE: Password Protect Plugin for GS - by Bigin - 2016-03-14, 18:17:27
RE: Password Protect Plugin for GS - by Charpy1 - 2016-03-14, 08:38:00
RE: Password Protect Plugin for GS - by carpman - 2016-03-20, 08:25:19
RE: Password Protect Plugin for GS - by nicolap - 2016-04-04, 23:55:06
RE: Password Protect Plugin for GS - by nicolap - 2016-04-05, 00:10:47
RE: Password Protect Plugin for GS - by shawn_a - 2016-04-05, 06:37:49
RE: Password Protect Plugin for GS - by nicolap - 2016-04-07, 05:56:59
RE: Password Protect Plugin for GS - by nicolap - 2016-04-07, 23:18:56
RE: Password Protect Plugin for GS - by shawn_a - 2016-04-08, 05:44:03
RE: Password Protect Plugin for GS - by mengi - 2016-04-15, 12:33:54
RE: Password Protect Plugin for GS - by Carlos - 2016-04-21, 23:13:25
RE: Password Protect Plugin for GS - by shawn_a - 2016-04-21, 23:19:58
RE: Password Protect Plugin for GS - by gs-gary - 2019-12-07, 22:14:51



Users browsing this thread: 1 Guest(s)