Open dsauvage opened 1 year ago
Thanks, sounds good.
@dsauvage : After reading again section "8.1 Persistent Connections" of RFC 2616 it seems that this is not correct. We don't have to close a connection in case of 304 or 404 error message. Can you please comment on the rational of this patch? TIA.
Description
As we can see in
src/core/aws-server-http_utils.adb:1596
S304
orS404
responses can be sent to the client without closing the connection, asWill_Close
is not set toTrue
in the case above.AWS is then vulnerable to Denial of Service attacks as all the server tasks can be easily set aside.
Using
Will_Close
insideSet_General_Header
without declaring it as a procedure in-parameter is error prone. Proposed patch fixes this issue by settingWill_Close
to True is the case above, and addingWill_Close
as an in-parameter to procedureSet_General_Header
Patch
aws-server-http_utils.adb.patch.txt