Please change in my code.
No. People here won't (and SHOULDN'T) do your work for you.
folks around here will bend over backwards to HELP YOU LEARN, and figure it out yourself. they'll point you in the right direction, give you tips and suggestions, make subtle corrections...
if you want somebody to write your code for you, i suggest you post under "jobs offered" and provide decent compensation.
otherwise... if you are having the user input the password from the command line, there's not much you can do (That i'm aware of). it's an OS problem, not a
java problem.
you could create a pop-up type window for entering a password - java supports the "*"s for that.