9 May 11:27
Forcing clients to enable cookies?
From: Stefan Müller-Wilken <stefan.mueller-wilken <at> resco.de>
Subject: Forcing clients to enable cookies?
Newsgroups: gmane.comp.apache.mod-security.user
Date: 2008-05-09 09:27:38 GMT
Subject: Forcing clients to enable cookies?
Newsgroups: gmane.comp.apache.mod-security.user
Date: 2008-05-09 09:27:38 GMT
Dear all, one of my customers has introduced a security policy by which all web applications have to do their session handling via cookies. Rather than doing the boilerplate code in all web apps I'd like to check in only one place if client browsers allow cookies and send them to an error page if not. Is there a way to use mod_security to do the trick? Or would I be better off using mod_rewrite instead? Conceptionally I would have set a cookie, force a reload, and on the next access, see if the cookie is still there, right? But how can I do that? Would be great if someone could give me an idea! Cheers Stefan. Resco GmbH Geschäftsführer: Michael Mörchen Amtsgericht Hamburg, HRB 76048 Ust.Ident-Nr.:DE208833022 Haftungsausschluss: Diese Nachricht ist ausschließlich für die Person oder Einheit bestimmt, an die sie gerichtet ist. Sie enthält unter Umständen Informationen, die unter geltendem Recht vertraulich, gesetzlich geschützt oder von der Offenlegung ausgeschlossen sind. Falls Sie nicht der vorgesehene Empfänger oder verantwortlich für die Weiterleitung dieser Nachricht an den vorgesehenen Empfänger sind, ist es Ihnen strengstens untersagt, diese Nachricht offenzulegen, zu verteilen, zu kopieren oder in irgendeiner Art zu benutzen. Sollten Sie diese Nachricht versehentlich erhalten haben, benachrichtigen Sie bitte den Absender und löschen und vernichten Sie jegliche Kopie davon, die Sie möglicherweise erhalten haben. Disclaimer: This message is intended only for the use of the individual or entity to which it is addressed and may contain information which is privileged, confidential, proprietary, or exempt from disclosure under applicable law. If you are not the intended recipient or the person responsible for delivering the(Continue reading)
But then again, there indeed _IS_ one thing
that confuses me a bit: in your code snippet you nowhere actually set the cookie, right? Something along
the lines of ...
# Set environment variable and same time set a probing cookie
RewriteRule ^/your/entry/page - [E=checkcookie:1, CO=cookieprobe:yes:mydomain.com:1:/]
... would do the trick, no?
Cheers
Stefan.
________________________________________
Von: Brian Rectanus [Brian.Rectanus <at> breach.com]
Gesendet: Freitag, 9. Mai 2008 18:59
An: Stefan Müller-Wilken
Cc: mod-security-users <at> lists.sourceforge.net
Betreff: Re: [mod-security-users] Forcing clients to enable cookies?
Stefan Müller-Wilken wrote:
> Dear all,
>
> one of my customers has introduced a security policy by which all web
> applications have to do their session handling via cookies. Rather than
> doing the boilerplate code in all web apps I'd like to check in only one
RSS Feed