Return a HttpResponse instead of an exception on NUL in query string parameters
authorMagnus Hagander <magnus@hagander.net>
Thu, 4 Nov 2021 16:07:50 +0000 (17:07 +0100)
committerMagnus Hagander <magnus@hagander.net>
Thu, 4 Nov 2021 16:10:59 +0000 (17:10 +0100)
commit37a5e6640319eddce61798dcaf3326c98b6fdccf
tree98e9406f48da55374dcfaddf6e86c66bd3d7290a
parentc4b2b65e8a9fc1bb60e5b7c1d80fbb7d3f807a44
Return a HttpResponse instead of an exception on NUL in query string parameters

Raising an exception triggers an email-to-admin-action, and the whole
reason we have this NUL check is to *avoid* triggering those emails...
Hopefully explicitly returning a 400 HttpResponse will maek them go
away.
pgweb/util/middleware.py