Sensitive Data In Logs (ARCH4160)
Esta página aún no está disponible en tu idioma.
Key java.logging.sensitive-data-in-logs · Severity error · Category logging
Logging sensitive data such as passwords, tokens, API keys, SSNs, or credit cards leaks those secrets into log sinks. Log files are often stored with weaker protection and broad access.
Incorrect
Section titled “Incorrect”log.info("Login attempt: user={} password={}", username, password);Correct
Section titled “Correct”log.info("Login attempt: user={}", username);Remove or mask sensitive fields from logs entirely; record only non-sensitive identifiers.