Ubuntu 18 Apache ECC SSL Kurulumu

Merhaba arkadaşlar;

Bu anlatımımda sizlere ubuntu 18 üzerinde apache üzerinde ecc ssl yapılandırmasını anlatacağım.

ECC SSL Nedir?

ECC, Eliptik Eğri Şifrelemesini temsil eder ve sonlu alanlar üzerinde eliptik eğrilere dayanan genel anahtar şifrelemesine bir yaklaşımdır.

Yapılandırma

İlk Olarak sistemimizde apache kurulu olduğunu varsayıyorum. Ardından ssl dosyalarımızı alttaki dizine kopyalıyoruz.

sudo cp /home/user/ssl.ca-bundle /etc/ssl/private/
sudo cp /home/user/ssl.crt /etc/ssl/private/
sudo cp /home/user/ssl.key /etc/ssl/private/

Alttaki dosyayı açıyoruz ve SSL dosyasını oluşturuyoruz.

sudo nano /etc/apache2/sites-enabled/default-ssl.conf

Alttaki kod bloğunundaki ServerName, SSLCertificateFile, SSLCertificateKeyFile, SSLCertificateChainFile bölümlerini düzenledikten sonra açtığımız yeni dosyanın içine yapıştırıp kaydedip çıkıyoruz.

<VirtualHost *:443>
        # The ServerName directive sets the request scheme, hostname and port t$
        # the server uses to identify itself. This is used when creating
        # redirection URLs. In the context of virtual hosts, the ServerName
        # specifies what hostname must appear in the request's Host: header to
        # match this virtual host. For the default virtual host (this file) this
        # value is not decisive as it is used as a last resort host regardless.
        # However, you must set it for any further virtual host explicitly.
        #ServerName www.example.com

        ServerAdmin webmaster@localhost
        DocumentRoot /var/www/html

        ServerName www.domain.com
        SSLEngine on
        SSLCertificateFile /etc/ssl/private/ssl.crt
        SSLCertificateKeyFile /etc/ssl/private/ssl.key
        SSLCertificateChainFile /etc/ssl/private/ssl.ca-bundle


        # Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
        # error, crit, alert, emerg.
        # It is also possible to configure the loglevel for particular
        # modules, e.g.
        #LogLevel info ssl:warn

        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined

        # For most configuration files from conf-available/, which are
        # enabled or disabled at a global level, it is possible to
        # include a line for only one particular virtual host. For example the
        # following line enables the CGI configuration for this host only
        # after it has been globally disabled with "a2disconf".
        #Include conf-available/serve-cgi-bin.conf
</VirtualHost>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

SSL modülünü aktif ediyoruz:

sudo a2enmod ssl

Daha sonra bir önceki adımda da belirttiği gibi apache’yi restart ediyoruz:

sudo systemctl restart apache2

İşlemimiz tamam.