Skip to content

Potential fix for code scanning alert no. 76: Workflow does not contain permissions#1648

Draft
David-Engel wants to merge 1 commit into
devfrom
alert-autofix-76
Draft

Potential fix for code scanning alert no. 76: Workflow does not contain permissions#1648
David-Engel wants to merge 1 commit into
devfrom
alert-autofix-76

Conversation

@David-Engel
Copy link
Copy Markdown
Collaborator

Potential fix for https://github.com/microsoft/msphpsql/security/code-scanning/76

Add an explicit permissions block in .github/workflows/cpp-lint.yml at the workflow root so it applies to all jobs (including cppcheck).
For this workflow, the minimal required permission is:

  • contents: read

This preserves existing functionality (checkout + linting) while enforcing least privilege and satisfying the CodeQL finding.

Suggested fixes powered by Copilot Autofix. Review carefully before merging.

…in permissions

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
@codecov
Copy link
Copy Markdown

codecov Bot commented Jun 5, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 85.72%. Comparing base (f17b007) to head (e4012c8).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##              dev    #1648   +/-   ##
=======================================
  Coverage   85.72%   85.72%           
=======================================
  Files          23       23           
  Lines        7210     7210           
=======================================
  Hits         6181     6181           
  Misses       1029     1029           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

1 participant