Server Administration

  Home arrow Server Administration arrow Page 6 - Generating Your Own Security Certifica...
SERVER ADMINISTRATION

Generating Your Own Security Certificates For Use With Apache/HTTPS
By: bluephoenix
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 5
    2004-01-27

    Table of Contents:
  • Generating Your Own Security Certificates For Use With Apache/HTTPS
  • Prepare the Working Environment
  • Install OpenSSL
  • Install Apache
  • Request, Sign and Install the Certificate
  • Configure Apache
  • Start/Stop Apache

  •  
     

    SEARCH CODEWALKERS

    TOOLS YOU CAN USE

    advertisement

    Generating Your Own Security Certificates For Use With Apache/HTTPS - Configure Apache


    (Page 6 of 7 )

    The desired directories, files and directives should be set in Apache's configuration file.

    # vi /usr/local/apache/conf/httpd.conf

    ServerType          standalone
    ServerRoot          /usr/local/apache

    <IfDefine SSL>
      Listen            80
      Listen            443
    </IfDefine>

    User                nobody
    Group               nogroup
    ServerAdmin         mail@example.com
    ServerName          www.example.com

    DocumentRoot        /mnt/hdd/web
    LoadModule          php4_module libexec/libphp4.so

    <IfModule mod_dir.c>
      DirectoryIndex    index.php index.html
    </IfModule>

    <IfModule mod_mime.c>
      AddType      application/x-httpd-php      .php
    </IfModule>

    <Directory "/mnt/hdd/web">
      Options           Indexes FollowSymLinks MultViews
      AllowOverride     None
      Order             allow,deny
                        Allow from all
    </Directory>

    <IfDefine SSL>
      NameVirtualHost     *:443
      <VirtualHost *:443>
        DocumentRoot    /mnt/hdd/webssl

        SSLEngine       on
        SSLCertificateFile \
            /usr/local/apache/conf/ssl.crt/server.crt
        SSLCertificateKeyFile \
            /usr/local/apache/conf/ssl.key/server.key

        <Directory "/mnt/hdd/webssl">
          Options       Indexes MultViews
          AllowOverride None
          Order         allow,deny
                        Allow from all
        </Directory>
      </VirtualHost>
    </IfDefine>

    The default configuration file provides a good starting point. Specific points of interest are the ServerType, ServerRoot, ServerAdmin, ServerName, DocumentRoot, LoadModule, SSLEngine, SSLCertificateFile and SSLCertificateKeyFile directives.

    Be sure that the SSLCertificateFile points to the location of the server's certificate and the SSLCertificateKeyFile points to the location of the server's encryption key.

    There may be other directives that you wish to change.

    More Server Administration Articles
    More By bluephoenix

    blog comments powered by Disqus

    SERVER ADMINISTRATION ARTICLES

    - Server Responses to Client Communication
    - Authentication in Client/Server Communication
    - Client/Server Communication
    - Understanding Awk in the UNIX Shell
    - Stream Editor in the UNIX Shell
    - Processes in the UNIX Shell
    - Migrating from Windows to Wine
    - Wine: Not Another Emulator
    - Preventive Measures to Block SSH Attacks
    - Monitoring Temperatures with Cacti
    - Cacti: RRDTool-based Graphing Solution
    - Network Magic 5.0 Review
    - Netfilter and Iptables Overview
    - Installing and Configuring Squid
    - Clickfree PC Backup Systems Compared


    © 2003-2012 by Developer Shed. All rights reserved. DS Cluster 6 - Follow our Sitemap