Re:My Notes on Gitlab's Postgres Schema Design (2022)
by plagiarist on Sunday February 18, 2024 @08:21AM
(#39418834)
I've already resolved to never use Gitlab entirely on the basis of that CVE but that makes it worse.
Password resets should just never go to an email that hasn't been deliberately attached to an account by the account's owner, full stop. There should not be a code path where it is possible to send any such thing to arbitrary emails. And redirect emails should never be treated as account emails in any way.
Re:My Notes on Gitlab's Postgres Schema Design (2022)
by yellowapple on Sunday February 18, 2024 @02:51PM
(#39422446)
Even without that auto-incrementing ID, there are plenty of other options for guessing valid email addresses to use with that exploit. For example, if you're able to figure out the format an organization uses for their email addresses (e.g. [email protected]), and you're able to figure out who works at that org (via e.g. LinkedIn), then there's a very good chance you can reset passwords for, say, the company's CTO or other likely-highly-privileged users.
That is: this kind of proves my point. Removing autoincrementing IDs from the equation is of minimal benefit when things have already gone horribly horribly wrong like this. It's a little bit more work on the attacker's part, but not by anywhere near enough for such a "mitigation" to be of much practical benefit.
This meant that people could send password resets for any user if they knew their userID. The mail format was like [email protected] or something.
Since it's a safe bet that "user ID 1" is an admin user, someone weaponised this.