# Node-RED - password for ui dashboard

**URL:** https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637
**Category:** Dashboard
**Created:** [17 December 2020 10:38 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637 "2020-12-17T10:38:38Z")
**Posts on this page:** 11
**Page:** 1

<div class="post-metadata">

### Author: ![Lance99](https://avatars.discourse-cdn.com/v4/letter/l/6de8d8/32.png) [@Lance99](https://discourse.nodered.org/u/Lance99)
#### Post date: [17 December 2020 10:38 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/1 "2020-12-17T10:38:38Z")

</div>

I have made a dashboard for a client. They really do not like that anyone who have the url can access the dashboard. How can I secure the ui with a passord?  
I have implemented a password for entering the dashboad editor.

---

<div class="post-metadata">

### Author: ![fellinga](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/fellinga/32/30631_2.png) [@fellinga](https://discourse.nodered.org/u/fellinga)
#### Post date: [17 December 2020 10:43 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/2 "2020-12-17T10:43:56Z")

</div>

Please see: [https://nodered.org/docs/user-guide/runtime/securing-node-red](https://nodered.org/docs/user-guide/runtime/securing-node-red)

It's the httpNodeAuth setting.

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [17 December 2020 10:54 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/3 "2020-12-17T10:54:30Z")

</div>

Or put it behind a reverse proxy to secure it.

---

<div class="post-metadata">

### Author: ![Lance99](https://avatars.discourse-cdn.com/v4/letter/l/6de8d8/32.png) [@Lance99](https://discourse.nodered.org/u/Lance99)
#### Post date: [17 December 2020 10:58 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/4 "2020-12-17T10:58:22Z")

</div>

Thanks! Is it complicated to install? I'm new into Node-Red ....

---

<div class="post-metadata">

### Author: ![Lance99](https://avatars.discourse-cdn.com/v4/letter/l/6de8d8/32.png) [@Lance99](https://discourse.nodered.org/u/Lance99)
#### Post date: [17 December 2020 11:00 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/5 "2020-12-17T11:00:51Z")

</div>

I run the Node-RED on a VM in Azure. How do move forward with reverse proxy?

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [17 December 2020 11:09 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/6 "2020-12-17T11:09:14Z")

</div>

There are several ways with Azure. You can add a service to your VM like NGINX, Caddy, Apache or some other web server or you could run HAproxy. All can be configured as a reverse proxy, there are instructions for Node-RED floating around, a web search should turn them up. Remember to proxy websockets as well.

You can, in fact run Node-RED as an Azure web app as well, in that case, you use IIS as a reverse proxy and this happens by default which makes it really easy to secure and you can use your Azure Active Directory to provide identity management. If you are running a Windows VM, you can do the same.

Of course, you should also be ensuring that Node-RED either uses HTTPS natively or that the proxy terminates HTTPS. Never use authentication without HTTPS. If you use Caddy, it has built-in Let's Encrypt integration.

* * *

If you don't know how to secure web services to the Internet, I strongly recommend getting a professional to check and improve the security configuration. The above is friendly information and isn't intended to be "Secure". It is very easy to get security wrong.

---

<div class="post-metadata">

### Author: ![fellinga](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/fellinga/32/30631_2.png) [@fellinga](https://discourse.nodered.org/u/fellinga)
#### Post date: [17 December 2020 11:30 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/7 "2020-12-17T11:30:36Z")

</div>

@Lance99 It's not complicated to just enable the httpNodeAuth, you just have to uncomment the correct line of code within the settings.js file (it's line 136 in my case), restart node-red and everyone should be prompted to enter a password.

@TotallyInformation you are right, but since this whole thing is already running.... httpNodeAuth would already add security, even on http (if they choose a password that is not used somewhere else) within minutes. He can then of course add more things like https etc.

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [17 December 2020 17:51 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/8 "2020-12-17T17:51:17Z")

</div>

> [@fellinga](#):
>
> @Lance99 It's not complicated to just enable the httpNodeAuth, you just have to uncomment the correct line of code within the settings.js file (it's line 136 in my case), restart node-red and everyone should be prompted to enter a password.

I'm afraid this is going to result in both unhappy customers and unhappy OP. Because just enabling a password is certainly not enough for an Internet connected instance of Node-RED.

> [@fellinga](#):
>
> but since this whole thing is already running.... httpNodeAuth would already add security, even on http (if they choose a password that is not used somewhere else) within minutes. He can then of course add more things like https etc.

No, I'm afraid it wouldn't be enough. Doing so will result in the password being presented in clear-text over the Internet. That will get cached in the local browser and at every cache point between the user and the server.

Please, **ALWAYS** enable https **FIRST** not last.

There are, of course, also other reasons for always wanting to present services over https but that is for a different discussion.

---

<div class="post-metadata">

### Author: ![Lance99](https://avatars.discourse-cdn.com/v4/letter/l/6de8d8/32.png) [@Lance99](https://discourse.nodered.org/u/Lance99)
#### Post date: [18 December 2020 09:12 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/9 "2020-12-18T09:12:38Z")

</div>

Currently I'm running one VM with password for the Node-RED editor. And one other VM has no password for entering the editor.  
Should I install password for the editor, before I enable httpNodeAuth?

By the way, the two dashboards I'm doing contain no critical information for the client. They can live with no password, but would be happy if its possible in the near future.

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [18 December 2020 20:12 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/10 "2020-12-18T20:12:33Z")

</div>

> [@Lance99](#):
>
> By the way, the two dashboards I'm doing contain no critical information for the client. They can live with no password, but would be happy if its possible in the near future.

If you leave the editor open, we've previously seen hacked versions of Node-RED. It can be used to attack other machines, spread malware, do phishing. It can also be used to gain a foothold in your VM. It could also be used to pass malware to your clients. The probably wouldn't be too happy then.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [17 January 2021 20:12 UTC](https://discourse.nodered.org/t/node-red-password-for-ui-dashboard/37637/11 "2021-01-17T20:12:39Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
