I'm trying to build a command line application where a user will be asked for their name and password but I want to mask the password using '*'. I looked into many posts and saw many of them using System.console() to use the readpassword() functionality, however, in the IDE environment, System.console() returns null and thus my program crashes. How can I overcome this? I want to be able to read the password without displaying what the user is actually typing in.
Edit: The other posts that I've read Link addressed this issue but the solution seems unclear to me.
Any form of help will be appreciated. Thank you.