mirror of
https://github.com/ansible/awx.git
synced 2026-05-15 13:27:40 -02:30
Do not allow superuser promotion by non-superusers.
This commit is contained in:
@@ -773,6 +773,7 @@ class UserList(ListCreateAPIView):
|
|||||||
model = User
|
model = User
|
||||||
serializer_class = UserSerializer
|
serializer_class = UserSerializer
|
||||||
|
|
||||||
|
@disallow_superuser_escalation
|
||||||
class UserMeList(ListAPIView):
|
class UserMeList(ListAPIView):
|
||||||
|
|
||||||
model = User
|
model = User
|
||||||
@@ -847,7 +848,7 @@ class UserActivityStreamList(SubListAPIView):
|
|||||||
return qs.filter(Q(actor=parent) | Q(user__in=[parent]))
|
return qs.filter(Q(actor=parent) | Q(user__in=[parent]))
|
||||||
|
|
||||||
|
|
||||||
|
@disallow_superuser_escalation
|
||||||
class UserDetail(RetrieveUpdateDestroyAPIView):
|
class UserDetail(RetrieveUpdateDestroyAPIView):
|
||||||
|
|
||||||
model = User
|
model = User
|
||||||
|
|||||||
Reference in New Issue
Block a user