algorithm - Password storing in 2017 -


so i'm working on own website login system. working on password storing part , have been looking @ couple of youtube videos peoples tell me not use things md5 because it's outdated.

i looked @ video tom scott made how not store passwords , told recent tutorial on how properly.

for project need store passwords myself , not use facebook or google logins.

i looked @ lot of websites , questions here on stack overflow can't seem find year explained.

so i'm wondering best way in 2017 store passwords? need use salt , pepper? maybe else? , hashing algorithm best @ moment? if possible i'd use within php.

can me out these questions?

thank :)

i assume want store passwords user authentication, , asked php solution explicitely, answer must use php function password_hash(). function date , handles tricky parts of password hashing.

// hash new password storing in database. // function automatically generates cryptographically safe salt. $hashtostoreindb = password_hash($password, password_default);  // check if hash of entered login password, matches stored hash. // salt , cost factor extracted $existinghashfromdb. $ispasswordcorrect = password_verify($password, $existinghashfromdb); 

if interested in more indept information, have @ tutorial safely storing passwords.


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

ios - Change Storyboard View using Seague -