Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

Possible Duplicate:
How do I comply with the EU Cookie Directive?

Under this new EU law we are not allowed to use any cookies without asking first,

I for one need to use a cookie to register the user logged on, as if not with a cookie they can log on more than once and breach the license terms of the software.

so i find myself asking what can we use instead of cookies to perform this task?

share|improve this question
7  
"...the EU’s directive stated that websites would have to obtain informed and explicit consent from their visitors through notifications every time a cookie is to be placed on their machine. The only exception is for cookies strictly necessary for the legitimate purpose of enabling the use of an explicitly requested service." - blog.incomeaccess.com/9134/2011/06/20/… I would think that the exception covers the need for session tracking cookies; as in strictly necessary to access the service(s) of your site. *INAL, and I don't live in the EU. –  techie007 Jun 30 '11 at 11:53
4  
that should be an answer –  jk. Jun 30 '11 at 12:13
    
@techie so if the explict use of my site is to gather your information and tracking your surfing habits im ok right :P Im sure that is how it would be ruled in the US. –  Chad Jun 30 '11 at 13:20
    
@Chad - another part of the American Way would be if you are not explicit enough, the ruling may not be so favorable. Especially if your site makes any money $-) –  JeffO Jun 30 '11 at 14:07
    
@Chad - If I explicitly requested that service from you, and your cookie was necessary for you to provide that requested service, then yes, I guess it would cover it. I don't really think it's an "answer" to an alternative to using cookies to track log on sessions, but hey, three people want it as an answer I'll put it in as one. ;) –  techie007 Jun 30 '11 at 16:01
show 1 more comment

marked as duplicate by Mark Trapp Jul 1 '11 at 7:40

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

4 Answers

You can add a session identifier to a hidden field in all pages or to the URL.

You could also ask all existing users for permission to use cookies and add a new cookie clause to your license.

It might be less expensive to drop non-compliant customers that to recode your site.

share|improve this answer
    
Thats a valid comment but I was looking for maybe some unique info that is sent by the browser / machine, that could be used server side to generate a unique id, basically becoming a serverside cookie... –  Theresa Forster Jun 30 '11 at 11:57
1  
@Theresa if there were such a thing web frameworks would not exclusively depend on session tracking cookies. –  Jeremy Jun 30 '11 at 13:23
    
Just to add, US Federal Government Web sites have had this restriction since the Clinton administration. The use of session cookies provides the minimum functionality necessary without writing to the users HDD. –  Michael Mangold Jun 30 '11 at 13:42
    
@Jeremy - ASP.NET can do cookieless sessions. msdn.microsoft.com/en-us/library/aa479314.aspx –  rally25rs Jun 30 '11 at 18:25
    
@rally25rs Good point, but its just putting the session ID in the URL, not using any hidden identifier from the machine. –  Jeremy Jun 30 '11 at 19:18
add comment

Not really an answer towards an alternative to using cookies for log on session tracking, but it seems to point to the idea that the question may be moot.

From here:

Essentially, the EU’s directive stated that websites would have to obtain informed and explicit consent from their visitors through notifications every time a cookie is to be placed on their machine. The only exception is for cookies strictly necessary for the legitimate purpose of enabling the use of an explicitly requested service.

I would think that the exception covers the need for session-tracking cookies; as in 'strictly necessary' to access the service(s) of your site.

Disclaimer: I'm Not A Lawyer, and I don't live in the EU. :)

share|improve this answer
    
Well, this should allow for session cookies, if they are created only upon the user's successful authorization to the service whose terms they've already agreed to, but I guess it leaves anonymous session cookies in the grey zone. –  Filip Dupanović Jun 30 '11 at 16:17
    
@Filip Dupanović - I would think that exception, unless defined better some place else, would leave a HUGE gray area. :) –  techie007 Jun 30 '11 at 16:19
1  
My service includes serving contextually relevant ads. For that work a cookie is essential. The directive's wording is a horrible mix of technical jargon, legal wording, and business speak. It is totally and utterly useless. –  edA-qa mort-ora-y Jul 1 '11 at 8:04
    
There is also the problem that each individual country writes its own laws interpreting the EU directive. –  idstam Jul 1 '11 at 11:24
add comment

I guess you could resort to something like evercookie, but without the actual cookie and just use the other techniques.

My laymans interpretation says you can place cookies on someones machines if they explicitly request for you to render them a service and the cookie is required for the service to function. Like clicking the Login button on a web page. It is trying to exclude secret cookies that the users didn't ask for and don't know exist.

This would be a useless law in the US, as every advertiser would argue that clicking on the link to load the page would be explicitly requesting the ads on the page, and that the cookies they place on your machine were explicitly requested with the simple action of visiting a URL. EU might be different, it looks pretty technically un-enforceable to me.

share|improve this answer
add comment

If this really an issue for your site then host it somewhere outside of the EU. The last time I checked the EU cannot control the entire internet.

share|improve this answer
add comment

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