question: private String anonymizePassword ( String password ) { if ( password == null ) { return "null" ; } StringBuilder sb = new StringBuilder ( ) ; for ( int i = 0 ; i < password . length ( ) ; i ++ ) { sb . append ( '*' ) ; } return sb . toString ( ) ; }
target:  Make a password into asterisks of the right length, for logging. 