[SERVER-24391] Prompt for password on user creation or password change via the shell Created: 03/Jun/16  Updated: 08/Jan/24  Resolved: 27/Jul/18

Status: Closed
Project: Core Server
Component/s: Security
Affects Version/s: None
Fix Version/s: 4.1.2

Type: New Feature Priority: Major - P3
Reporter: Davenson Lombard Assignee: Kashish Garg
Resolution: Done Votes: 0
Labels: platforms_security
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Documented
is documented by DOCS-11990 Docs for SERVER-24391: Prompt for pas... Closed
Related
is related to SERVER-3788 version of auth() that prompts for pa... Closed
is related to SERVER-36803 Ability to prompt for user input in s... Closed
is related to SERVER-36802 Don't omit db.auth() et al from shell... Closed
Backwards Compatibility: Fully Compatible
Sprint: Platforms 2018-07-30
Participants:

 Description   

When a user is created or when we update a password in the shell, the password is in plain text.

Can we have a way to mask password on user creation? For example, by prompting for the password with echo off.

Such feature could also be implemented on password change.



 Comments   
Comment by Kevin Pulo [ 22/Aug/18 ]

This is great, but not wired into db.auth(), db.createUser(), etc. This might be done on SERVER-3788, but in the meantime the way to do it manually is to call passwordPrompt() wherever the password string would ordinarily be specified, eg. something like:

db.createUser( { user: "myusername", pwd: passwordPrompt() } )
db.auth("myusername", passwordPrompt())

Comment by Githook User [ 27/Jul/18 ]

Author:

{'name': 'Kashish Garg', 'email': 'kashish.garg@mongodb.com'}

Message: SERVER-24391 Prompt for password on user creation or password change via the shell
Branch: master
https://github.com/mongodb/mongo/commit/077a5b00937a539ef004f986ac08f9c51cf0e92e

Generated at Thu Feb 08 04:06:14 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.