Closed MysticalMount closed 8 months ago
UPDATED with correct resolution:
Ok so the "not allowed" means that the "API like" endpoints do require a token in order to work.
That token can only be gotten by logging in, and then reading a hidden div element in the return HTML.
If you get your password wrong, it will look like the HTML parse is failing to retrieve the token.
Realising this narrowed it down for me, enabled password, and got the right one!
Closing as above
Versions
Pi-hole version is v5.17.3 (Latest: v5.17.3) web version is v5.21 (Latest: null) FTL version is v5.25.1 (Latest: null)
Platform
Docker pihole/pihole:latest
Host OS Ubuntu 22.04
Note: I have changed the default port from 80 to 21000 as the server Im running it on doesnt have 80 available
Expected behavior
When authenticated the endpoint responds.
Actual behavior / bug
Persistently get: Not allowed (login session invalid or expired, please relogin on the Pi-hole dashboard)!
Dashboard/UI is working fine every single link, but for external-dns (Kubernetes) to work we require this endpoint to manipulate the local DNS.
Steps to reproduce
Steps to reproduce the behavior:
Deploy latest via Docker, try to access: /admin/scripts/pi-hole/php/customdns.php
Debug Token