简体   繁体   中英

owasp sensitive data prevention in java

owasp sensitive data prevention in java

In my code I wrote following line and got A6-Sensitive Data Exposure- Heap Inspection

private String password;

How should I change this code for owasp sensitive data prevention in java?

Still not clear which tool gave you this warning at this line (it is unlikely that it was the dependency check). I can only guess the tool wants passwords to be stored in a char[] rather than a String .

The reasoning is that you can overwrite the password with blanks if it is no longer needed and therefore minimise the chance that it shows up in heap dumps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM