Installing SSL for a full website on ezpublish

Author Message

Gérard Bouchard

Thursday 24 January 2008 6:03:58 am

Hi all,

I'm working on a web server running ubuntu 7.10 & apache 2.0. This server has one website (based on ezpublish 3.9.2) only.

When you enter the website, the first page asks you to log in (with login/pass). Since I've setup SSL, it's impossible to login. Whatever the login/pass is, the website says that we have a bad username or password.

Here is my config file of the website with the vhosts (apache 2.0) :

NameVirtualHost *:443

<VirtualHost *:80>
	DocumentRoot /var/www/
	ServerName localhost
	Redirect / https://localhost/
</VirtualHost>

<VirtualHost *:443>
	ServerName localhost
	DocumentRoot /var/www/
	SSLEngine on
	SSLCertificateFile /etc/apache2/server.crt
	SSLCertificateKeyFile /etc/apache2/server.key
</VirtualHost>

I edit the /settings/override/site.ini.append.php file, here it is :

<?php 

#?ini charset="utf-8"?

[SiteSettings]
SSLPort=443

[SSLZoneSettings]
SSLZones=enabled

/*
[ExtensionSettings]
ActiveExtensions[]=ezdhtml
ActiveExtensions[]=ezodf

[Session]
SessionNameHandler=custom

[SiteSettings]
DefaultAccess=plain_site
SiteList[]=plain_site
SiteList[]=plain_site_lang2

[SiteAccessSettings]
CheckValidity=false
AvailableSiteAccessList[]=plain_site
AvailableSiteAccessList[]=plain_site_admin
AvailableSiteAccessList[]=plain_site_lang2
MatchOrder=uri
HostMatchMapItems[]

[MailSettings]
Transport=SMTP
TransportServer=SR-INF21.netfective.com
TransportUser=
TransportPassword=
AdminEmail=bluage.support@netfective.com
EmailSender=

[DebugSettings]
DebugOutput=disabled
DebugRedirection=disabled

[TemplateSettings]
Debug=disabled
ShowXHTMLCode=disabled
ShowUsedTemplates=disabled

[DatabaseSettings]
SQLOutput=disabled
SiteAccessList[]=plain_site
SiteAccessList[]=plain_site_admin
SiteAccessList[]=plain_site_lang2
*/ ?>

I just uncommented the first line (which was #?ini charset="utf-8"?) and added the SSL Lines. I want to have SSL for all the pages of the websites, how do I do ? Have I to put all the zones in lines like "ModuleViewAccessMode[user/login]=ssl" (but how to list all the zones ?)

Thanks for your support :)

Regards,

Gérard

Gérard Bouchard

Friday 25 January 2008 12:21:28 am

It's ok, I didn't modify the site.ini file (SSLZones=disabled is marked)
Here is my website config file (apache2.0) :

NameVirtualHost *:443

<VirtualHost *:80>
	DocumentRoot /var/www/
	ServerName localhost
	Redirect / https://localhost/
</VirtualHost>

<VirtualHost *:443>
	ServerName localhost
	DocumentRoot /var/www/
	SSLEngine on
	SSLCertificateFile /etc/apache2/server.crt
	SSLCertificateKeyFile /etc/apache2/server.key
</VirtualHost>

And now, as soon as I enter the website by taping http://localhost/mywebsite, https activates and I can move on all my website based on ezpublish with SSL.

Noicokuna Niemoge

Monday 26 January 2009 12:14:29 am

I've got another problem with ssl. When I enable it, the login redirection redirects me to:

www.mysite.com/index.php?/index.php?/siteaccess/

... is it a known bug?

Shiki soku ze ku...

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 18:16:49
Script start
Timing: Jan 18 2025 18:16:49
Module start 'layout'
Timing: Jan 18 2025 18:16:49
Module start 'content'
Timing: Jan 18 2025 18:16:50
Module end 'content'
Timing: Jan 18 2025 18:16:50
Script end

Main resources:

Total runtime0.9264 sec
Peak memory usage4,096.0000 KB
Database Queries57

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0149 588.0469152.6406
Module start 'layout' 0.01500.0045 740.687539.4922
Module start 'content' 0.01950.9054 780.1797502.8359
Module end 'content' 0.92490.0015 1,283.015612.1250
Script end 0.9264  1,295.1406 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00400.4316160.0002
Check MTime0.00160.1734160.0001
Mysql Total
Database connection0.00110.122910.0011
Mysqli_queries0.868493.7397570.0152
Looping result0.00050.0572550.0000
Template Total0.873894.320.4369
Template load0.00220.232420.0011
Template processing0.871694.086420.4358
Template load and register function0.00020.023910.0002
states
state_id_array0.00160.175110.0016
state_identifier_array0.00210.222620.0010
Override
Cache load0.00180.1908230.0001
Sytem overhead
Fetch class attribute can translate value0.00070.070620.0003
Fetch class attribute name0.00140.153130.0005
XML
Image XML parsing0.00020.025920.0001
class_abstraction
Instantiating content class attribute0.00000.000930.0000
General
dbfile0.00270.2872100.0003
String conversion0.00000.001440.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
6content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
3content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 15
 Number of unique templates used: 6

Time used to render debug report: 0.0002 secs