From e0dcab7043f8898fb60c3c2b480a3a554f09df5f Mon Sep 17 00:00:00 2001 From: Michael DeHaan Date: Fri, 14 Nov 2008 16:34:55 -0500 Subject: Two security things -- restrict python imports within cheetah code, allow power-user and power-pass to be specified when running power commands instead of storing them in cobbler. --- cobbler/commands.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'cobbler/commands.py') diff --git a/cobbler/commands.py b/cobbler/commands.py index d2da685d..380f374c 100644 --- a/cobbler/commands.py +++ b/cobbler/commands.py @@ -276,21 +276,21 @@ class CobblerFunction: obj = collect_fn().find(self.options.name) if obj is None: raise CX(_("object not found")) - self.api.power_on(obj) + self.api.power_on(obj,self.options.power_user,self.options.power_pass) return None if "poweroff" in self.args: obj = collect_fn().find(self.options.name) if obj is None: raise CX(_("object not found")) - self.api.power_off(obj) + self.api.power_off(obj,self.options.power_user,self.options.power_pass) return None if "reboot" in self.args: obj = collect_fn().find(self.options.name) if obj is None: raise CX(_("object not found")) - self.api.reboot(obj) + self.api.reboot(obj,self.options.power_user,self.options.power_pass) return None if "remove" in self.args: -- cgit