There is no way to make particular portion of command line input to be protected with asterisks - command line input is just plain text.
Options
- store password in a file so it is not visible in the input. The question now is how to protect that file but may work for some cases - i.e. specify encrypted password similar to encrypted settings in web.config
- require user to type password in
- instead password require user to log in with that account (for Windows auth)
- if there is some way to get short-lived token (i.e. using OAUTH) - you may use that in clear text instead of password