Page 1 of 1
ESP Easy: Failed HTTP code: 401 after upgrade to beta
Posted: Saturday 28 January 2023 16:23
by PieterS
Since yesterday I upgraded from last stable 2022.2 to beta 15006. Everything works fine except communication from ESP-devices to Domoticz.
As long as I configure the controller for Domoticz MQTT it works fine.
Devices which use Protocol Domoticz HTTP give the error HTTP : C001 192.168.1.18 GET... failed HTTP code: 401
Firmware on the ESP8266 is version mega-20220809_57b0c0c
I know that security is changed/improved but it should be nice to know how to configure ESP Easy.
So every hint is welcome.
Re: ESP Easy: Failed HTTP code: 401 after upgrade to beta
Posted: Saturday 28 January 2023 18:40
by Herman-H
Did you enter at the Controller tab , Credentials, your controller user and controller password?
Re: ESP Easy: Failed HTTP code: 401 after upgrade to beta
Posted: Saturday 28 January 2023 19:25
by PieterS
Thnx for reply.
Enabled Extended Credentials, checked username and password. Gave the device a reboot and checked the log of the ESP again. Still the same error..
No Authentication-error in the log of Domoticz..
Re: ESP Easy: Failed HTTP code: 401 after upgrade to beta
Posted: Saturday 28 January 2023 22:19
by Herman-H
I can't help you with this problem. But go to letscontrolit.com and ask TD-er or Ath for help
Re: ESP Easy: Failed HTTP code: 401 after upgrade to beta
Posted: Saturday 28 January 2023 23:45
by waltervl
If they are on the same network, did you add the IP adress of the ESP to trusted network? And if you use http and not https did you set
"Allow Basic Authentication over plain HTTP". Both options are in the security tab of Domoticz menu Setup -> Settings.
See wiki:
https://www.domoticz.com/wiki/Security
Re: ESP Easy: Failed HTTP code: 401 after upgrade to beta
Posted: Sunday 29 January 2023 10:59
by PieterS
I use the suggested Trusted Networks for years. Didn't change that. It's filled in as noted in the GUI.
@waltervl: Tried API protection before. Didn't mention that. Sorry.
But: I tried it again this morning. And YES!! Your hint works too!
So I thought at the reply of Herman.. I disabled Extended Credentials as API Protection is ON. And there is the error again: HTTP 401...
My lesson is: Both hints were usefull!
Use Extended Credentials and API Protection both Enabled
Thanks gentlemen
@waltervl: create a example about this case in the Wiki of Domoticz? That document is rather difficult to read for me/noobs.
Re: ESP Easy: Failed HTTP code: 401 after upgrade to beta
Posted: Sunday 29 January 2023 14:23
by waltervl
This is ESPeasy specific so someone should note this in the esp easy wiki. Beside that this is Domoticz beta behavior and not Domoticz stable.
Re: ESP Easy: Failed HTTP code: 401 after upgrade to beta
Posted: Wednesday 16 August 2023 9:55
by simat
I've only just had to use "Use Extended Credentials and API Protection both Enabled" after upgrading from 2023.1 to 2023.2 Stable.
Trusted networks had localhost and wildcard for local subnet.
127.0.0.1;10.0.32.*
ESPEasy was - ESP_Easy_mega_20230623_normal_ESP32_4M316k Jun 23 2023