Skip to content

Instantly share code, notes, and snippets.

@simong
Last active August 29, 2015 14:17
Show Gist options
  • Select an option

  • Save simong/361c1b97e7d03ba08bd8 to your computer and use it in GitHub Desktop.

Select an option

Save simong/361c1b97e7d03ba08bd8 to your computer and use it in GitHub Desktop.
Email verification

Scenarios that touch upon email verification

  1. A user creates a new local user account
  2. A users comes in through SSO but has no email attribute
  3. A user updates his own email address
  4. Someone invites a guest via an email address
  5. ?

Some background around inviting guests

When a guest gets invited for the first time, we will create a user account for it. Most likely we will create the email2user mapping so people can keep sharing content with the guest whilst there's no user behind it yet

# Some scenarios to think about

Hijacking an account

  1. Jack shares confidential.content with the.cio@academia.edu
  2. This creates a mapping between the.cio@academia.edu but the link is still unverified
  3. Jack shares content2 with the.cio@academia.edu
    1. This adds content2 to the library of the existing guest user
  4. Alice (NOT THE CIO) signs in through SSO and no email attribute is released
    1. Because there's no email address available, we cannot create a user account
    2. Alice is asked to enter an email address and she fills in the.cio@academia.edu
    3. We can't link up the accounts just yet as otherwise Alice might get access to the confidential content
    4. To counter this, we send a "please verify your email" to the.cio@academia.edu (with all the information to update the guest account)

Hijacking a potential account

  1. The CIO has no account (and hasn't been invited yet either)
  2. Alice signs in through SSO but no email attribute is released
    1. Because there's no email address available, we cannot create a user account
    2. Alice is asked to enter an email address and she fills in the.cio@academia.edu
    3. Even though there's no email present, we can't create the account as we cannot trust Alice
    4. We send a "please verify your email" to the.cio@academia.edu (with all the information to create the user account in case Alice is the CIO)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment