Skip to content

Modify rule S4790: Add Dart language #4980

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 19, 2025

Conversation

antonioaversa
Copy link
Contributor

Review

A dedicated reviewer checked the rule description successfully for:

  • logical errors and incorrect information
  • information gaps and missing content
  • text style and tone
  • PR summary and labels follow the guidelines

@antonioaversa antonioaversa force-pushed the antonio/DART-250-S4790-add-dart-language branch from a72fd49 to e13bcb3 Compare April 30, 2025 14:05
@antonioaversa antonioaversa force-pushed the antonio/DART-250-S4790-add-dart-language branch from e13bcb3 to 3fe1b08 Compare April 30, 2025 16:31
@antonioaversa antonioaversa marked this pull request as ready for review April 30, 2025 16:31
Copy link
Contributor

Choose a reason for hiding this comment

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

The convention for Security-Hotspots is to used "Sensitive" comment instead of "Noncompliant"

----
import 'package:crypto/crypto.dart';

final digest = sha1.convert(input).bytes; // Noncompliant

Choose a reason for hiding this comment

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

Suggested change
final digest = sha1.convert(input).bytes; // Noncompliant
final digest = sha1.convert(input).bytes; // Sensitive

----
import 'package:pointycastle/export.dart';

final digest = Digest('SHA-1'); // Noncompliant

Choose a reason for hiding this comment

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

Suggested change
final digest = Digest('SHA-1'); // Noncompliant
final digest = Digest('SHA-1'); // Sensitive

----
import 'package:cryptography/cryptography.dart';

final digest = Sha1(); // Noncompliant

Choose a reason for hiding this comment

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

Suggested change
final digest = Sha1(); // Noncompliant
final digest = Sha1(); // Sensitive

Copy link
Contributor

Choose a reason for hiding this comment

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

LGTM.
Reading SonarSource/sonar-dotnet#9180 (comment) I realize the description.adoc part is confusing because it mix Hash ans MAC algorithm in the same list.
I created #5007 to improve the text. The rule probably deserve even better content but I don't want to spend time on this today.
We can merge the change on this branch or on master. I let you decide.

@antonioaversa
Copy link
Contributor Author

LGTM. Reading SonarSource/sonar-dotnet#9180 (comment) I realize the description.adoc part is confusing because it mix Hash ans MAC algorithm in the same list. I created #5007 to improve the text. The rule probably deserve even better content but I don't want to spend time on this today. We can merge the change on this branch or on master. I let you decide.

Indeed. I merged into this PR, so that we have a single PR to merge onto master during implementation.

Copy link

sonarqube-next bot commented May 6, 2025

Quality Gate passed Quality Gate passed for 'rspec-tools'

Issues
0 New issues
0 Fixed issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

Copy link

sonarqube-next bot commented May 6, 2025

Quality Gate passed Quality Gate passed for 'rspec-frontend'

Issues
0 New issues
0 Fixed issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

@antonioaversa antonioaversa added this pull request to the merge queue May 19, 2025
Merged via the queue into master with commit 57b079d May 19, 2025
8 of 9 checks passed
@antonioaversa antonioaversa deleted the antonio/DART-250-S4790-add-dart-language branch May 19, 2025 17:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants