koltyakov/sp-pnp-node

Password shown in clear text when retrying failed connectivity with the pnp-ambient.js example

darrenparkinson opened this issue · 2 comments

After cloning the repository and going into the examples folder, I ran the pnp-ambient.js example. After the first run, it failed.

On the second run I removed the strategy configuration value from the private.json since the documentation here suggests that username/password are all that's required for SharePoint online.

On re-running the sample, it re-prompted me for all the details. The password was shown in clear text at the prompt.

Subsequently, I realised my username was entered incorrectly and strategy is now back in the config file and working.

I just thought I should bring it up, but there may be nothing to fix if you don't configure it incorrectly in the first place ;)

Thanks.

Hi there,

Thanks for using the lib and the interest. I've never faced password showing in a prompt in a clear text.

In node-sp-auth-config, password parameter has a 'password' type flag and should not be shown when prompts appear asking for missing auth parameters.

Can it be that password was in any other parameter, like secret or client keys?

Anyway, I'll take a look if a can reproduce it.

Andrew

I have been trying to reproduce without luck (or bad luck in this case).
So I assume that a misconfiguration took place and everything OK with the lib in this perspective.
Closing the issue. Feel free to reopen if it comes back.