无法安装自签名SSL证书。 Apache错误

时间:2013-01-15 20:39:01

标签: apache ubuntu ssl openssl ssl-certificate

我正在尝试安装我使用这些说明生成的自签名证书:

http://www.akadia.com/services/ssh_test_certificate.html

我已准备好证书,并已多次重读说明。但是,唯一的区别是我把它放在/etc/apache2/conf.d/security/

我从apache收到以下错误。

Syntax error on line 1 of /etc/apache2/conf.d/security/server.crt:
Invalid command '-----BEGIN', perhaps misspelled or defined by a module not included in the server configuration
Action 'configtest' failed.
The Apache error log may have more information.
   ...fail!

任何线索?我在Ubuntu 11.04中运行来自tasksel的最新灯泡安装。 (vhosts in sites-available等)。我还确保使用a2enmod ssl启用了ssl。它说它已经启用了。

------------ --------------- VHOST

<VirtualHost *:80>
        ServerAdmin webmaster@localhost
        ServerName www.cmp.me

        SSLEngine on
        SSLCertificateFile /etc/apache2/conf.d/security/server.crt
        SSLCertificateKeyFile /etc/apach2/conf.d/security/server.key

        DocumentRoot /var/www/sites/www.cmp.me
        <Directory />
                Options FollowSymLinks
                AllowOverride None
        </Directory>
        <Directory /var/www/sites/www.cmp.me>
                Options Indexes FollowSymLinks MultiViews
                AllowOverride None
                Order allow,deny
                allow from all
        </Directory>

        ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
        <Directory "/usr/lib/cgi-bin">
                AllowOverride None
                Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
                Order allow,deny
                Allow from all
        </Directory>

        ErrorLog /var/www/errors/cmp-error.log

        # Possible values include: debug, info, notice, warn, error, crit,
        # alert, emerg.
        LogLevel debug

    Alias /doc/ "/usr/share/doc/"
    <Directory "/usr/share/doc/">
        Options Indexes MultiViews FollowSymLinks
        AllowOverride None
        Order deny,allow
        Deny from all
        Allow from 127.0.0.0/255.0.0.0 ::1/128
    </Directory>

</VirtualHost>

0 个答案:

没有答案