Add the OpenSSF Scorecard GitHub Action and publish the results
Mantenedores costumam responder em até 2 dias
Avaliação
- Dificuldade
- 2/5
- Tempo estimado
- 1-3 horas
- Facilidade para iniciantes
- 78/100
Direção de pesquisa
Comece pelo README da action Scorecard e pelos workflows existentes em .github/workflows/; adicione um workflow que atenda aos requisitos listados de gatilhos, permissões, pinning das actions, publicação dos resultados e upload de SARIF. Execute actionlint .github/workflows/scorecard.yaml para verificá-lo. O trabalho estará concluído quando o workflow atender aos critérios de aceitação e a CI existente continuar verde.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Problem
python-sdk has no OpenSSF Scorecard results published. The public Scorecard API returns nothing for it today (curl -s https://api.securityscorecards.dev/projects/github.com/dapr/python-sdk is a 404), while dapr/dapr is already scanned. Running the official Scorecard action on a schedule gives users a public score for the project's supply-chain practices, and gives maintainers a list of concrete things to fix (pinned dependencies, token permissions, branch protection and so on) in the repo's code scanning alerts.
Proposed change
Add a workflow, for example .github/workflows/scorecard.yaml, using ossf/scorecard-action. The action's README has a starter workflow; the important parts are:
- Triggers:
pushtomain, a weeklyschedule, andbranch_protection_rule. - Top-level
permissions: read-all, and on the job only what it needs:security-events: write(upload SARIF),id-token: write(publish results),contents: read,actions: read. ossf/scorecard-actionwithresults_format: sarifandpublish_results: true.- Upload the SARIF with
github/codeql-action/upload-sarifso findings appear under Security, Code scanning. - Optionally upload the SARIF with
actions/upload-artifacttoo, for easy download.
Pin the actions in this new workflow to commit SHAs with the version as a trailing comment (for example uses: actions/checkout@<sha> # v7.0.0). Scorecard's own Pinned-Dependencies check expects it, and publish_results: true requires the workflow to follow the action's restrictions (see its README).
Optionally, add the Scorecard badge to README.md:
[](https://scorecard.dev/viewer/?uri=github.com/dapr/python-sdk)
Acceptance criteria
- A Scorecard workflow runs on push to
main, weekly, and on branch protection changes. - It uses
ossf/scorecard-actionwithpublish_results: true, and uploads the SARIF to code scanning. - The workflow's token has read-only permissions at the top level and only the job-level write permissions listed above.
- All
uses:in the new workflow are pinned to full commit SHAs with a version comment. - Existing CI stays green.
How to test
- Run
actionlint .github/workflows/scorecard.yamllocally. - After merge (or via
workflow_dispatchif you add it), check the run succeeds and that results appear under Security, Code scanning. - Confirm
curl -s https://api.securityscorecards.dev/projects/github.com/dapr/python-sdkreturns a JSON result. - Before opening the PR you can preview the score locally with the scorecard CLI:
scorecard --repo=github.com/dapr/python-sdk(needs aGITHUB_AUTH_TOKEN).
- Linguagem predominante
- Python
- Estrelas
- 274
- Forks
- 160
- Merge médio
- 1d 23h
- PRs com merge (30d)
- 70
Preparar o ambiente
Inicia o contêiner de desenvolvimento do projeto no navegador, com a sua própria conta do GitHub.
- Sem Dockerfile nem arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de dapr/python-sdk
-
SDK Alignment of Workflow ExamplesTalvez livre de novo Um pull request para esta issue foi fechado sem ser mesclado. Abertadapr-ext-workflow good first issue kind/enhancement P2
Dificuldade 2/5 1-2 dias Facilidade para iniciantes 72/100
dapr/python-sdk#853 · 4 comentários ·
Mantenedores costumam responder em até 2 dias
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 47/100
dapr/python-sdk#1346 ·
Mantenedores costumam responder em até 2 dias
-
Add PyPI keywords and project links to the dapr packageTalvez já em andamento @SpinachDigital assumiu há 4 dias. Abertagood first issue help wanted kind/enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 20/100
dapr/python-sdk#1335 · 1 comentário ·
Mantenedores costumam responder em até 2 dias
-
Give each workflow's token only the permissions it needsTalvez já em andamento @AlphaNen assumiu há 4 dias. Abertagood first issue help wanted
dapr/python-sdk#1333 · 1 comentário · 1 responsável ·
Mantenedores costumam responder em até 2 dias
-
ci/release-failure release
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 25/100
dapr/python-sdk#1320 ·
Mantenedores costumam responder em até 2 dias
Todas as issues de dapr/python-sdk
Issues semelhantes
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 85/100
521xueweihan/HelloGitHub#4115 ·
-
get_lldp_neighbors_detail: query asks for 'max-address' (typo for 'mac-address'), so remote_chassis_id is always emptyTalvez já em andamento @Jah-yee assumiu hoje. Aberta
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 88/100
-
lesson-submission pending-review
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 74/100
Ikalus1988/MisakaNet#3899 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
aws-samples/sample-per-model-bedrock#549 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 90/100