atom feed28 messages in ru.sysoev.nginxNginx feature request
FromSent OnAttachments
Hendrik HardemanFeb 10, 2008 12:55 am 
Bedros HanounikFeb 10, 2008 8:54 am 
Manlio PerilloFeb 10, 2008 9:05 am 
Hendrik HardemanFeb 10, 2008 10:37 am 
Hendrik HardemanFeb 10, 2008 10:54 am 
Manlio PerilloFeb 10, 2008 11:16 am 
Manlio PerilloFeb 10, 2008 11:34 am 
Hendrik HardemanFeb 10, 2008 12:18 pm 
Hendrik HardemanFeb 10, 2008 12:24 pm 
Manlio PerilloFeb 10, 2008 12:31 pm 
eliottFeb 10, 2008 1:13 pm 
Hendrik HardemanFeb 10, 2008 1:39 pm 
Adam ZellFeb 10, 2008 1:49 pm 
Manlio PerilloFeb 10, 2008 2:13 pm 
Hendrik HardemanFeb 10, 2008 2:21 pm 
Hendrik HardemanFeb 10, 2008 2:43 pm 
Cliff WellsFeb 11, 2008 4:10 pm 
Hendrik HardemanFeb 11, 2008 6:29 pm 
Cliff WellsFeb 11, 2008 7:10 pm 
Hendrik HardemanFeb 12, 2008 2:13 am 
Roger PackApr 21, 2009 7:42 am 
Igor SysoevApr 21, 2009 1:10 pm 
Joe BofhApr 21, 2009 3:58 pm 
Delta YehApr 21, 2009 6:56 pm 
Igor SysoevApr 21, 2009 11:32 pm 
Igor SysoevApr 22, 2009 12:16 am 
Joe BofhApr 22, 2009 12:33 am 
Igor SysoevApr 22, 2009 5:38 am 
Subject:Nginx feature request
From:Hendrik Hardeman (hend@public.gmane.org)
Date:Feb 10, 2008 12:55:38 am
List:ru.sysoev.nginx

Hi all,

Discovered Nginx a few weeks back. After some experimenting I have come to the
conclusion that Nginx really is very very good.

I have a small feature request:

I have a set of static files (html and others) which I want to make available only from a certain date/time. Inspired by the rewrite module, this morning I thought of a simple method to control access to such files.

My idea was to set the file creation/modification time of the static files in the future, i.e. the date/time from which they can be made available (e.g. I could use the touch tool to set the appropriate date/time). I could then do something like

if (!-f $request_filename) {return 404;} if ($date_gmt < fct($request_filename)) {return 403;}

Unfortunately, I haven't found a way to get at the file creation/modification time (please do let me know if I overlooked something). The 'fct' in my example is an imaginary function which returns the file creation time in the same format as $date_gmt (presumably unix epoch timestamp)

An even better way to handle this would be to have a directive in the core module which disallows serving files which have a creation/modification time in the future. I could then use:

location /ftc/ { filetime_check on; }

to disallow serving of files with a filetime in the future for that location.
Files would then automatically become available once the request time >=
filetime. This way access to certain files could be controlled in a very
straightforward and transparent way - and with a simple 'touch'.

Though I'd definitely prefer a directive for the above purpose, access to file creation/modification time (through variable or function) could still be useful in the rewriting or ssi module.

Anyone any other suggestions ?

Thanks,

_________________________________________________________________ Post ads for free - to sell, rent or even buy.www.yello.in http://ss1.richmedia.in/recurl.asp?pid=186