| <?php | |
| $key = '[[ KEY ]]'; | |
| $userData = [ | |
| 'avatarURL' => $user->avatarURL, | |
| 'email' => $user->email, | |
| 'id' => $user->id, | |
| 'name' => $user->name | |
| ]); | |
| $token = bin2hex(openssl_encrypt(json_encode($data), 'AES-128-ECB', md5($key, true), OPENSSL_RAW_DATA)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment