0

GLPI Agent HTTP 403 Error: "Access denied (invalid request (untrusted address))" when requesting /now endpoint

amangion 1 month ago 0

Hello everyone,

I am encountering an issue with the GLPI Agent when it tries to query the /now endpoint on a client machine.

In the PHP error log (/var/www/html/glpi/files/_log/php-errors.log), I see the following critical error:



==> /var/www/html/glpi/files/_log/php-errors.log <==

[2025-06-13 11:06:25] glpiphplog.CRITICAL: *** Uncaught Exception GuzzleHttp\Exception\ClientException: Client error: `GET http://pcwindows002:62354/now` resulted in a `403 Access denied (invalid request (untrusted address))` response:

run()

vendor/guzzlehttp/promises/src/Promise.php:224 GuzzleHttp\Promise\Promise->invokeWaitFn()

vendor/guzzlehttp/promises/src/Promise.php:269 GuzzleHttp\Promise\Promise->waitIfPending()

vendor/guzzlehttp/promises/src/Promise.php:226 GuzzleHttp\Promise\Promise->invokeWaitList()

vendor/guzzlehttp/promises/src/Promise.php:62 GuzzleHttp\Promise\Promise->waitIfPending()

vendor/guzzlehttp/guzzle/src/Client.php:165 GuzzleHttp\Promise\Promise->wait()

src/Agent.php:721 GuzzleHttp\Client->request()

src/Agent.php:770 Agent->requestAgent()

ajax/agent.php:56 Agent->requestInventory()

This indicates that the GLPI server receives a 403 Forbidden response with the message "Access denied (invalid request (untrusted address))" when trying to access the /now endpoint on the client.

I have verified the GLPI-Agent configuration on the client, specifically the httpd-trust setting, which includes the GLPI server IP and the client IP. However, the request is still rejected.

I suspect this might be related to IP trust configuration or authentication tokens required by the agent’s embedded HTTP server.

Has anyone experienced this issue or can provide guidance on how to correctly configure the GLPI Agent to accept requests from the GLPI server on the /now endpoint?

Thank you in advance for your help!