Another relatively safe strategy : Don't buffer http data on server. Read a limited sized header and then stream the body to its request handler.
Hell, a streaming consumer which doesn't require and check the content-length might even spin forever on CPU if a malicious client keeps sending data.