# Initializing config screen based on new config node

**URL:** <https://discourse.nodered.org/t/initializing-config-screen-based-on-new-config-node/7327>\
**Category:** Developing Nodes\
**Created:** [28 January 2019 09:07 UTC](https://discourse.nodered.org/t/initializing-config-screen-based-on-new-config-node/7327 "2019-01-28T09:07:33Z")\
**Posts on this page:** 1\
**Showing post:** 12

<div class="post-metadata">

**Author:** ![BartButenaers](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bartbutenaers/32/10476_2.png) [@BartButenaers](https://discourse.nodered.org/u/BartButenaers)\
**Post date:** [31 January 2019 23:48 UTC](https://discourse.nodered.org/t/initializing-config-screen-based-on-new-config-node/7327/12 "2019-01-31T23:48:23Z")

</div>

Hey Nick (@knolleary),  
The username seems quite easy, but the password content is not clear to me ...

This is the content of the `configNode.credentials` on the client-side (i.e. in the config screen):

- When I neither change the username nor the password, then credentials are **undefined**.

- When I only change the username to 'xxxx', then the credentials contain only the new username:  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/a/ac49035de0f4c92029caa21ea5d62ce8e2786e71.png)  
The password is not included, but the boolean shows a password is available (at the server-side).

- When I change the password to 'xxxx', then the credentials contain only the new password:  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/0/030d1b94e147dcc989ff0dbbc38bf791708af6bb.png)

- When I change both username and password, then the credentials contain both values.

- When I **append**'xxxx' to the original password, then the credentials contain a constant ` __PWDR___ ` (representing the password which is only known on the server side) combined with my newly added characters:  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/d/dab2423444f5f4fea2821d182cfb916232683676.png)  
Could still manage this one: when I send it to the server, I could replace the constant value by the real password value.

- But when I **replace** a few characters of the original password by 'xx', then _a part of the constant value will be replaced_ by my new characters:  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/b/b25e4cff335db420db6e3905244a1a0a204feec4.png)  
I have no clue how I could determine which part of the real original password is remained. Indeed if I'm not mistaken, the constant value is always ` __PWDR___ `, undependent of the length of my real original password. Which is of course great from a security perspective, but not for me ...

I see that other nodes (like mqtt) are also dealing with the constant value, but I don't see at first sight how to handle _partial replacements_ of the original password...

Do you have any other tips in your big magic box?

---

_[View the full topic](https://discourse.nodered.org/t/initializing-config-screen-based-on-new-config-node/7327)._
