Difference between revisions of "Webserver"

From Blue-IT.org Wiki

(Apache2)
(Derectory)
Line 10: Line 10:
 
     Options ExecCGI FollowSymLinks
 
     Options ExecCGI FollowSymLinks
 
     AllowOverride None
 
     AllowOverride None
 
+
     Order allow,deny
+
     '''Order allow,deny'''
    Allow from all
+
     '''Allow from all'''
     '''Require all granted'''
 
  
 
New
 
New
Line 21: Line 20:
  
 
     '''Require all granted'''
 
     '''Require all granted'''
 
  
 
== SSL ==
 
== SSL ==

Revision as of 15:29, 2 February 2014

Apache2

Apache 2.4

Since apache version 2.4 there exists some new vocabularies for directives.

The next sections show the difference to apache2 version 2.2:

Derectory

Old

  <Directory "/srv/www/whatever">
   Options ExecCGI FollowSymLinks
   AllowOverride None

   Order allow,deny
   Allow from all

New

  <Directory "/srv/www/whatever">
   Options ExecCGI FollowSymLinks
   AllowOverride All
   Require all granted

SSL

Ubuntu Hardy - 8.04

First create a server certificate. Please add the directory and filennames according to your needs:

sudo a2enmod ssl
export MY_SSL_DIR="/etc/apache2/ssl"
export MY_PAM_FILE="apache.pem"
sudo apt-get install ssl-cert
sudo mkdir "${MY_SSL_DIR}"
sudo /usr/sbin/make-ssl-cert /usr/share/ssl-cert/ssleay.cnf "${MY_SSL_DIR}/${MY_PAM_FILE}"

Now add the following to your virtual hosts config file (test with default). And use the pam filename and path from above:

<VirtualHost *>

[...]
       SSLEngine on
       SSLCertificateFile /etc/apache2/ssl/apache.pem
       SSLProtocol all
       SSLCipherSuite HIGH:MEDIUM
[...]

Restart the webserver

sudo invoke-rc.d apache2 restart

Subversion