Browsing articles tagged with "php - 3/152 - Admins Goodies"
Nov 22, 2012
tom

Isolating Apache virtualhosts from the rest of the system

I am setting up a web server that will host a number of different web sites as Apache VirtualHosts, each of these will have the possibility to run scripts (primarily PHP, possiblu others). My question is how I isolate each of these VirtualHosts from eachother and from the rest of the system? I don’t want e.g. website X to read the configuration of website Y or any of the server’s “private” files. At the moment […]

Continue Reading »
Nov 18, 2012
tom

run php script in the background

is there a way to launch a php script and let it run on the server until it finishes? I use this php5-cgi /var/www/script.php -q & connecting via putty. When I close it (the session) the script stops! Why does it run dependent on the session? Asked by Sandro Antonucci Try nohup and disown: nohup php5-cgi /var/www/script.php -q & disown Answered by Dennis Kaarsemaker Check more discussion of this question. Bookmark on Delicious Digg this […]

Continue Reading »
Nov 17, 2012
tom

installing PHP with LAMP server

I am trying to install LAMP on my Ubuntu 12.04, from the method shown in this link. After running the following code sudo apt-get install php5 mysql-server apache2 I should have php installed, but when i type “localhost/info.php” it does not show the PHP window that it is supposed to show, instead the file gets downloaded in the Downloads folder Any help would be appreciated Asked by user1581917 You also need to install libapache2-mod-php5 – […]

Continue Reading »
Nov 17, 2012
tom

Binding to LDAPS using PHP failing

We’ve finally set-up our server to accept ldap SSL connections thanks to another question answered by a helpful member. Our problem now is that when attempting to bind to ldap using the below simple PHP script, we constantly fail. Binding using ldap instead of ldaps works just fine using the script so I know the ldap is enabled. The catcher is that while using LDP.exe, we can successfully connect and bind to ldap on port […]

Continue Reading »
Nov 9, 2012
tom

Compromised web server/multiple domains [closed]

Possible Duplicate: My server’s been hacked EMERGENCY Earlier today I found a lot of weird files on one of my servers (running Ubuntu Server 10.04), which I can’t understand how they got there. Probably some sort of XSS-injection, need to dig further in my applications. What I found; Multiple directories in the web roots of several domains, with short names (“wesz”, “aog0″, “uioolz”, …) containing the exact same files and file structures. Google doesn’t tell […]

Continue Reading »
Nov 7, 2012
tom

Install PHP 5.3 on Centos 6

I am setting up a staging server using CentOS and need to install PHP 5.3 to mirror my production server. Using the standard yum install php I’m sure will give me 5.4 – I’ve had a look and can’t figure out how to specify a version number to install. Can anyone advise? Many thanks. Asked by bsod99 To specify a version you do: yum install php-5.3.3-14 This assumes that php-5.3.3-14 is available in the repos […]

Continue Reading »
Nov 6, 2012
tom

Confirm that mysqli extension is not installed

Recently I discovered that mysqli extension is not installed in my server Centos version 2.6. I confirm it because I change the driver of db connection from mysqli to mysql and now works fine. So, is there another way/log to determinate this problem? because the apache error_log does not say anything about it. This really is not a problem, but it could be more complex in future. Why? because using the mysqli driver, the website […]

Continue Reading »
Nov 5, 2012
tom

Is there a good reason to change session.save_path?

On shared hosting, we had occasional problems when the server’s /tmp directory was full. Our hosting company suggested we change the session save path to be unique for each site. ini_set(‘session.save_path’, DOCUMENT_ROOT . ‘/_SESSIONS/’); Yes, that puts our sessions in the web root. We deal with potential privacy issues by including a .htacces file in that folder: deny from all This works. We have now moved to our own managed server. The default session save […]

Continue Reading »
Oct 30, 2012
tom

MediaWiki “open_basedir restriction in effect”

I installed a local MediaWiki and gave it access to the following directories in php.ini: open_basedir = /srv/http/:/home/:/tmp/:/usr/share/pear/:/usr/share/webapps/mediawiki Why do I still get the following message? It doesn’t make sense to me: <b>Warning</b>: is_file(): open_basedir restriction in effect. File(/usr/share/webapps/mediawiki/images/lock_yBgMBwiR) is not within the allowed path(s): (/srv/http/:/home/:/tmp/:/usr/share/pear/:/usr/share/webapps/mediawiki) in <b>/usr/share/webapps/mediawiki/includes/GlobalFunctions.php</b> on line <b>1196</b><br /> How can /usr/share/webapps/mediawiki/images/lock_yBgMBwiR not be within /usr/share/webapps/mediawiki? I don’t have further restrictions in httpd.conf (I’ve read in the official php documentation that file […]

Continue Reading »
Oct 29, 2012
tom

Amazon RDS and users, security

By default you got a username and password for your RDS database. Would it be dangerous to use the credentials on your production website, say in php files? Or is it necessary to create a user with less control of the db (e.g. only read)? However I can’t find the place to add user on amazon’s console. Asked by StCee Every production site needs to have credentials for the corresponding database they use. These files […]

Continue Reading »
Pages:«1234567...152»