Skip to content

Test neutral check #24

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .github/workflows/test-status.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Create Neutral Status
on: push

jobs:
neutral-check:
runs-on: ubuntu-latest
steps:
- name: Create Neutral Check
uses: LouisBrunner/checks-action@v2.0.0

Check warning on line 9 in .github/workflows/test-status.yaml

View check run for this annotation

Codacy Development / Codacy Static Code Analysis

.github/workflows/test-status.yaml#L9

An action sourced from a third-party repository on GitHub is not pinned to a full length commit SHA. Pinning an action to a full length commit SHA is currently the only way to use an action as an immutable release.
Copy link

Choose a reason for hiding this comment

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

⚠️ Codacy found a medium Security issue: An action sourced from a third-party repository on GitHub is not pinned to a full length commit SHA. Pinning an action to a full length commit SHA is currently the only way to use an action as an immutable release.

The issue identified by the Semgrep linter is that the GitHub Action specified in the uses line is not pinned to a full-length commit SHA. This means that the action could change if the maintainers update the repository, potentially introducing breaking changes or vulnerabilities. Pinning to a specific commit SHA ensures that the exact version of the action is used, providing a more secure and stable integration.

To fix this issue, you should replace the version tag (v2.0.0) with the full-length commit SHA of that version. You can find the commit SHA by checking the repository's commit history on GitHub.

Assuming the commit SHA for version v2.0.0 is abc123def456gh789ijk012lmnop345qrst678, the code suggestion would look like this:

Suggested change
uses: LouisBrunner/checks-action@v2.0.0
uses: LouisBrunner/checks-action@abc123def456gh789ijk012lmnop345qrst678

This comment was generated by an experimental AI tool.

Choose a reason for hiding this comment

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

⚠️ Codacy found a medium Security issue: An action sourced from a third-party repository on GitHub is not pinned to a full length commit SHA. Pinning an action to a full length commit SHA is currently the only way to use an action as an immutable release.

The issue identified by the Semgrep linter is that the action LouisBrunner/checks-action@v2.0.0 is being referenced using a version tag (v2.0.0). Using version tags can lead to potential security risks, as they may change over time if the maintainer updates the action. To ensure that the action remains immutable and does not change unexpectedly, it is recommended to pin the action to a specific commit SHA.

To fix this issue, you should replace the version tag with the full-length commit SHA of the version you want to use. You can find the commit SHA by looking at the repository's commit history.

Here’s a code suggestion to fix the issue, assuming the commit SHA is abcdef1234567890abcdef1234567890abcdef12 (you should replace it with the actual SHA):

Suggested change
uses: LouisBrunner/checks-action@v2.0.0
uses: LouisBrunner/checks-action@abcdef1234567890abcdef1234567890abcdef12

This comment was generated by an experimental AI tool.

Choose a reason for hiding this comment

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

⚠️ Codacy found a medium Security issue: An action sourced from a third-party repository on GitHub is not pinned to a full length commit SHA. Pinning an action to a full length commit SHA is currently the only way to use an action as an immutable release.

The issue identified by the Semgrep linter is that the action LouisBrunner/checks-action@v2.0.0 is referenced using a version tag (v2.0.0) instead of a full-length commit SHA. Using version tags can lead to potential security vulnerabilities because the code associated with that tag could change if the repository owner updates it. Pinning to a specific commit SHA ensures that the action remains immutable and secure, as it will always refer to the exact version of the code at that commit.

To fix this issue, you should replace the version tag with the full-length commit SHA of the specific version you want to use. Here’s how you can do that:

Suggested change
uses: LouisBrunner/checks-action@v2.0.0
uses: LouisBrunner/checks-action@<full-length-commit-SHA>

Make sure to replace <full-length-commit-SHA> with the actual SHA of the commit corresponding to the version you intend to use.


This comment was generated by an experimental AI tool.

with:
token: ${{ secrets.GITHUB_TOKEN }}
name: "Manual Neutral Test"
conclusion: neutral
output: |
{"summary":"This is a test check with neutral conclusion"}