Support

Admin Tools

#43428 Type error when logging a blocked attempt (escapeLogLine() null value in first parm)

Posted in ‘Admin Tools for Joomla!’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
5.4.10
PHP version
8.3.6
Admin Tools version
10.4.0

Latest post by nicholas on Monday, 19 October 2026 10:28 CDT

fdinkler

Getting php errors reported when Admin Tools blocks a WordPress bot probing attack.

Reference the stack trace email results below...

Admin Tools’ DFI Shield (DFIShield::onAfterRoute) flagged the request and called blockRequest().

While logging the block, escapeLogLine() got null where it requires a string, so PHP 8 threw a TypeError. The likely cause is one of the spoofed or empty values (probably something in the header data) coming through as null.

So the plugin’s bug is real, but the bot triggered it. The block itself was working as intended. The side effects are that the request wasn’t logged properly and I got an error email.

A PHP Exception occurred on your site. Here you can find the stack trace:

Exception Type: TypeError
File: /var/www/grbr/plugins/system/admintools/src/Utility/BlockedRequestHandler.php
Line: 889
Message: Akeeba\Plugin\System\AdminTools\Utility\BlockedRequestHandler::escapeLogLine(): Argument #1 ($value) must be of type string, null given, called in /var/www/grbr/plugins/system/admintools/src/Utility/BlockedRequestHandler.php on line 863

#0 /var/www/grbr/plugins/system/admintools/src/Utility/BlockedRequestHandler.php(863): Akeeba\Plugin\System\AdminTools\Utility\BlockedRequestHandler->escapeLogLine()
#1 /var/www/grbr/plugins/system/admintools/src/Utility/BlockedRequestHandler.php(173): Akeeba\Plugin\System\AdminTools\Utility\BlockedRequestHandler->logRequestToFile()
#2 /var/www/grbr/plugins/system/admintools/src/Utility/BlockedRequestHandler.php(217): Akeeba\Plugin\System\AdminTools\Utility\BlockedRequestHandler->logRequest()
#3 /var/www/grbr/plugins/system/admintools/src/Feature/DFIShield.php(79): Akeeba\Plugin\System\AdminTools\Utility\BlockedRequestHandler->blockRequest()
#4 /var/www/grbr/plugins/system/admintools/src/Extension/AdminTools.php(844): Akeeba\Plugin\System\AdminTools\Feature\DFIShield->onAfterRoute()
#5 /var/www/grbr/plugins/system/admintools/src/Extension/AdminTools.php(268): Akeeba\Plugin\System\AdminTools\Extension\AdminTools->runVoidFeature()
#6 /var/www/grbr/libraries/vendor/joomla/event/src/Dispatcher.php(454): Akeeba\Plugin\System\AdminTools\Extension\AdminTools->onAfterRoute()
#7 /var/www/grbr/libraries/vendor/joomla/application/src/AbstractApplication.php(99): Joomla\Event\Dispatcher->dispatch()
#8 /var/www/grbr/libraries/src/Application/SiteApplication.php(811): Joomla\Application\AbstractApplication->dispatchEvent()
#9 /var/www/grbr/libraries/src/Application/SiteApplication.php(243): Joomla\CMS\Application\SiteApplication->route()
#10 /var/www/grbr/libraries/src/Application/CMSApplication.php(304): Joomla\CMS\Application\SiteApplication->doExecute()
#11 /var/www/grbr/includes/app.php(58): Joomla\CMS\Application\CMSApplication->execute()
#12 /var/www/grbr/index.php(51): require_once('...')
#13 {main}
Request information GET variables
Array
(
    [rest_route] => /
)
POST variables
Array
(
)
COOKIE variables
Array
(
    [8f19ab96ad7a9b10f5b7229b09f332fa] => uvor7r6q3pads9623a3naf5os4
)
REQUEST variables
Array
(
    [rest_route] => /
)
SERVER variables
Array
(
    [HTTPS] => on
    [SSL_TLS_SNI] => renoballoonregistration.com
    [HTTP_HOST] => renoballoonregistration.com
    [HTTP_USER_AGENT] => Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)
    [HTTP_ACCEPT] => text/html,application/xhtml+xml,*/*;q=0.8
    [HTTP_COOKIE] => 8f19ab96ad7a9b10f5b7229b09f332fa=uvor7r6q3pads9623a3naf5os4
    [HTTP_FORWARDED] => for="[::1]"
    [HTTP_REFERER] => http://renoballoonregistration.com/?rest_route=/
    [HTTP_TRUE_CLIENT_IP] => ::1
    [HTTP_X_CLIENT_IP] => ::1
    [HTTP_X_FORWARDED_FOR] => ::1
    [HTTP_X_FORWARDED_HOST] => renoballoonregistration.com
    [HTTP_X_ORIGINAL_URL] => /?rest_route=/
    [HTTP_X_ORIGINATING_IP] => ::1
    [HTTP_X_REAL_IP] => ::1
    [HTTP_X_REMOTE_ADDR] => ::1
    [HTTP_ACCEPT_ENCODING] => gzip
    [PATH] => /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin
    [SERVER_SIGNATURE] => <address>Apache/2.4.58 (Ubuntu) Server at renoballoonregistration.com Port 443</address>
 
    [SERVER_SOFTWARE] => Apache/2.4.58 (Ubuntu)
    [SERVER_NAME] => renoballoonregistration.com
    [SERVER_ADDR] => 172.26.7.157
    [SERVER_PORT] => 443
    [REMOTE_ADDR] => 45.148.10.9
    [DOCUMENT_ROOT] => /var/www/grbr
    [REQUEST_SCHEME] => https
    [CONTEXT_PREFIX] => 
    [CONTEXT_DOCUMENT_ROOT] => /var/www/grbr
    [SERVER_ADMIN] => [email protected]
    [SCRIPT_FILENAME] => /var/www/grbr/index.php
    [REMOTE_PORT] => 52474
    [GATEWAY_INTERFACE] => CGI/1.1
    [SERVER_PROTOCOL] => HTTP/1.1
    [REQUEST_METHOD] => GET
    [QUERY_STRING] => rest_route=/
    [REQUEST_URI] => /?rest_route=/
    [SCRIPT_NAME] => /index.php
    [PHP_SELF] => /index.php
    [REQUEST_TIME_FLOAT] => 1792421560.4033
    [REQUEST_TIME] => 1792421560
)

nicholas
Akeeba Staff
Manager

This appears to be due to a latent bug in file logging which has existed throughout Admin Tools 7 ever since its first release in 2021. Version 7.9.3 implemented a change so that a bug like that isn't silently ignored, but raised as a TypeException. However, the release 7.9.3 version did not include the second part of the fix which addressed the root cause and, crucially, also included the missing integration tests for this feature.

The fix will be included in 7.9.4. In the meantime, you can set "Keep a debug log file" to No.

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!