private transient String password;
Diving deeper into the Java transient modifier
Enrique López Mañas

I know it is just an example, but maybe would help someone: given that strings are immutable in java, it is better to keep passwords in memory like char[] so you can destroy it anytime.

thanks for the article.

Like what you read? Give Kirill Rozhenkov a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.