Re: HttpAccessKeyModule или HttpSecureLinkModule
    Gena Makhomed 
    gmm at csdoc.com
       
    Thu Jul  4 11:18:39 UTC 2013
    
    
  
On 04.07.2013 13:21, Андрей Урядов wrote:
> set $fileName '';
> set $secretKey '';
> if ($request_uri ~* ^/path_to_files/([0-9a-z]+)/(.+)$) {
>          set $fileName $2;
>          set $secretKey $1;
> }
> set $rightKey 0;
> if (-f /path_to_download_keys/download_key/$remote_addr-$secretKey) {
>        set $rightKey 1;
>        rewrite ^(.*)$ /path_to_files/$fileName break;
> }
> if ( $rightKey != 1) {
>        return 404;
> }
http://nginx.org/ru/docs/http/ngx_http_secure_link_module.html
-- 
Best regards,
  Gena
    
    
Подробная информация о списке рассылки nginx-ru