Mod usertrack Cookie while 3xx redirect

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

 



Hello everyone,

I've spent some time trying to figure out why my Usertrack cookies were not sent while doing a 3xx redirect.

I had the same problem with custom Headers set using the header command (everything in an .htaccess file)

To get the header I have to put the "always" condition so that they get added. Since I've had a look at mod_headers.c and mod_usertrack.c and it seems the redirection is using f->r->err_headers_out instead of f->r->headers _out (while f is ap_filter_t*)

So my question is, what is the best way to achieve what I want ? (put usertrack cookies while redirecting) (I forgot to say that I don't want to use a script language like PHP for performance reasons)

1- Use some rewrite magic (internal redirect, proxy ?) to get the headers sent using for example a local redirect (which seems to add the headers), then a 3xx redirect (but I can't get them at that phase) 2- make a small patch to add a similar directive (CookieAlwaysSend ?) that also adds usertrack cookie header to f->r->err_headers_out (should I also add a error filter to the chain in that case ?) 3- use some other magic to get the internal current value of usertrack cookie in rewrite rules (getting the value of f->r->headers_out if it has already been filled by usertrack would be great) and then add the cookie manually

I've tried using the CO directive from mod_rewrite and those cookies are correctly added in 3xx redirects...

Maybe I'm completely mistaken and I should not put cookies in redirect responses or manually adding a simple "Location: URI" header instead of doing a 3xx redirect would do the trick but I'm not sure about Browser compatibility ...
If I'm mistaken it would be great to have some pointers to understand why.

Thanks in advance,

Stephane.

--
(Logo EmisFr)
*Stéphane BERTHELOT*
EmisFR
/Réseau : Sécurité et Serveurs , Développements métier et spécifiques/
10 rue Mazagran, 54000 NANCY, France
http://www.emisfr.com
Tel/Fax.: +33.3 83 32 25 75

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
  "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[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