Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

How to get user algorith, user password hash value

Asked Modified Viewed 3,498 times
S
SGT-TURKEY
S
.:: We have success the difficult, impossible that is just takes time ::.
  • Junior Member, joined since
  • Contributed 16 posts on the community forums.
  • Started 8 threads in the forums
  • Started this discussions
asked
Junior Member

Hi everybody. I'm working hard v7

I'm working hard to manuel member registration with new bootstrap form. How to get user salt, user algoritm values...
For example


<form name='userregisterform' method='POST' action='actionurl'>
    <input type='text' name='username' value=''>
    <input type='text' name='userpassword' value=''>
    <input type='text' name='userpasswordagain' value=''>
    <input type='text' name='usermail' value=''>
    ... other user fields inputs ....
    <input type=submit' name='saveuser' value='SAVE USER'>
</form>


my php codes :

if(isset($_POST["saveuser"])){
   $username=$_POST["username"];
   $userpassword=$_POST["userpassword"];
   $userpasswordagain=$_POST["userpasswordagain"];
   $usermail=$_POST["usermail"];
  $other user input values...

}


I want to get how to make user_salt values, user_passwords hash values.??

For Example :

user_salt = da7486536bcb437f91a901bdbea718e0b465c80b
user_password = b56b6ba5f2f6baa941b1333c4991bcb39897e737e1fd5c518575687b6084d59a

How to translate input value to password hash values..

Sorry my bad english...
0 replies

3 posts

N
NetriX
N
NetriX 10
Need help? Having trouble?
» View our Documentation for guides, functions and more - including the Getting Started section!
» Attach Log Files and Screenshots when reporting issues
» My support days are usually Mon-Thurs. Send me a PM if urgent.
  • Senior Member, joined since
  • Contributed 566 posts on the community forums.
  • Started 93 threads in the forums
answered
Senior Member

Try this...

$salt = sha1($_POST['userpassword'], substr($_POST['userpassword'], 12));
$password = hash_hmac('sha256', $_POST['userpassword'], $salt);
0 replies
— 3 months later —
T
tjakob
T
tjakob 10
  • Newbie, joined since
  • Contributed 9 posts on the community forums.
  • Started 3 threads in the forums
answered
Newbie

I connect to the topic :)
I have the same problem, I want to perform user registration from another form, how is the salt generated in PHPFusion 7, the example given by Netrix does not solve the problem. The password saved with this salt is not valid at logon.
I will be very grateful to everyone for their help.
0 replies
S
SGT-TURKEY
S
.:: We have success the difficult, impossible that is just takes time ::.
  • Junior Member, joined since
  • Contributed 16 posts on the community forums.
  • Started 8 threads in the forums
  • Started this discussions
answered
Junior Member

Hi again, please help me..


      $user_password=stripinput($_POST["user_password"]);
      
      echo "Old Salt : ". $userdata["user_salt"]."<br>";
      echo "Old Password : ". $userdata["user_password"]."<hr>";

      
      $salt=sha1($user_password, substr($user_password, 12));
      echo "New Salt : ".$salt."<br>";
      echo "New Password : ".hash_hmac('sha256', $user_password, $salt);


Result

Old Salt : 9ba0bf9b44f35cdf04c7189e566802cda3d0f129
Old Password : ccf6b2bbd9f8d9b6ea171009e079c59f31b4513449f8f6228961f86c3373c9f7



New Salt : 7d1573c10e751512202bea4f0fc273d44b909c18
New Password : 4d6c985138e845009377dd31acab86d81b41a24489c1c9d9603eeab24bd0e899


the results are not the same
0 replies

Labels

None yet

Statistics

  • Views 0 views
  • Posts 3 posts
  • Votes 0 votes
  • Topic users 3 members

3 participants

N
N
NetriX 10
Need help? Having trouble?
» View our Documentation for guides, functions and more - including the Getting Started section!
» Attach Log Files and Screenshots when reporting issues
» My support days are usually Mon-Thurs. Send me a PM if urgent.
  • Senior Member, joined since
  • Contributed 566 posts on the community forums.
  • Started 93 threads in the forums
T
T
tjakob 10
  • Newbie, joined since
  • Contributed 9 posts on the community forums.
  • Started 3 threads in the forums
S
S
.:: We have success the difficult, impossible that is just takes time ::.
  • Junior Member, joined since
  • Contributed 16 posts on the community forums.
  • Started 8 threads in the forums
  • Started this discussions

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet