mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-06 21:35:55 +01:00
security fix: CP-10: Admin Websites Suspend / Unsuspend
This commit is contained in:
@@ -574,6 +574,12 @@ class WebsiteManager:
|
||||
|
||||
website = Websites.objects.get(domain=websiteName)
|
||||
|
||||
admin = Administrator.objects.get(pk=userID)
|
||||
if ACLManager.checkOwnership(websiteName, admin, currentACL) == 1:
|
||||
pass
|
||||
else:
|
||||
return ACLManager.loadErrorJson('websiteStatus', 0)
|
||||
|
||||
if state == "Suspend":
|
||||
confPath = virtualHostUtilities.Server_root + "/conf/vhosts/" + websiteName
|
||||
command = "mv " + confPath + " " + confPath + "-suspended"
|
||||
|
||||
Reference in New Issue
Block a user