I'd like to revive this one:
Right now, is it possible to create a new account with an email that already exists in the database?
If username can be changed, we need to apply the changes to the content items that have it as owner.
I think what @sebastienros means is that the Owner should be kept for history but we should also have an immutable ID to identify the real Owner instead. That way, no need to change the Owner when the username is changed. This also means that permissions should be then checked against that new immutable ID.
The identifier of a user account should not be editable
The identifier of a user account should be random, and not entered by a user
To prevent accounts from being impersonated in case an identifier was leaked. So even at the time of the creation of an account, the identifier should be computer generated, or have a part that is computer generated.
The identifier should be normalized such that its usage is case insensitive, and any attempt to use a different case will match an existing account. For instance all values should be stored and looked up with a defined char case.
Implications
Most helpful comment
The identifier of a user account should not be editable
The identifier of a user account should be random, and not entered by a user
To prevent accounts from being impersonated in case an identifier was leaked. So even at the time of the creation of an account, the identifier should be computer generated, or have a part that is computer generated.
The identifier should be normalized such that its usage is case insensitive, and any attempt to use a different case will match an existing account. For instance all values should be stored and looked up with a defined char case.
Implications