21.6 Creating Accounts
Creating a User account is easily the most difficult and complicated part of this chapter. When we create a new User, we want to check that the email address supplied by the user is valid. We therefore create a disabled User and send the user an email to confirm the existence of his or her email account. This email contains a link to an activation webpage, which when accessed enables the User. To make sure that this process works securely, we use a cryptographic hash in the URL pattern of the activation page.
If this process sounds familiar, it’s because it is: we are effectively re-creating the password reset system but for the purpose of creating a new user. The key difference is that we need the ability to resend an ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access