# HTTP request Unauthorized when Authentication is required

**URL:** <https://discourse.nodered.org/t/http-request-unauthorized-when-authentication-is-required/27027>\
**Category:** General\
**Created:** [21 May 2020 10:27 UTC](https://discourse.nodered.org/t/http-request-unauthorized-when-authentication-is-required/27027 "2020-05-21T10:27:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Marcos](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcos/32/18284_2.png) [@Marcos](https://discourse.nodered.org/u/Marcos)\
**Post date:** [21 May 2020 10:27 UTC](https://discourse.nodered.org/t/http-request-unauthorized-when-authentication-is-required/27027/1 "2020-05-21T10:27:21Z")

</div>

Hi guys,

Looking for something to elaborate a ui for a project a came into a problem in using “dynamically change config parameter of a node”. The problem happens with the http request and even if there are several discussion on the topic, I’ve been not able to find a solution.

As per [dynamically change config parameter of a node](https://flows.nodered.org/flow/6fe183c197b3464a1fe4d89744e068ff), this is my flow

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/3/6/368b35ccca2da90a5077778fe01b4755a0ce7a1d.png)

When I click the inject node, node-red reply with

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/5/3/53969180068adb04b1626d82a8136640634f2a38.png)

If I click Review Change I obtain this

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/7/87ed509c0e6028d9bc11512fe98f5b4a18d09906.png)

Then Review Changes again

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/3/1/31da9daee2b7a93f620bf4763290088fa48f11f9.png)

As you can see, it reports that something has changed: the port field has increased. Pushing on merge button and open again node settings I can see the change.

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/5/a5cb6411df0b911bb3bbf276ad21a8d66d384bd5.png)

(previously was 108) So I can now deploy as node red require.

Otherwise, if at the first step I click on Ignore, no deploy is required by node red but the change is not shown in the node settings until the next refresh of the browser page. No need to deploy. Pretty acceptable for my purpose.

By thinking to do this kind of changes from ui, I think an aspects need to be faced.

How can I can let http request have access to flow if authentication is enabled?

What it happens is that, when authentication (admin and password) is required to have access to node red, even if I use for http request “basic authentication” Type with correct user and password, the flow is able to access only to html source page but not to the flow itself and result is as per following image.

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/7/a7cfdda9449168cbedd7681557f0b2dd72d23b70.png)

Just a try with Digest Type give me “bad request” as payload.

Does anyone have a suggestion?

---

<div class="post-metadata">

**Author:** ![Marcos](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcos/32/18284_2.png) [@Marcos](https://discourse.nodered.org/u/Marcos)\
**Post date:** [1 June 2020 07:41 UTC](https://discourse.nodered.org/t/http-request-unauthorized-when-authentication-is-required/27027/2 "2020-06-01T07:41:06Z")

</div>

Hi Dears,  
So many other attempts I've performed since last time but no positive results I've obtained.  
Even if I bypass HTTP node and try an externally request I'm not able to be authenticated.  
It seems that, when authentication is enabled, it is not possible to reach the flow.  
Could anyone confirm this?

---

<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:** [31 July 2020 07:41 UTC](https://discourse.nodered.org/t/http-request-unauthorized-when-authentication-is-required/27027/3 "2020-07-31T07:41:15Z")

</div>

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