Forum Discussion
Mohanad_313515
Nimbostratus
May 16, 2018iRule for disallow Request Content-Length in the header from being sent
Hello All,
I'm facing this issue "Request Content-Length differs from actual request body length"
I have contact with the dev team, they have a workaround to disallow this value in the header from being sent, can I do the same on the BIG-IP via iRule?
- Abdessamad1
Cirrostratus
It's better if the dev team fix their code to send the correct content length value.
If that's not possible, you can disable the violation from your ASM blocking settings.
Removing the header via irule might trigger other violations.
But you can also recalculate the length in an iRule:
when HTTP_REQUEST { if { [HTTP::method] eq "POST" } { HTTP::collect } } when HTTP_REQUEST_DATA { HTTP::header replace Content-Length [HTTP::payload length] }
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects