Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Nisarg Parikh
New EU Cookie law implementation
May 18, 2012 7:00 AM
Answer

Nisarg Parikh

Rank: Expert

Posts: 262

Join Date: December 30, 2009

Recent Posts

Hi Community,

Has anybody has implemented new EU Cookie law ?

Any suggestions?

-Nisarg
Nisarg Parikh
RE: New EU Cookie law implementation
May 18, 2012 7:29 AM
Answer

Nisarg Parikh

Rank: Expert

Posts: 262

Join Date: December 30, 2009

Recent Posts

I have tried with below settings in Liferay.

session.enable.persistent.cookies=false

session.enable.url.with.session.id=false

Now Liferay does not add any cookie but Tomcat adds JSESSIONID cookie.

I have also treid setting cookie=false in context.xml in Tomcat but it still writes JSESSIONID cookie.

Dont know why is that being written.

Any suggestion or Help from community?

Thank you in advance.

-Nisarg
Juan Gonzalez
RE: New EU Cookie law implementation
May 20, 2012 3:16 AM
Answer

Juan Gonzalez

LIFERAY STAFF

Rank: Liferay Legend

Posts: 2857

Join Date: October 28, 2008

Recent Posts

Interesting.

What is that law about?
Nisarg Parikh
RE: New EU Cookie law implementation
May 20, 2012 5:44 AM
Answer

Nisarg Parikh

Rank: Expert

Posts: 262

Join Date: December 30, 2009

Recent Posts

Law is like on the landing page we need to ask user's consent about saving cookies in user's machine.
If user does not give permission to save cookie, website does not save any cookie on user's machine.

Can find more info on this link -
http://www.ico.gov.uk/

There are few websites which have implemented this law...some have their own interpretation of law..
I have tried as mentioned above but still it writes JSESSIONID.

Any idea or suggestion?

Please help me.

Thank you.

-Nisarg
Hitoshi Ozawa
RE: New EU Cookie law implementation
May 20, 2012 5:40 PM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 7949

Join Date: March 23, 2010

Recent Posts

Are you setting web.xml in the webapps\ROOT\WEB-INF?

In case Liferay is not working properly afterwards.
Which version of Tomcat are you using?
Below patch fix in 6.0.30. Liferay 6.0.6 tomcat bundle is using 6.0.29.
https://issues.apache.org/bugzilla/show_bug.cgi?id=49811
Nisarg Parikh
RE: New EU Cookie law implementation
May 20, 2012 11:40 PM
Answer

Nisarg Parikh

Rank: Expert

Posts: 262

Join Date: December 30, 2009

Recent Posts

Hi Hitoshi,

I have tried setting below properties in portal-ext.properties


session.enable.persistent.cookies=false

session.enable.url.with.session.id=false

and set cookies="false" in context.xml in tomcat server. I am using Liferay 6.0.5 and tomcat is 6.0.29

Still it writes JSESSIONID on machine..

Actually I want to customize the cookie writing thing..if user say yes then I want to write cookie otherwise not..

Any suggestion or help?

Thank you.

-Nisarg
Kailash Yadav
RE: New EU Cookie law implementation
May 21, 2012 12:33 AM
Answer

Kailash Yadav

Rank: Regular Member

Posts: 165

Join Date: October 18, 2011

Recent Posts

According to http://www.cookiecert.com/eu-cookie-law, every cookies does not need consent, the cookie law is concerned only with cookies that are NOT "strictly" necessary for the proper functioning a website like tracking cookies. As I think default liferay write only necessary cookies.
Hitoshi Ozawa
RE: New EU Cookie law implementation
May 21, 2012 4:31 AM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 7949

Join Date: March 23, 2010

Recent Posts

and set cookies="false" in context.xml in tomcat server.


And what about your web.xml in ROOT\WEB-INF folder as I've asked you before?
Nisarg Parikh
RE: New EU Cookie law implementation
May 21, 2012 6:01 AM
Answer

Nisarg Parikh

Rank: Expert

Posts: 262

Join Date: December 30, 2009

Recent Posts

Hi Hitoshi,

I have not changed anything in web.xml of ROOT\WEB-INF folder.

I am not sure about what to add/change in that? Can you please help me in that case?

Thank you for your help.

-Nisarg
Nisarg Parikh
RE: New EU Cookie law implementation
May 21, 2012 6:41 AM
Answer

Nisarg Parikh

Rank: Expert

Posts: 262

Join Date: December 30, 2009

Recent Posts

Hi Hitoshi,

I want in such a way that if user says NO to save cookies (on landing page) then I have to stop Liferay from writing any cookie.
i.e. session.enable.persistent.cookies=false

And again after sometime if user says YES to save cookies then I want Liferay to write cookies.
i.e. session.enable.persistent.cookies=true

Is this possible to dynamically load the properties?
If not then how can I achieve this functionality?

Please help me.
Thank you.

-Nisarg
Amy Green
RE: New EU Cookie law implementation
May 23, 2012 3:12 AM
Answer

Amy Green

Rank: New Member

Posts: 2

Join Date: May 22, 2012

Recent Posts

Exactly.
I need the same as Nisarg.

By leaving this:
- session.enable.persistent.cookies=false
- session.enable.url.with.session.id=false

You are saying ALWAYS NOT to cookies..and that's not what the law says. It's possible to change this properties for each user, only in their session, depending on their choice?