{"id":18952267,"url":"https://github.com/step-security/ghaction-import-gpg","last_synced_at":"2026-03-17T21:04:48.653Z","repository":{"id":210506640,"uuid":"726727642","full_name":"step-security/ghaction-import-gpg","owner":"step-security","description":"GitHub Action to import a GPG key. Secure drop-in replacement for crazy-max/ghaction-import-gpg.","archived":false,"fork":false,"pushed_at":"2026-03-16T04:51:45.000Z","size":5683,"stargazers_count":2,"open_issues_count":13,"forks_count":4,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-16T11:23:34.913Z","etag":null,"topics":["step-security-maintained-actions"],"latest_commit_sha":null,"homepage":"https://docs.stepsecurity.io/actions/stepsecurity-maintained-actions","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/step-security.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-12-03T07:52:04.000Z","updated_at":"2026-03-16T04:51:51.000Z","dependencies_parsed_at":"2023-12-03T09:33:52.784Z","dependency_job_id":"dad13808-00d7-4da0-873c-3dc4c7f83a55","html_url":"https://github.com/step-security/ghaction-import-gpg","commit_stats":null,"previous_names":["step-security/ghaction-import-gpg"],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/step-security/ghaction-import-gpg","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/step-security%2Fghaction-import-gpg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/step-security%2Fghaction-import-gpg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/step-security%2Fghaction-import-gpg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/step-security%2Fghaction-import-gpg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/step-security","download_url":"https://codeload.github.com/step-security/ghaction-import-gpg/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/step-security%2Fghaction-import-gpg/sbom","scorecard":{"id":1237591,"data":{"date":"2025-09-09T07:27:02Z","repo":{"name":"github.com/step-security/ghaction-import-gpg","commit":"4d3430a3773d9ba9654feb03f7b043dadc6b2f57"},"scorecard":{"version":"v5.0.0","commit":"ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4"},"score":7.6,"checks":[{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#binary-artifacts"}},{"name":"Branch-Protection","score":8,"reason":"branch protection is not maximal on development and all release branches","details":["Info: 'allow deletion' disabled on branch 'main'","Info: 'force pushes' disabled on branch 'main'","Warn: required approving review count is 1 on branch 'main'","Warn: codeowners review is not required on branch 'main'","Info: status check found to merge onto on branch 'main'","Info: PRs are required in order to make changes on branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#branch-protection"}},{"name":"CI-Tests","score":10,"reason":"11 out of 11 merged PRs checked by a CI test -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project runs tests before pull requests are merged.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#ci-tests"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#cii-best-practices"}},{"name":"Code-Review","score":10,"reason":"all changesets reviewed","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#code-review"}},{"name":"Contributors","score":10,"reason":"project has 3 contributing companies or organizations -- score normalized to 10","details":["Info: ait pune contributor org/company found, stepsecurity contributor org/company found, step-security contributor org/company found, "],"documentation":{"short":"Determines if the project has a set of contributors from multiple organizations (e.g., companies).","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#contributors"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#dangerous-workflow"}},{"name":"Dependency-Update-Tool","score":10,"reason":"update tool detected","details":["Info: detected update tool: Dependabot: .github/dependabot.yml:1"],"documentation":{"short":"Determines if the project uses a dependency update tool.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#dependency-update-tool"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#license"}},{"name":"Maintained","score":3,"reason":"4 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 3","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#packaging"}},{"name":"Pinned-Dependencies","score":6,"reason":"dependency not pinned by hash detected -- score normalized to 6","details":["Warn: containerImage not pinned by hash: dev.Dockerfile:5","Warn: containerImage not pinned by hash: dev.Dockerfile:15","Warn: containerImage not pinned by hash: dev.Dockerfile:24","Warn: containerImage not pinned by hash: dev.Dockerfile:36","Warn: containerImage not pinned by hash: dev.Dockerfile:45","Warn: containerImage not pinned by hash: dev.Dockerfile:57","Warn: containerImage not pinned by hash: dev.Dockerfile:67","Warn: containerImage not pinned by hash: dev.Dockerfile:73","Info:  20 out of  20 GitHub-owned GitHubAction dependencies pinned","Info:  15 out of  15 third-party GitHubAction dependencies pinned","Info:   0 out of   8 containerImage dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#pinned-dependencies"}},{"name":"SAST","score":9,"reason":"SAST tool detected but not run on all commits","details":["Info: SAST configuration detected: CodeQL","Warn: 26 commits out of 30 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#sast"}},{"name":"Security-Policy","score":10,"reason":"security policy file detected","details":["Info: security policy file detected: SECURITY.md:1","Info: Found linked content: SECURITY.md:1","Info: Found disclosure, vulnerability, and/or timelines in security policy: SECURITY.md:1","Info: Found text in security policy: SECURITY.md:1"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#security-policy"}},{"name":"Signed-Releases","score":10,"reason":"4 out of the last 4 releases have a total of 4 signed artifacts.","details":["Info: provenance for release artifact: multiple.intoto.jsonl: https://api.github.com/repos/step-security/ghaction-import-gpg/releases/assets/259361811","Info: provenance for release artifact: multiple.intoto.jsonl: https://api.github.com/repos/step-security/ghaction-import-gpg/releases/assets/184030403","Info: provenance for release artifact: multiple.intoto.jsonl: https://api.github.com/repos/step-security/ghaction-import-gpg/releases/assets/180198691","Info: provenance for release artifact: multiple.intoto.jsonl: https://api.github.com/repos/step-security/ghaction-import-gpg/releases/assets/141899388"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#signed-releases"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Info: jobLevel 'actions' permission set to 'read': .github/workflows/actions_release.yaml:24","Warn: jobLevel 'contents' permission set to 'write': .github/workflows/actions_release.yaml:26","Info: jobLevel 'actions' permission set to 'read': .github/workflows/codeql.yml:31","Info: jobLevel 'contents' permission set to 'read': .github/workflows/codeql.yml:32","Info: jobLevel 'contents' permission set to 'read': .github/workflows/scorecards.yml:29","Info: jobLevel 'actions' permission set to 'read': .github/workflows/scorecards.yml:30","Info: jobLevel 'issues' permission set to 'read': .github/workflows/scorecards.yml:32","Info: jobLevel 'pull-requests' permission set to 'read': .github/workflows/scorecards.yml:33","Info: jobLevel 'checks' permission set to 'read': .github/workflows/scorecards.yml:35","Info: topLevel 'contents' permission set to 'read': .github/workflows/actions_release.yaml:19","Warn: topLevel 'contents' permission set to 'write': .github/workflows/audit_package.yml:36","Info: topLevel 'packages' permission set to 'read': .github/workflows/audit_package.yml:38","Info: topLevel 'packages' permission set to 'read': .github/workflows/auto_cherry_pick.yml:27","Warn: topLevel 'contents' permission set to 'write': .github/workflows/auto_cherry_pick.yml:25","Info: topLevel 'contents' permission set to 'read': .github/workflows/ci.yml:9","Info: topLevel 'contents' permission set to 'read': .github/workflows/codeql.yml:24","Info: topLevel 'contents' permission set to 'read': .github/workflows/dependency-review.yml:13","Info: topLevel 'contents' permission set to 'read': .github/workflows/guarddog.yml:10","Info: topLevel permissions set to 'read-all': .github/workflows/scorecards.yml:18","Info: topLevel 'contents' permission set to 'read': .github/workflows/test.yml:9","Info: topLevel 'contents' permission set to 'read': .github/workflows/validate.yml:9"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#token-permissions"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/ea7e27ed41b76ab879c862fa0ca4cc9c61764ee4/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-09-13T07:14:51.847Z","repository_id":210506640,"created_at":"2025-09-13T07:14:51.848Z","updated_at":"2025-09-13T07:14:51.848Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30631436,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-17T17:32:55.572Z","status":"ssl_error","status_checked_at":"2026-03-17T17:32:38.732Z","response_time":56,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["step-security-maintained-actions"],"created_at":"2024-11-08T13:32:23.344Z","updated_at":"2026-03-17T21:04:48.635Z","avatar_url":"https://github.com/step-security.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# StepSecurity Maintained ghaction-import-gpg Action\n\nForked from: [crazy-max/ghaction-import-gpg](https://github.com/crazy-max/ghaction-import-gpg)\n\nGitHub Action to easily import a GPG key.\n\n![Import GPG](.github/ghaction-import-gpg.png)\n\n___\n\n* [Features](#features)\n* [Prerequisites](#prerequisites)\n* [Usage](#usage)\n  * [Workflow](#workflow)\n  * [Sign commits](#sign-commits)\n  * [Use a subkey](#use-a-subkey)\n  * [Set key's trust level](#set-keys-trust-level)\n* [Customizing](#customizing)\n  * [inputs](#inputs)\n  * [outputs](#outputs)\n* [Contributing](#contributing)\n* [License](#license)\n\n## Features\n\n* Works on Linux, macOS and Windows [virtual environments](https://help.github.com/en/articles/virtual-environments-for-github-actions#supported-virtual-environments-and-hardware-resources)\n* Allow seeding the internal cache of `gpg-agent` with provided passphrase\n* Signing-only subkeys support\n* Purge imported GPG key, cache information and kill agent from runner\n* (Git) Enable signing for Git commits, tags and pushes\n* (Git) Configure and check committer info against GPG key\n\n## Prerequisites\n\nFirst, [generate a GPG key](https://docs.github.com/en/github/authenticating-to-github/generating-a-new-gpg-key) and\nexport the GPG private key as an ASCII armored version to your clipboard:\n\n```shell\n# macOS\ngpg --armor --export-secret-key joe@foo.bar | pbcopy\n\n# Ubuntu (assuming GNU base64)\ngpg --armor --export-secret-key joe@foo.bar -w0 | xclip\n\n# Arch\ngpg --armor --export-secret-key joe@foo.bar | xclip -selection clipboard -i\n\n# FreeBSD (assuming BSD base64)\ngpg --armor --export-secret-key joe@foo.bar | xclip\n```\n\nPaste your clipboard as a [`secret`](https://help.github.com/en/actions/configuring-and-managing-workflows/creating-and-storing-encrypted-secrets)\nnamed `GPG_PRIVATE_KEY` for example. Create another secret with the\n`PASSPHRASE` if applicable.\n\n## Usage\n\n### Workflow\n\n```yaml\nname: import-gpg\n\non:\n  push:\n    branches: master\n\njobs:\n  import-gpg:\n    runs-on: ubuntu-latest\n    steps:\n      -\n        name: Checkout\n        uses: actions/checkout@v4\n      -\n        name: Import GPG key\n        uses: step-security/ghaction-import-gpg@v6\n        with:\n          gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}\n          passphrase: ${{ secrets.PASSPHRASE }}\n      -\n        name: List keys\n        run: gpg -K\n```\n\n### Sign commits\n\n```yaml\nname: import-gpg\n\non:\n  push:\n    branches: master\n\njobs:\n  sign-commit:\n    runs-on: ubuntu-latest\n    steps:\n      -\n        name: Checkout\n        uses: actions/checkout@v4\n      -\n        name: Import GPG key\n        uses: step-security/ghaction-import-gpg@v6\n        with:\n          gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}\n          passphrase: ${{ secrets.PASSPHRASE }}\n          git_user_signingkey: true\n          git_commit_gpgsign: true\n      -\n        name: Sign commit and push changes\n        run: |\n          echo foo \u003e bar.txt\n          git add .\n          git commit -S -m \"This commit is signed!\"\n          git push\n```\n\n### Use a subkey\n\nWith the input `fingerprint`, you can specify which one of the subkeys in a GPG\nkey you want to use for signing.\n\n```yaml\nname: import-gpg\n\non:\n  push:\n    branches: master\n\njobs:\n  import-gpg:\n    runs-on: ubuntu-latest\n    steps:\n      -\n        name: Checkout\n        uses: actions/checkout@v4\n      -\n        name: Import GPG key\n        uses: step-security/ghaction-import-gpg@v6\n        with:\n          gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}\n          passphrase: ${{ secrets.PASSPHRASE }}\n          fingerprint: \"C17D11ADF199F12A30A0910F1F80449BE0B08CB8\"\n      -\n        name: List keys\n        run: gpg -K\n```\n\nFor example, given this GPG key with a signing subkey:\n\n```\npub   ed25519 2021-09-24 [C]\n      87F257B89CE462100BEC0FFE6071D218380FDCC8\n      Keygrip = F5C3ABFAAB36B427FD98C4EDD0387E08EA1E8092\nuid           [ unknown] Joe Bar \u003cjoe@bar.foo\u003e\nsub   ed25519 2021-09-24 [S]\n      C17D11ADF199F12A30A0910F1F80449BE0B08CB8\n      Keygrip = DEE0FC98F441519CA5DE5D79773CB29009695FEB\n```\n\nYou can use the subkey with signing capability whose fingerprint is `C17D11ADF199F12A30A0910F1F80449BE0B08CB8`.\n\n### Set key's trust level\n\nWith the `trust_level` input, you can specify the trust level of the GPG key.\n\nValid values are:\n* `1`: unknown\n* `2`: never\n* `3`: marginal\n* `4`: full\n* `5`: ultimate\n\n```yaml\nname: import-gpg\n\non:\n  push:\n    branches: master\n\njobs:\n  import-gpg:\n    runs-on: ubuntu-latest\n    steps:\n      -\n        name: Checkout\n        uses: actions/checkout@v4\n      -\n        name: Import GPG key\n        uses: step-security/ghaction-import-gpg@v6\n        with:\n          gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}\n          passphrase: ${{ secrets.PASSPHRASE }}\n          trust_level: 5\n```\n\n## Customizing\n\n### inputs\n\nThe following inputs can be used as `step.with` keys:\n\n| Name                  | Type   | Description                                                                                |\n|-----------------------|--------|--------------------------------------------------------------------------------------------|\n| `gpg_private_key`     | String | GPG private key exported as an ASCII armored version or its base64 encoding (**required**) |\n| `passphrase`          | String | Passphrase of the GPG private key                                                          |\n| `trust_level`         | String | Set key's trust level                                                                      |\n| `git_config_global`   | Bool   | Set Git config global (default `false`)                                                    |\n| `git_user_signingkey` | Bool   | Set GPG signing keyID for this Git repository (default `false`)                            |\n| `git_commit_gpgsign`  | Bool   | Sign all commits automatically. (default `false`)                                          |\n| `git_tag_gpgsign`     | Bool   | Sign all tags automatically. (default `false`)                                             |\n| `git_push_gpgsign`    | String | Sign all pushes automatically. (default `if-asked`)                                        |\n| `git_committer_name`  | String | Set commit author's name (defaults to the name associated with the GPG key)                |\n| `git_committer_email` | String | Set commit author's email (defaults to the email address associated with the GPG key)      |\n| `workdir`             | String | Working directory (below repository root) (default `.`)                                    |\n| `fingerprint`         | String | Specific fingerprint to use (subkey)                                                       |\n\n\u003e [!NOTE]\n\u003e `git_user_signingkey` needs to be enabled for `git_commit_gpgsign`, `git_tag_gpgsign`,\n\u003e `git_push_gpgsign`, `git_committer_name`, `git_committer_email` inputs.\n\n### outputs\n\nThe following outputs are available:\n\n| Name          | Type   | Description                                                                                                                     |\n|---------------|--------|---------------------------------------------------------------------------------------------------------------------------------|\n| `fingerprint` | String | Fingerprint of the GPG key (recommended as [user ID](https://www.gnupg.org/documentation/manuals/gnupg/Specify-a-User-ID.html)) |\n| `keyid`       | String | Low 64 bits of the X.509 certificate SHA-1 fingerprint                                                                          |\n| `name`        | String | Name associated with the GPG key                                                                                                |\n| `email`       | String | Email address associated with the GPG key                                                                                       |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstep-security%2Fghaction-import-gpg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstep-security%2Fghaction-import-gpg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstep-security%2Fghaction-import-gpg/lists"}