# Is it possible to skip request body and send a response?

**URL:** <https://www.ruby-forum.com/t/is-it-possible-to-skip-request-body-and-send-a-response/221325>\
**Category:** NGINX\
**Created:** [July 9, 2012, 9:07am UTC](https://www.ruby-forum.com/t/is-it-possible-to-skip-request-body-and-send-a-response/221325 "2012-07-09T09:07:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![aris](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/258eb7/32.png) [@aris](https://www.ruby-forum.com/u/aris)\
**Post date:** [July 9, 2012, 9:07am UTC](https://www.ruby-forum.com/t/is-it-possible-to-skip-request-body-and-send-a-response/221325/1 "2012-07-09T09:07:46Z")

</div>

I’m using access\_by\_lua function to authorize request before starting  
upload process, It works just awesome. But in case when request is not  
authorized I would like to send a response skipping the stage of reading  
request body. Is this possible in theory or does this contradicts  
rfc2616? Currently I can only close connection by discarding the request  
body with lingering\_timeout set to zero.

Thanks for any help.

Posted at Nginx Forum:

> **[Is it possible to skip request body and send a response?](https://forum.nginx.org/read.php?2,228422,228422#msg-228422)**
>
> I'm using access\_by\_lua function to authorize request before starting upload process, It works just awesome. But in case when request is not authorized I would like to send a response skipping the stage of reading request body. Is this possible in...
