Skip to content

Commit

Permalink
Add RSPEC content
Browse files Browse the repository at this point in the history
  • Loading branch information
jamie-anderson-sonarsource committed Nov 14, 2024
1 parent cfca020 commit 2f0210c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion rules/S7171/secrets/metadata.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "SECRET_TYPE should not be disclosed",
"title": "Mailgun SMTP credentials should not be disclosed",
"type": "VULNERABILITY",
"code": {
"impacts": {
Expand Down
16 changes: 11 additions & 5 deletions rules/S7171/secrets/rule.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,20 @@ exploiting the secret.

// Set value that can be used to refer to the type of secret in, for example:
// "An attacker can use this {secret_type} to ..."
:secret_type: secret
:secret_type: credentials

// Where possible, use predefined content for common impacts. This content can
// be found in the folder "shared_content/secrets/impact".
// When using predefined content, search for any required variables to be set and include them in this file.
// Not adding them will not trigger warnings.

//include::../../../shared_content/secrets/impact/some_impact.adoc[]
include::../../../shared_content/secrets/impact/phishing.adoc[]

include::../../../shared_content/secrets/impact/exceed_rate_limits.adoc[]

include::../../../shared_content/secrets/impact/suspicious_activities_termination.adoc[]



== How to fix it

Expand All @@ -31,9 +37,9 @@ include::../../../shared_content/secrets/fix/vault.adoc[]

=== Code examples

:example_secret: example_secret_value
:example_name: java-property-name
:example_env: ENV_VAR_NAME
:example_secret: aae73f3aa79607cabffe7cd69e37e478-058ba5af-d1a3a279
:example_name: mailgun.smtp.password
:example_env: MAILGUN_SMTP_PASSWORD

include::../../../shared_content/secrets/examples.adoc[]

Expand Down

0 comments on commit 2f0210c

Please sign in to comment.