I was using readLine of BufferedReader to get input/new password from user, but wanted to mask the password so I am trying to use java.io.Con
Got this error message when running the application from Netbeans. Judging from the other answers, it seems this happens when running your application from an IDE. If you take a look at this question: Trying to read from the console in Java, it is because
Most IDEs are using javaw.exe instead of java.exe to run Java code
The solution is to use the command line/terminal to get the Console.