SSL Logging

Discussion in 'Installation/Configuration' started by edworcs, Jun 22, 2011.

  1. edworcs

    edworcs New Member HowtoForge Supporter


    We're trying to get per virtual host SSL logging working. We would like an ssl_access_log and an ssl_error_log for virtual sites where SSL has been enabled.

    We can see that per virtual host logging is controlled by vlogger and configured in /etc/httpd/conf/sites-available/ispconfig.conf. This appears to work with a non SSL access.log

    We can see that the /etc/httpd/conf/sites-available/SITENAME.vhost file has an entry for error logs:

    <VirtualHost IP.AD.DR.ES:443>
    ErrorLog /var/log/ispconfig/httpd/SITENAME/error.log
    This does log SSL errors, but they are mixed in with all other errors. We'd like a separate ssl_error_log. We also know that direct modification of .vhost files is not a smart idea as they will be overwritten. So we added the following into Apache Directives on a per site basis:

    CustomLog  /var/www/SITENAME/log/access_ssl_log combined_ssl_ispconfig
    ErrorLog   /var/www/SITENAME/log/error_ssl_log
    Unfortunately this is placed outside of the SSL Virtual host in the .vhost file and so all requests are logged to access_ssl_log for both http and https.

    We can see that there is an entry for logging in /etc/httpd/conf.d/ssl.conf

    #   Per-Server Logging:
    #   The home of a custom SSL log file. Use this when you want a
    #   compact non-error SSL logfile on a virtual host basis.
    CustomLog logs/ssl_request_log \
              "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
    We can see the following server wide files:


    The files listed above are logged to if the IP address of the SSL site is used directly, but not the name.

    Can anybody offer any help as to how to do this?



    ISPConfig 3.0.3 on Centos 5.5. Setup using Perfect Server, but modified since setup.
    Last edited: Jun 22, 2011

Share This Page