From b9a3ef486ebcde18a5ade37865ff8f397185d24f Mon Sep 17 00:00:00 2001
From: Till Brehm <tbrehm@ispconfig.org>
Date: Sun, 24 Jul 2016 05:30:59 -0400
Subject: [PATCH] Fixed #3979 Mailbox users unable to save autoresponders

---
 server/server.sh |   40 ++++++++++++++++++++++------------------
 1 files changed, 22 insertions(+), 18 deletions(-)

diff --git a/server/server.sh b/server/server.sh
index 7302ca4..9c92a86 100755
--- a/server/server.sh
+++ b/server/server.sh
@@ -1,25 +1,29 @@
-#!/bin/sh
+#!/bin/bash
+
 
 PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/X11R6/bin
 
 . /etc/profile
 
-if [ -f /tmp/ispconfig3_install/install/autoupdate ]; then
-	#
-	# there is a auto-update waiting for update, so let's do it
-	#
-	cd /tmp/ispconfig3_install/install
-	/usr/bin/php -q autoupdate.php	
-	cd /
+umask 022
 
-	#
-	# do some clean-up
-	#
-	rm /tmp/ispconfig3_install -R
+if [ -f /usr/local/ispconfig/server/lib/php.ini ]; then
+        PHPINIOWNER=`stat -c %U /usr/local/ispconfig/server/lib/php.ini`
+        if [ $PHPINIOWNER == 'root' ] || [ $PHPINIOWNER == 'ispconfig'  ]; then
+                export PHPRC=/usr/local/ispconfig/server/lib
+        fi
+fi
 
-else
-	# 
-	# there is no update waiting, so lets start the ISPConfig-System
-	#
-	/usr/bin/php -q /usr/local/ispconfig/server/server.php
-fi
\ No newline at end of file
+cd /usr/local/ispconfig/server
+/usr/bin/php -q \
+    -d disable_classes= \
+    -d disable_functions= \
+    -d open_basedir= \
+    /usr/local/ispconfig/server/server.php
+
+cd /usr/local/ispconfig/security
+/usr/bin/php -q \
+    -d disable_classes= \
+    -d disable_functions= \
+    -d open_basedir= \
+    /usr/local/ispconfig/security/check.php

--
Gitblit v1.9.1