Bad request 400 - HTTP API - Printable Version +- Logic Machine Forum (https://forum.logicmachine.net) +-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1) +--- Forum: Application Store (https://forum.logicmachine.net/forumdisplay.php?fid=11) +--- Thread: Bad request 400 - HTTP API (/showthread.php?tid=4243) |
Bad request 400 - HTTP API - Peter B. - 15.09.2022 Hi, we are using http api / base auth in our web application to communicate with Logic Machine. Everything worked just fine, but with latest LM fw update, we cannot log in from the web app to the LM anymore. Basically the CORS setting works ok, we have set the domain of the web app in the Services / Http server screen. The OPTIONS request from the web app gets the response 200 -> OK, but the following GET request just dies, LM returning an 400 - Bad request error. Nothing is logged anywhere, nor in the nginx error log (debug level). We traced that the request hits the lp-handler.lua, but what happens there is unknown (it's either bytecode, or otherwise not readable). Before the introduction of the CORS setting in the system menu of the LM, the web app was working fine. Our LM version: HW: LM5 Lite (i.MX6) SW: 20211215 Does anybody have similar experience? What would you suggest as next step in debugging? Is it possible to obtain the lp-handler.lua source? Thank you for any help or suggestion. Peter RE: Bad request 400 - HTTP API - admin - 16.09.2022 CORS seems to broken in this firmware. We can provide beta firmware with fixed CORS. RE: Bad request 400 - HTTP API - Peter B. - 16.09.2022 Hi, ok, that would be much appreciated. Thank you. RE: Bad request 400 - HTTP API - Peter B. - 19.09.2022 Hi. When aproximately can we expect this new FW please? Do you have my email address? Thx. RE: Bad request 400 - HTTP API - admin - 21.09.2022 Beta FW will be ready by the end of this week. Should it be sent to the email that you use for your forum account? RE: Bad request 400 - HTTP API - Peter B. - 21.09.2022 (21.09.2022, 13:17)admin Wrote: Beta FW will be ready by the end of this week. Should it be sent to the email that you use for your forum account? Yes, please. Thank you. RE: Bad request 400 - HTTP API - Zen - 06.10.2022 Hi admin, can you share the firmware here too? We got this problem too and we wanna try solve it. RE: Bad request 400 - HTTP API - admin - 06.10.2022 This is beta FW for LM5M3: https://dl.openrb.com/lm-22-imx6/lm5m3-20220922.img If you need it for another HW model then let me know. RE: Bad request 400 - HTTP API - Zen - 06.10.2022 (06.10.2022, 11:29)admin Wrote: This is beta FW for LM5M3: https://dl.openrb.com/lm-22-imx6/lm5m3-20220922.img Thanks for the fast response, our HW is LM5 Lite (i.MX6) RE: Bad request 400 - HTTP API - Daniel - 07.10.2022 Then you good to go with this version. RE: Bad request 400 - HTTP API - Zen - 07.10.2022 (07.10.2022, 07:25)Daniel Wrote: Then you good to go with this version. Thank you. We will go further try this and i'll let you know if we unlock the situation. Is there any guide about the 4 CORS origin string available to be written under the HTTP Server section in the LM5 config, eventually? Please let me know. BR RE: Bad request 400 - HTTP API - Zen - 23.11.2022 (07.10.2022, 18:07)Zen Wrote: Is there any guide about the 4 CORS origin string available to be written under the HTTP Server section in the LM5 config, eventually? Any news about this? (07.10.2022, 18:07)Zen Wrote: Is there any guide about the 4 CORS origin string available to be written under the HTTP Server section in the LM5 config, eventually? RE: Bad request 400 - HTTP API - Daniel - 23.11.2022 Google is your friend https://en.wikipedia.org/wiki/Cross-origin_resource_sharing CORS origin 1 – 4 Up to 4 IP addresses/hosts which can use CORS |