How to disable auth for a http-in node?

How i can disable authorization in use node "http-in"?


I want to sent data to Node-Red use GET request.

Up, help plz

You haven't given much to go on which is probably why you aren't getting much help.

THere are several ways in which authorisation could be added to http-in, either natively in Node-RED or externally via a reverse proxy.

Either way, you need to adjust the settings for that and exclude that path.

Hi @kastyan43

If you have used httpNodeAuth to setup basic username/password security, then there is no way to disable that for particular nodes. You either have it apply to everything, or nothing.

That is a limitation of the httpNodeAuth setting.

Alternative solutions do exist, but they get more complicated:

  • Running Node-RED behind a proxy which lets you apply the security more selectively outside of Node-RED
  • use the httpNodeMiddlerware setting to add a custom middleware (code) where you write the logic to selectively apply basic authentication based on the request arriving. I'm not aware of an example for this that we can point you at - unless someone else on the forum has done this.

I see you're using the add-on for Home Assistant. There's an option in the add-on config to disable authentication. See addon-node-red/DOCS.md at main · hassio-addons/addon-node-red · GitHub

Thank you friend, i try this but it not work.

certfile: fullchain.pem
credential_secret: secret
http_node:
password: mypass
username: myname
http_static:
password: pass
username: name
init_commands:
keyfile: privkey.pem
npm_packages:
ssl: false
system_packages:
theme: default
leave_front_door_open: true
dark_mode: false
require_ssl: false

work!! thank!