Move ban checking from WCF boot to middleware
authorTim Düsterhus <duesterhus@woltlab.com>
Mon, 8 Aug 2022 09:25:13 +0000 (11:25 +0200)
committerTim Düsterhus <duesterhus@woltlab.com>
Mon, 8 Aug 2022 09:29:03 +0000 (11:29 +0200)
commit51154ba3f8f1d09b54560d5d1933f9053ef409cb
treee00f866c5589fee7535341da1f699d5b3d8b44fb
parent3d2da94e5eeb34caca64b0ef94c83b9a6ee1164d
Move ban checking from WCF boot to middleware

The previous location in WCF made sense back when `initBlacklist()` also
checked the IP address, User-Agent, or hostname blocklist to prevent processing
the request as much as possible. As all these checks are gone now, the only
thing that remains is the inexpensive ban check.

Move it into a middleware, it does not really belong into WCF which should just
be responsible for booting the framework independently of the request in
question.
wcfsetup/install/files/lib/http/middleware/CheckUserBan.class.php [new file with mode: 0644]
wcfsetup/install/files/lib/system/WCF.class.php
wcfsetup/install/files/lib/system/WCFACP.class.php
wcfsetup/install/files/lib/system/request/RequestHandler.class.php