Skip to content

fix/cci upload rename#147

Open
markcrivera wants to merge 2 commits into
developfrom
fix/cci-upload-rename
Open

fix/cci upload rename#147
markcrivera wants to merge 2 commits into
developfrom
fix/cci-upload-rename

Conversation

@markcrivera
Copy link
Copy Markdown
Collaborator

No longer uses system defined temp dir to upload CCI matrix to. Now uploads directly to configured dir.

Signed-off-by: Mark Rivera <mcrivera@gmail.com>
@markcrivera markcrivera changed the title Fix/cci upload rename fix/cci upload rename May 15, 2025
@Amndeep7 Amndeep7 temporarily deployed to tir-fix-cci-upload-rena-s9zz1p May 15, 2025 19:18 Inactive
Comment thread server/utils/hash.ts

export function hashPassword(password: string, salt: string, secretKey: string): string {
const hmac = crypto.createHmac("sha256", secretKey);
hmac.update(password);

Check failure

Code scanning / CodeQL

Use of password hash with insufficient computational effort

Password from [an access to INIT_PASSWORD](1) is hashed insecurely. Password from [an access to INIT_PASSWORD](2) is hashed insecurely. Password from [an access to inputPassword](3) is hashed insecurely. Password from [an access to password](4) is hashed insecurely.
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think CodeQL may be indavertantly flagging on hmac.update.

hmac.upadate(password) is an intermediate step, not the final hash.

We are HMAC-ing the password with a secretKey using SHA-256 (not a weak hash like MD5 or SHA-1 stated in the Show more details).

We are feeding the result into PBKDF2, recommended by NIST and OWASP and has FIPS-140 validated implementations,.

We are using 600000 iterations which exceeds NIST requirements (>10,000) and is the recommended # of iterations by OWASP when using PBKDF2-HMAC-SHA256.

@markcrivera markcrivera changed the base branch from main to develop May 15, 2025 20:00
@markcrivera markcrivera marked this pull request as draft May 19, 2025 13:22
@mitre mitre deleted a comment from sonarqubecloud Bot May 19, 2025
@markcrivera markcrivera marked this pull request as ready for review May 19, 2025 14:46
Signed-off-by: Mark Rivera <mcrivera@gmail.com>
@sonarqubecloud
Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants