Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: Conflict with consent module

Status Resolved
Add-on / Version Publisher 2.8.3
Severity
EE Version 4.3.2

Jeff Roberts

Jul 24, 2018

Description:

There is a conflict with Publisher and the new EE Consent module. The error message is:

Exception Caught
No such property: 'session' on EllisLab\ExpressionEngine\Legacy\Facade
Facade.php:119

The exception is occurring, because Publisher is setting cookies before the EE session service is fully constructed.

I have traced the error and have reduced the backtrace to the following key lines:
1. EE_Core::run_ee() (line 293) loads the ‘session’ library
2. EE_Session::__construct() (line 121) triggers the ‘session_start’ hook
3. Publisher_ext::sessions_start() (line 227) calls start() on the Publisher session service
4. BoldMinded\Publisher\Service\Session::start() (line 268) calls update() on the Publisher tracker service
5. BoldMinded\Publisher\Service\Url\Tracker::setTrackerCookie() (line 219) called by the update() method, tries to set a cookie with the EE input service
6. EE_Input::cookieIsAllowed() (line 270) called by set cookie, when ‘require_cookie_consent’ is enabled, calls hasGranted() on the EE consent service
7. system/ee/EllisLab/ExpressionEngine/app.setup.php (line 338) when initializing the EE consent service, tries to access the EE session service

Detailed steps to reproduce the issue:
1. Install Publisher
2. Add $config[‘require_cookie_consent’] = ‘y’; to system/user/config/config.php
3. Reload the page

My thoughts are to either make ‘publisher_tracker’ a necessary cookie (easiest fix and what I have done for now, but not really in the spirit of cookie consent), or to move updating the tracker to the ‘core_boot’ hook (after the EE session service is fully initialized).

 

 

#1

BoldMinded (Brian)

Thanks for the detailed report. Its rare that I get a detailed report like this so its very appreciated when I do. I’ll take a look at this in a couple days, kind of behind right now due to my family visiting for a few days.

I’ll see if moving it to core_boot works, if it does I’ll do that. As for making it a necessary cookie, I’m not sure that is not in the spirit of cookie consent. I’ve done quite a bit of work with GDPR recently and it really comes down to if the cookie contains any personally identifiable information, or if the the information in the cookie can be tied to PII, which the tracking cookie does not. All it is used for is to ensure the use is redirected to the correct place after switching languages.

#2

BoldMinded (Brian)

Comment has been marked private.

Login to reply