Comments (1)
I just talked to someone about this and thought I'd see if this is still the case :)
Solution:
Convert email adress to lowercase and strip trailing and leading spaces. Don't forget to update the database - in case someone actually has used uppercase letters or spaces in his registration.
Unfortunately, this solution isn't quite this simple. The reason is, that there are people who have multiple accounts, with different capitalization (because they tried logging in from a different browser, their account couldn't be found and they decided to re-register). You can't simply merge them, because there will be merge conflicts.
So, lower-casing everything in the database is not possible (as that would create multiple accounts with the same E-Mail Address) and lower-casing on registration and login is not possible (as that would disallow logging into an account with upper-case letters).
A fix would be, to insert accounts always lowercased and search always case-insensitive. You can then handle on the application layer what to do. On registration, you can search case-insensitively whether that account exist and refuse if any case-variant already does. On login, you search case-insensitively and if there is exactly one match, you treat them as equal and try to log in that one. If there is more than one match, you treat them as different and look for one with that exact casing. You can also show warnings if conflicts are shown.
Of course, this requires some application-level code, but it should be manageable. You can opt to lower-case all accounts in the DB that are already conflict-free. Once there are no more "conflicting" accounts, you can clean up.
from muesli.
Related Issues (20)
- Automatic exam addmission HOT 1
- Add a warning when adding more points than maximum
- automatic reminder of new courses HOT 1
- Fix the test pipeline failure HOT 1
- Doppelte Anmeldung
- Angewandte Informatik ist veraltet HOT 1
- Die OpenAPI.json ist nicht mehr da. HOT 3
- SMTP Error im Docker
- `alembic upgrade head` broken HOT 1
- Remove outer margin
- Display Issues on mobile
- 500 error when trying to authorize with email and password using the API HOT 9
- Regression for interactive points entry HOT 7
- Requesting exercise via API returns result of all exercises of an exam instead of returning only the result of the exercise requested with its unique id HOT 2
- Problems in the API Spec
- C&P error in the exam API Spec
- Problem with the development setup
- Regression introduced in PR #106
- Option to request active tutorials via API
- Option join a tutorial using API call HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from muesli.