I built an Apache 2.2.32 server on Ubuntu from sources, and if I test my phpinfo() I see:
'./configure' '--prefix=/usr/local/php_7.2.25' '--with-apxs2=/usr/local/apache2/bin/apxs' '--with-mysqli=/usr/local/mysql-5.1.55/bin/mysql_config' '--with-gettext' '--with-curl' '--enable-intl' '--enable-ssl'
So I understand that SSL is enabled.
I created the certificate files 'server.key', 'server.crt' and 'cert.csr', within '/usr/local/apache2/conf/', by using '/usr/bin/openssl'. So I understand that OpenSSL works ok.
I inserted the following lines in the '/usr/local/apache2/conf/extra/httpd-vhosts.conf' file, at the bottom.
Listen 443 <VirtualHost *:443> DocumentRoot "/myserver/web" ServerName foo.local ErrorLog "logs/own-error_log" CustomLog "logs/own-access_log" common SSLEngine on SSLProtocol all -SSLv2 SSLCipherSuite HIGH:MEDIUM:!aNULL:!MD5 SSLCertificateFile "/usr/local/apache2/conf/server.crt" SSLCertificateKeyFile "/usr/local/apache2/conf/server.key" <Directory "/myserver/web"> Options FollowSymLinks AllowOverride All Order allow,deny Allow from all DirectoryIndex index.php index.html index.htm </Directory> </VirtualHost>
However, when I tried to restart Apache, I got the following error message:
Invalid command 'SSLEngine', perhaps misspelled or defined by a module not included in the server configuration
What am I doing wrong?