15

I have Apache running in Ubuntu 14.04. How do I disable and enable the SSL mode without a command? What about with a command?

36

As far as I know there is currently no way to disable SSL without command. With command, simply launch your terminal and enter

sudo a2dismod ssl

and restart apache2

sudo service apache2 restart

To do the opposite, use this command

sudo a2enmod ssl

and also restart apache2

2
  • and how enable ? – stevGates Dec 15 '15 at 3:56
  • I've appended it to my answer. – Tung Tran Dec 15 '15 at 4:05
2

For disabling SSL without a command you can manually edit the SSLEngine directive in your ssl configuration file (usually in /etc/apache2/sites-enabled/default-ssl.conf)

change:

SSLEngine on

to:

SSLEngine off

restart Apache. I guess that requires a command...

for Ubuntu 14.04 and before use: sudo service apache2 restart

for Ubuntu 16.04 and beyond use: sudo systemctl restart apache2.service

from: https://httpd.apache.org/docs/2.4/mod/mod_ssl.html

0

Only commands are available for disable and enable SSL

Locate your SSL Protocol Configuration on your Apache server with root permission. And type

grep -i -r "SSLProtocol" /etc/apache2 

to disable

Type the following command to restart

apachectl -k restart 
1
  • 1
    Is grep -i -r "SSLProtocol" /etc/apache2 intended to update the apache configuration, effectively disabling SSL? Instead, this command simply shows which files contain the SSLProtocol directive. The better answer is above (askubuntu.com/a/709631/382980) – matty Aug 29 '16 at 4:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.