I would suggest that you still password protect the editor even if you have hidden your node-red from the outside world. Your cat may attempt to hack you from within your network.
If you want to test the hashing time duration on your machine when using different costs, you can play with these flows. Warning, the function node will require the installation of bcrypt
which may or may not already be installed on your system.
[{"id":"02ad12a4dd3bb656","type":"function","z":"bf43e3aa151c3e51","name":"bcrypt hash","func":"const { hash } = bcrypt;\n\nconst start = Date.now();\n\nmsg.hash = await hash(msg.password, msg.cost);\n\nmsg.duration = Date.now() - start;\n\nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[{"var":"bcrypt","module":"bcrypt"}],"x":370,"y":220,"wires":[["8d464f555326b98d"]]},{"id":"47c177b7330ab163","type":"inject","z":"bf43e3aa151c3e51","name":"","props":[{"p":"password","v":"5up3r 53cr3t pa55w0rd","vt":"str"},{"p":"cost","v":"16","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":170,"y":220,"wires":[["02ad12a4dd3bb656"]]},{"id":"8d464f555326b98d","type":"debug","z":"bf43e3aa151c3e51","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":570,"y":220,"wires":[]},{"id":"4c1503c8e7b7592f","type":"inject","z":"bf43e3aa151c3e51","name":"","props":[{"p":"password","v":"5up3r 53cr3t pa55w0rd","vt":"str"},{"p":"hash","v":"$2b$16$4nWRWwHiEufnUV.o3K7e0uwhT4x9G7wKsfXL9RsDZvXrLqsYFFJQG","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":170,"y":300,"wires":[["7fe9f0d5f22f37a4"]]},{"id":"7fe9f0d5f22f37a4","type":"function","z":"bf43e3aa151c3e51","name":"bcrypt compare","func":"const { compare } = bcrypt;\n\nconst start = Date.now();\n\nmsg.compare = await compare(msg.password, msg.hash);\n\nmsg.duration = Date.now() - start;\n\nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[{"var":"bcrypt","module":"bcrypt"}],"x":380,"y":300,"wires":[["bb78be24f86cbd23"]]},{"id":"bb78be24f86cbd23","type":"debug","z":"bf43e3aa151c3e51","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":570,"y":300,"wires":[]}]
results from my pi4:
password: "5up3r 53cr3t pa55w0rd"
cost: 16
hash: "$2b$16$jelKXI4R3WsJtCGWThEk4OUO2brGAmZXeMUlCEgY.cMrA0oZ6v/66"
duration: 8253
And then later when using this password, node-red took about 8 seconds to authenticate me and start the session. The only delay is on the initial login. That would make any brute force attempt to take much longer. Further testing showed me that the default cost of 8 only takes about 30 milliseconds to hash the password, versus 8000 milliseconds.