EPrints Technical Mailing List Archive

Message: #08984


< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First

Re: [EP-tech] Error while enabling SSL


Hi Sonu,

You may not have SSL enabled on your Apache webserver or you may have not put eprints-ssl.conf in the right place.  I have several questions/comments, which should allow me to help you fix this.

1. What Linux operating system are you running? (a2ensite is usually only a command for Apache on Debian/Ubuntu system.  So my assumption would be one of them.  However, the specific version of Debian / Ubuntu you are running would be useful to know as well).

2. Where did you put the eprints-ssl.conf file?  (Normally, I would expect you to put this in /etc/apache2/sites-available/).

3. Have you tried running (as the root user): "apache2ctl configtest", does that report any issues.  (It should just say "Syntax OK" if there are no problems.  If you are not running Debian or Ubuntu the command you need may be "apachectl configtest").

4. Please could you show me the output of the following command (run as the root user):

  source /etc/apache2/envvars && apache2 -S

(If you are not running Debian or Ubuntu you may need to run the command: httpd -S).

5.  If you are running Debian or Ubuntu it is worth running the following command as the root user to make sure SSL is enabled.

  a2enmod ssl

After running that command you will need to restart the webserver (e.g. apache2ctl restart) to check if it has worked from your web browser.

Regards

David Newman

On 21/06/2022 7:26 am, Sonu Yadav wrote:
CAUTION: This e-mail originated outside the University of Southampton.
Dear, 

Can you help me to enable the SSL certificate?

I am Using Eprints latest stable version. I am trying to enable SSL certificate EPrints 3.4 version but failed.

I have purchased an SSL certificate having these abc.key, xyz.crt, qwe.pem, and bundle_asd.crt  files and I placed them in /etc/apache2/ssl/ folder.
I follows the following step :

1. I edit the 10_core.pl file and paste the below code 

$c->{host} = 'xyz.edu.in';
$c->{port} = 80;
$c->{aliases} = [];
$c->{securehost} = 'xyz.edu.in';
$c->{secureport} = 443;
$c->{http_root} = undef;

2. then I run this command /usr/share/eprints/bin/generate_apacheconf with eprints user.

3. Then I edit the file eprints-ssl.conf file and paste the below code there
<VirtualHost 12.123.234.256:443>
  SSLEngine on
  SSLCertificateFile /etc/apache2/ssl/12345.crt
  SSLCertificateFile /etc/apache2/ssl/45677.pem

  Include /usr/share/eprints/cfg/apache_ssl/xyz.conf
 
  PerlTransHandler +EPrints::Apache::Rewrite
</VirtualHost>

4. then i run this command a2ensite eprints-ssl

When I open the site in the browser, it is showing an error and I also follow how to do video.

Thanks,
Sonu