index b37ba728bd16310eeed1cfb5f8094cd0c1ed248f..2b9554ccab6e603c952a7d1558b62351067a83a0 100644 (file)
*/
$exists = file_exists(CONFIG_DIR."/".CONFIG_FILE);
- /* Redirect to GOsa login */
- if(isset($_POST['use_gosa'])){
+ /* Redirect to GOsa login, if :
+ * - gosa.conf exists
+ * - Permisssion are set correctly
+ */
+ if(isset($_POST['next']) && $exists && !is_world_readable(CONFIG_DIR."/".CONFIG_FILE)){
session_destroy();
header("Location: index.php");
exit();
$err_msg= "";
if($exists && $this->is_world_readable(CONFIG_DIR."/".CONFIG_FILE)){
- $err_msg = _("Your configuration file is currently world readable. This is a big security risk. Please updated the file permissions!");
+ $err_msg = _("Your configuration file is currently world readable. Please updated the file permissions!");
+ }elseif(!$exists){
+ $err_msg = _("The configuration is currently not readable or it does not exists.");
}
$smarty = get_smarty();