mod_rewrite, cookies and : in the value

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Configuration: 2 servers which use two different cookies to help maintain
sessions. The cookies are set domain wide so each server can actually update
the others cookies.

When a request is sent to either server, I want to be able to update the
others cookies (session timeout time) with mod_rewrite due to an application
limitation (which allows these to get out of sync).

This is a simple task, except that the value of the cookie actually has a
":" in it which confuses mod_rewrite and the parameters since the parameter
separator is a ":".

Example:
RewriteCond %{HTTP_COOKIE} "CookieName=(.*);"
RewriteRule ^/ - [CO=CookieName:%1:domain.com:20:/,C]

With the value of %1 being "list: someData|OtherData "

Mod_rewrite takes this to be:
RewriteRule ^/ - [CO=CookieName:list:someData|OtherData:domain.com:20:/,C]

...which just throws things off :) Does anyone have a trick which would
allow a ":" to be in the data of a cookie when set?

thanks
benji
---
Benji Spencer
System Administrator
Ph: 312-329-2288

Attachment: smime.p7s
Description: S/MIME cryptographic signature


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux