Re: Expected behavior for "If-Modified-Since: <now>" and CGI generated content?

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

 



Hello,

Perhaps you want the server or the cgi software to respond with
headers specific to tell the client the content should not be cached
in any way for that type of responses.

Headers like:
Cache-Control: no-cache, no-store
Pragma: no-cache
Expires: 0

Those are the ones I recall, there may be others.

El mar, 9 mar 2021 a las 23:48, Heiko Schlittermann
(<hs@xxxxxxxxxxxxxxxx.invalid>) escribió:
>
> Hi,
>
> I've a resource generated by a CGI script (the result changes, it
> depends on the X-Forwarded-For header). Now the server receives requests
> for this resource.
>
> The requests have set the "If-Modified-Since" header
> to the current timestamp. The server now *always* responds with "Not
> Modified".  I understand that this is basically right, since the
> resource can't be modified in an infinite small amount of time.
>
> But how can I (the CGI script) convince the server, to evaluate the
> "Expires: 0" header (or maybe another one) and ignore the
> If-Modified-Since?
>
>
> There is a workaround, a can delete the If-Modified-Since header before
> processing the request, but that seems to be a workaround only. I think,
> the producer of the variable content should have a way to tell the
> server *Please do not respond with 304 for my content".
>
> I checked the source of modules/http/protocol_http.c, it seems to be
> there already for at least 7 years, so I believe, it's mature.
>
> Setting the "Last-Modified" header in the CGI script to a date in the
> future doesn't work, as Apache seems to cap it to the current date.
>
>     Best regards from Dresden/Germany
>     Viele Grüße aus Dresden
>     Heiko Schlittermann
> --
>  SCHLITTERMANN.de ---------------------------- internet & unix support -
>  Heiko Schlittermann, Dipl.-Ing. (TU) - {fon,fax}: +49.351.802998{1,3} -
>  gnupg encrypted messages are welcome --------------- key ID: F69376CE -



-- 
Daniel Ferradal
HTTPD Project
#httpd help at Freenode

---------------------------------------------------------------------
To unsubscribe, e-mail: users-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