Use GitHub user ids instead of usernames for authentication
Otherwise, renaming a GitHub account could allow someone else to gain access to a CDB account.
This commit is contained in:
@@ -144,6 +144,7 @@ class User(db.Model, UserMixin):
|
||||
|
||||
# Account linking
|
||||
github_username = db.Column(db.String(50, collation="NOCASE"), nullable=True, unique=True)
|
||||
github_user_id = db.Column(db.Integer, nullable=True, unique=True)
|
||||
forums_username = db.Column(db.String(50, collation="NOCASE"), nullable=True, unique=True)
|
||||
|
||||
# Access token for webhook setup
|
||||
|
||||
Reference in New Issue
Block a user