# cd /usr/local/www/svn.https # mkdir certs # cd certs # openssl genrsa -des3 -out server.key 1024 # openssl req -new -key server.key -x509 -out server.crt
After we have the keys we have to configure apache. We load the mod_ssl module
LoadModule ssl_module libexec/apache22/mod_ssl.so
We then use the following directives to set up https:
SSLEngine On SSLCertificateFile certs/server.crt SSLCertificateKeyFile certs/server.key SSLSessionCache dbm:/usr/local/www/svn.https/ssl/gcache SSLSessionCacheTimeout 3600 SSLVerifyClient none Listen 443
And in the Location the points to the Subversion repository we add SSLRequireSSL directive:
<Location /svn> DAV svn ... SSLRequireSSL </Location