Open BetterYan opened 4 years ago
Thanks for this - this type of problem is very common with the kind of cookie auth which ASP.NET (and Core) applications use. The issue is that User1 has a cookie which says he's an admin, and there's nothing about revoking his admin rights (via another session) which can directly reach out to his browser and revoke the cookie.
The only solution is to re-validate the cookie against the database on every access, which isn't usually considered to be very good for performance.
However, I'd say that Bonobo is not usually used in very high-volume environments, and it would probably make sense to make sure that the cookie is revalidated more often.
@willdean To my opinion, it's a minor bug that that 'normal' user can edit user profie at the fronend. But the backend side accepts the 'set as admin' request. It's the major issue.
Version 6.5.0
17 April 2019 Normal user can add himself with an admin role. It can be reproduced with below sequence