-
Notifications
You must be signed in to change notification settings - Fork 37
Open
Labels
questionFurther information is requestedFurther information is requested
Description
There is an issue when you try to access the API explorer IP/api/index.php/explorer/:
Access refused to 172.18.0.1 by SQL or Script injection protection in main.inc.php:analyseVarsForSqlAndScriptsInjection type=2
Try to go back, fix data of your form and resubmit it. You can contact also your technical support.
By default it redirects to http://0.0.0.0/api/index.php/:/api/index.php/explorer/ which contains a : which then triggers the error above.
Current work around:
sudo docker exec -it dolibarr-docker-web-1 bash
nano /var/www/html/conf/conf.phpThis happens when the configuration file sets:
<?php
$dolibarr_main_url_root='://0.0.0.0';
$dolibarr_main_document_root='/var/www/html';
$dolibarr_main_url_root_alt='/custom';
$dolibarr_main_document_root_alt='/var/www/html/custom';
$dolibarr_main_data_root='/var/www/documents';
...Then change:
$dolibarr_main_url_root='://0.0.0.0';into:
$dolibarr_main_url_root='http://0.0.0.0';Then restart your container and you should be able to access IP/api/index.php/explorer/
This was done and tested on Kubuntu 24.04 kernel 6.14.0-27-generic.
Metadata
Metadata
Assignees
Labels
questionFurther information is requestedFurther information is requested