<div dir="ltr"><div><div><div>Hello,<br><br></div>I have created perl NGINX module to server static files on the NGINX (mainly images). For security reasons I am generating the AES:CBC encrypted url which I am decrypting on the NGINX and serving the file via NGINX perl module. The problem is that I am sometimes getting the bellow response with HTTP response code set to 000:<br>
<br><br><font face="courier new,monospace">XX.XX.XX.XX - - [01/Sep/2013:01:20:37 +0400] "GET /media/u5OU/NRkImrrwH/TThHe7hns5bOEv+Aou2/VJ8YD/ts= HTTP/1.1" <span style="color:rgb(255,0,0)"><b><u>000</u></b></span> 39078 "<a href="http://gruppu.com/full/JcbyEJTb8nMh+YH0xSg1jgl4N7vWQi2xBPep7VcJmD8=" target="_blank">http://XXXX/full/JcbyEJTb8nMh+YH0xSg1jgl4N7vWQi2xBPep7VcJmD8=</a>" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:23.0) Gecko/20100101 Firefox/23.0"<br>
<br><br></font></div><font face="courier new,monospace"><font face="arial,helvetica,sans-serif">The way how I handle the url in the perl module is :<br><br><font face="courier new,monospace"><font face="arial,helvetica,sans-serif">In case the file is found:</font><br>
$r->sendfile($fileresult[0]);<br>$r->flush();</font><br></font></font></div><font face="courier new,monospace"><font face="arial,helvetica,sans-serif"></font></font><div>
<div><font face="courier new,monospace">return OK;<br><br></font></div><div><font face="courier new,monospace"><font face="arial,helvetica,sans-serif">else:<span style="font-family:courier new,monospace"><br>$r->status(404);<br>
return DECLINED;</span><br></font></font></div><div><font face="courier new,monospace"><br><br></font></div><div><font face="courier new,monospace"><font face="arial,helvetica,sans-serif">My question is if I am sending the files correctly or is there any other specific value i should send back from perl (besides returning OK). <br>
<br>If needed I can send the nginx.conf. <br><br><br>Thanks for your help. <br><br>Regards,<br><br><br>Jorge<br></font></font></div></div></div>