List for cgit developers and users
 help / color / mirror / Atom feed
* cgit cache wrong content response http ./. https
@ 2018-11-27 15:34 DLange
  0 siblings, 0 replies; only message in thread
From: DLange @ 2018-11-27 15:34 UTC (permalink / raw)


Hi,

cgit bases the cache slot to use solely on ctx.qry.raw:

	err = cache_process(ctx.cfg.cache_size, ctx.cfg.cache_root,
		ctx.qry.raw, ttl, process_request);

Thus running cgit on a website with http:// _and_ https:// results in
the wrong schema being returned if the cache content from the "other
protocol" is not yet expired and the content contains cgit generated URLs.
This is the case for the atom feeds and for the repository home pages
where the "Atom feed" URL of the repository commits is contained.

The cache key used to select the slot should include the protocol (at
least for these pages) to prevent returning the wrong content.

Kind regards,
Daniel


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2018-11-27 15:34 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-27 15:34 cgit cache wrong content response http ./. https DLange

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).