ccc
This commit is contained in:
@@ -1,20 +1,28 @@
|
||||
<?php
|
||||
|
||||
$key = $_GET("key");
|
||||
$type = $_GET("type");
|
||||
$value = $_GET("value");
|
||||
$userName = $_GET("username");
|
||||
$password = $_GET("password");
|
||||
$id = $username . $date->getTimestamp();
|
||||
|
||||
$
|
||||
$returnData = array();
|
||||
$date = new DateTime();
|
||||
|
||||
switch( $key ){
|
||||
case "validation":
|
||||
|
||||
break;
|
||||
case "create":
|
||||
|
||||
break;
|
||||
default:
|
||||
echo "false";
|
||||
$passwordSalt = "sexfamemoney$U046qKlL$moneyfamesex";
|
||||
|
||||
|
||||
$hashedPassword = crypt( $password, $passwordSalt );
|
||||
$hashedId = crypt( $id, $passwordSalt );
|
||||
|
||||
/*
|
||||
For login:
|
||||
if (hash_equals($hashed_password, crypt($user_input, $hashed_password))) {
|
||||
echo "Password verified!";
|
||||
}
|
||||
*/
|
||||
|
||||
$returnData["password"] = $hashed_password;
|
||||
$returnData["id"] = $hashedId;
|
||||
|
||||
echo( json_encode( $returnData ) );
|
||||
|
||||
?>
|
||||
Reference in New Issue
Block a user