diff options
author | michael pereira | 2011-04-07 14:45:47 +0200 |
---|---|---|
committer | michael pereira | 2011-04-07 14:45:47 +0200 |
commit | 30963f047c24cbd3fa9c8c4af736c509caafbfe3 (patch) | |
tree | c33202190e20221b26f0b1f608117ea9118f9da1 /application/modules | |
parent | Bootos und Configs in Bootmenuentry categorisiert (diff) | |
download | pbs2-30963f047c24cbd3fa9c8c4af736c509caafbfe3.tar.gz pbs2-30963f047c24cbd3fa9c8c4af736c509caafbfe3.tar.xz pbs2-30963f047c24cbd3fa9c8c4af736c509caafbfe3.zip |
Meta Recht geändert
Diffstat (limited to 'application/modules')
11 files changed, 20 insertions, 18 deletions
diff --git a/application/modules/user/controllers/BootisoController.php b/application/modules/user/controllers/BootisoController.php index a8c7de7..ae34ca0 100644 --- a/application/modules/user/controllers/BootisoController.php +++ b/application/modules/user/controllers/BootisoController.php @@ -224,7 +224,7 @@ class user_BootisoController extends Zend_Controller_Action public function editbootisoAction() { //ACL Darf er BootISOs editieren? - if(!Pbs_Acl::checkRight('be')) + if(!Pbs_Acl::checkRight('be') && !Pbs_Acl::checkRight('bem')) $this->_redirect('/user/bootiso/index/page/'.$this->page.'/modifyresult/forbidden'); $bootisoID = $this->_request->getParam('bootisoID'); @@ -276,7 +276,7 @@ class user_BootisoController extends Zend_Controller_Action $bootiso->getPublic() != $bootisoold->getPublic() || $bootiso->getSerialnumber() != $bootisoold->getSerialnumber()){ //ACL Is he allowed to edit other than Metadata? - if(Pbs_Acl::checkRight('bem')) + if(!Pbs_Acl::checkRight('be')) $this->_redirect('/user/bootiso/index/page/'.$this->page.'/modifyresult/forbidden'); } diff --git a/application/modules/user/controllers/BootmenuController.php b/application/modules/user/controllers/BootmenuController.php index 77f509c..466ecb8 100644 --- a/application/modules/user/controllers/BootmenuController.php +++ b/application/modules/user/controllers/BootmenuController.php @@ -333,7 +333,7 @@ class user_BootmenuController extends Zend_Controller_Action public function editbootmenuentryAction() { //ACL Is he allowed to edit BootMenus? - if(!Pbs_Acl::checkRight('booee')) + if(!Pbs_Acl::checkRight('booee') && !Pbs_Acl::checkRight('booeem')) $this->_redirect('/user/bootmenu/index/page/'.$this->page.'/modifyresult/forbidden'); $bootmenuentryID = $this->_request->getParam('bootmenuentryID'); @@ -421,7 +421,7 @@ class user_BootmenuController extends Zend_Controller_Action $bootmenuentryold->getKcl() != $bootmenuentry->getKcl() || $bootmenuentryold->getKclappend() != $bootmenuentry->getKclappend()){ //ACL Is he allowed to edit this? - if(Pbs_Acl::checkRight('booeem')) + if(!Pbs_Acl::checkRight('booee')) $this->_redirect('/user/bootmenu/index/page/'.$this->page.'/modifyresult/forbidden'); } diff --git a/application/modules/user/controllers/BootosController.php b/application/modules/user/controllers/BootosController.php index 59efff0..aad26aa 100644 --- a/application/modules/user/controllers/BootosController.php +++ b/application/modules/user/controllers/BootosController.php @@ -274,7 +274,7 @@ class user_BootosController extends Zend_Controller_Action { //ACL Is he allowed to edit Preboots? - if(!Pbs_Acl::checkRight('boe')) + if(!Pbs_Acl::checkRight('boe') && !Pbs_Acl::checkRight('boem')) $this->_redirect('/user/bootos/index/page/'.$this->page.'/modifyresult/forbidden'); $bootosID = $this->_request->getParam('bootosID'); @@ -328,13 +328,13 @@ class user_BootosController extends Zend_Controller_Action $bootos->getExpires() != $bootosold->getExpires() || $bootos->getPublic() != $bootosold->getPublic() ){ //ACL Is he allowed to edit this? - if(Pbs_Acl::checkRight('boem')) + if(!Pbs_Acl::checkRight('boe')) $this->_redirect('/user/bootos/index/page/'.$this->page.'/modifyresult/forbidden'); } if($bootos->getPath_kernel() != $bootosold->getPath_kernel() || $bootos->getPath_init() != $bootosold->getPath_init()){ //ACL Is he allowed to edit the Kernel/Init Path? - if(Pbs_Acl::checkRight('boem')) + if(!Pbs_Acl::checkRight('boe')) $this->_redirect('/user/bootos/index/page/'.$this->page.'/modifyresult/forbidden'); $path_tmp = "../resources/bootos/"; diff --git a/application/modules/user/controllers/ConfigController.php b/application/modules/user/controllers/ConfigController.php index bbc0c8f..1af05cc 100644 --- a/application/modules/user/controllers/ConfigController.php +++ b/application/modules/user/controllers/ConfigController.php @@ -132,7 +132,7 @@ class user_ConfigController extends Zend_Controller_Action public function editconfigAction() { //ACL Darf er Configs editieren? - if(!Pbs_Acl::checkRight('ce')) + if(!Pbs_Acl::checkRight('ce') && !Pbs_Acl::checkRight('cem')) $this->_redirect('/user/config/index/page/'.$this->page.'/modifyresult/forbidden'); $configID = $this->_request->getParam('configID'); @@ -176,7 +176,7 @@ class user_ConfigController extends Zend_Controller_Action if($configold->getShellscript() != $config->getShellscript()){ //ACL Is he allowed to edit other than Metadata? - if(Pbs_Acl::checkRight('cem')) + if(!Pbs_Acl::checkRight('ce')) $this->_redirect('/user/config/index/page/'.$this->page.'/modifyresult/forbidden'); } diff --git a/application/modules/user/controllers/PrebootController.php b/application/modules/user/controllers/PrebootController.php index b630267..e74dd3f 100644 --- a/application/modules/user/controllers/PrebootController.php +++ b/application/modules/user/controllers/PrebootController.php @@ -250,7 +250,7 @@ class User_PrebootController extends Zend_Controller_Action public function editprebootAction() { //ACL Is he allowed to edit Preboots? - if(!Pbs_Acl::checkRight('pre')) + if(!Pbs_Acl::checkRight('pre') && !Pbs_Acl::checkRight('prem')) $this->_redirect('/user/preboot/index/page/'.$this->page.'/modifyresult/forbidden'); $prebootID = $this->_request->getParam('prebootID'); @@ -291,7 +291,7 @@ class User_PrebootController extends Zend_Controller_Action if($preboot->getPath_preboot() != $prebootold->getPath_preboot()){ //ACL Is he allowed to edit the Preboot Path? - if(Pbs_Acl::checkRight('prem')) + if(!Pbs_Acl::checkRight('pre')) $this->_redirect('/user/preboot/index/page/'.$this->page.'/modifyresult/forbidden'); exec("wget -O '".$path_preboot."preboot.zip' ".escapeshellcmd($preboot->getPath_preboot()) ." 2>&1 | grep 'saved'" , $status); diff --git a/application/modules/user/forms/Bootiso.php b/application/modules/user/forms/Bootiso.php index 10bd53d..7a3547e 100644 --- a/application/modules/user/forms/Bootiso.php +++ b/application/modules/user/forms/Bootiso.php @@ -26,7 +26,7 @@ class user_Form_Bootiso extends Zend_Form $this->setName($this->action); $this->setMethod('post'); - if (Pbs_Acl::checkRight('bem')) + if (!Pbs_Acl::checkRight('be')) $meta = true; else $meta = null; diff --git a/application/modules/user/forms/Bootmenu.php b/application/modules/user/forms/Bootmenu.php index 081904f..8389fa8 100644 --- a/application/modules/user/forms/Bootmenu.php +++ b/application/modules/user/forms/Bootmenu.php @@ -23,7 +23,7 @@ class user_Form_Bootmenu extends Zend_Form $this->setName($this->action); $this->setMethod('post'); - if (Pbs_Acl::checkRight('booeem')) + if (!Pbs_Acl::checkRight('booee')) $meta = true; else $meta = null; diff --git a/application/modules/user/forms/BootmenuEntries.php b/application/modules/user/forms/BootmenuEntries.php index 56ed5da..b897974 100644 --- a/application/modules/user/forms/BootmenuEntries.php +++ b/application/modules/user/forms/BootmenuEntries.php @@ -56,7 +56,7 @@ class user_Form_BootmenuEntries extends Zend_Form $this->setName($this->action); $this->setMethod('post'); - if (Pbs_Acl::checkRight('booeem')) + if (!Pbs_Acl::checkRight('booee')) $meta = true; else $meta = null; diff --git a/application/modules/user/forms/Bootos.php b/application/modules/user/forms/Bootos.php index 21f674b..6edc7eb 100644 --- a/application/modules/user/forms/Bootos.php +++ b/application/modules/user/forms/Bootos.php @@ -28,7 +28,7 @@ class user_Form_Bootos extends Zend_Form $this->setName("BootOsCreate"); $this->setMethod('post'); - if (Pbs_Acl::checkRight('boem')) + if (!Pbs_Acl::checkRight('boe')) $meta = true; else $meta = null; diff --git a/application/modules/user/forms/Config.php b/application/modules/user/forms/Config.php index e9bbffb..2ee221d 100644 --- a/application/modules/user/forms/Config.php +++ b/application/modules/user/forms/Config.php @@ -18,7 +18,7 @@ class user_Form_Config extends Zend_Form $this->setName($this->action); $this->setMethod('post'); - if (Pbs_Acl::checkRight('cem')) + if (!Pbs_Acl::checkRight('ce')) $meta = true; else $meta = null; diff --git a/application/modules/user/forms/Preboot.php b/application/modules/user/forms/Preboot.php index 8032a71..99c7563 100644 --- a/application/modules/user/forms/Preboot.php +++ b/application/modules/user/forms/Preboot.php @@ -18,9 +18,11 @@ class user_Form_Preboot extends Zend_Form $this->setName($this->action); $this->setMethod('post'); - if (Pbs_Acl::checkRight('prem')) + if (!Pbs_Acl::checkRight('pre')) $meta = true; - + else + $meta = null; + $this->addElement('text', 'title', array( 'filters' => array('StringTrim'), 'validators' => array( |