0

I want to create a database for user-account-Management.

I want the user to save his username and optionally his password in a database. Only the user itself should see the data in realtext on the website.

If User 1 type in passwort 123456 the encryptet string for user 1 is o92f2323 for example. If User 2 type in passwort 123456 too the encryptet string for user 2 is 0r90fg2f3.

So every encryption is user-specified. I dont know what i should look for. Can you please tell me some tags that i should look for to work with.

Thank you in advance!

PasiB
  • 97
  • 9
  • passwords should not be decryptable. You should be using `password_hash()`. http://php.net/manual/en/function.password-hash.php – Funk Forty Niner May 27 '17 at 12:34
  • Yes i know. But the password isnt for the login of the website. It is data for an external Programm. Users should input their data so they can watch them. For the register an login for my website, which include the Account-Management I use password_hash of course. :) – PasiB May 27 '17 at 12:39
  • I want that even I couldn't whatch the User-Data in de DB in cleartext. Only the frontent which encode the cryptet data in the Database should display the user-saved data. :) You know what i mean? Sorry my english isn't very well... – PasiB May 27 '17 at 12:42
  • Ok, Then you can use password_hash() . and password_verify() to check the password. – Adharsh M May 27 '17 at 12:42
  • See this Q&A then https://stackoverflow.com/questions/1289061/best-way-to-use-php-to-encrypt-and-decrypt-passwords and the linked duplicate https://stackoverflow.com/questions/5089841/two-way-encryption-i-need-to-store-passwords-that-can-be-retrieved – Funk Forty Niner May 27 '17 at 12:43
  • If those ^ answer your question (which I think it does), let me know and I mark the question as a duplicate. – Funk Forty Niner May 27 '17 at 12:45
  • @PasiB I am waiting on an answer. Do those links answer what you asked, yes or no? Ping me back as I did for you here with the @ symbol. – Funk Forty Niner May 27 '17 at 12:50
  • Yes it is my answer, thank you! @Fried – PasiB May 27 '17 at 12:55

0 Answers0