This repository has been archived by the owner on Jun 16, 2022. It is now read-only.
Password salting #151
Labels
Backend
Changes are expected to be made to the service, repository, or controller level of Java source files
blocked
This issue is blocked by a pending PR or another issue that must be resolved first.
DevOps
Changes are expected to be made to IaaS manifests or low-level Java configuration bindings.
enhancement
New feature or request
Milestone
Summary
In production, passwords should be salted (+peppered) in addition to the existing hashing algorithm. The salt can be hardcoded through an environment variable in the dev stack and when testing, but in production the salt should come from an environment variable separate from our IaaS manifests.
Salting is a strong recommendation by the NIST, which serves as the foundation for the regulations associated with HIPAA. Applying peppering to passwords is also considered a good practice by the NIST.
Implementation
AuthenticationService
salt a new user's password based on the environment salt.AuthenticationService
pass through several fields from the UserDTO and use an environment variable to select which field will be used as the pepper.SecurityConfig.java
.SECURITY_SALT
environment variable on Heroku, GHA, and dev-stack.UserDTO
, and "pepper field" are passed in).The text was updated successfully, but these errors were encountered: