{"id":15418656,"url":"https://github.com/jamiemagee/vulnerability-git-hooks","last_synced_at":"2025-04-06T16:49:27.625Z","repository":{"id":173531577,"uuid":"650427624","full_name":"JamieMagee/vulnerability-git-hooks","owner":"JamieMagee","description":"git hooks to prevent committing vulnerable dependencies","archived":false,"fork":false,"pushed_at":"2025-02-28T22:50:04.000Z","size":9,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-01T00:36:09.111Z","etag":null,"topics":["deps-dev","git-hooks","supply-chain-security"],"latest_commit_sha":null,"homepage":"","language":"Shell","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/JamieMagee.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-06-07T03:48:07.000Z","updated_at":"2025-02-28T22:49:50.000Z","dependencies_parsed_at":"2023-09-27T23:46:15.575Z","dependency_job_id":null,"html_url":"https://github.com/JamieMagee/vulnerability-git-hooks","commit_stats":{"total_commits":6,"total_committers":2,"mean_commits":3.0,"dds":"0.33333333333333337","last_synced_commit":"8268669aaba1758dfe8d5e21a04126a618a85f6a"},"previous_names":["jamiemagee/vulnerability-git-hooks"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JamieMagee%2Fvulnerability-git-hooks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JamieMagee%2Fvulnerability-git-hooks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JamieMagee%2Fvulnerability-git-hooks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JamieMagee%2Fvulnerability-git-hooks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JamieMagee","download_url":"https://codeload.github.com/JamieMagee/vulnerability-git-hooks/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247517924,"owners_count":20951716,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["deps-dev","git-hooks","supply-chain-security"],"created_at":"2024-10-01T17:22:05.770Z","updated_at":"2025-04-06T16:49:27.564Z","avatar_url":"https://github.com/JamieMagee.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Vulnerability Git Hooks\n\n[![MIT License](https://img.shields.io/github/license/JamieMagee/vulnerability-git-hooks?style=for-the-badge)](https://github.com/JamieMagee/vulnerability-git-hooks/blob/main/LICENSE.md)\n![Stability Experimental](https://img.shields.io/badge/stability-experimental-orange.svg?style=for-the-badge)\n\nA colleciton of [git hooks][1] that use the [`deps.dev` query API][2] to prevent adding vulnerable dependencies to your repository.\n\n## How does it work?\n\nThe `pre-commit` script calculates the hash for each file that has been staged for commit.\nFor example `/m56MsEiiIS5aRp0T5U6VdDdjq0=` is the hash for `org.apache.logging.log4j:log4j-core:2.17.0`\nIt then uses the [`deps.dev` query API][2] to check if any of the files match a known dependency.\nIf any vulnerabilities are found, the commit is aborted.\n\n## Requirements\n\n- [OpenSSL][3]\n- [cURL][4]\n- [jq][5]\n\n## Installation\n\nCopy the script to the `.git/hooks` directory in your local repository.\n\n## License\n\nAll code in this repository is licensed under [the MIT license][6].\n\n[1]: https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks\n[2]: https://docs.deps.dev/api/v3alpha/#query\n[3]: https://www.openssl.org/\n[4]: https://curl.se/\n[5]: https://jqlang.github.io/jq/\n[6]: https://opensource.org/licenses/MIT","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjamiemagee%2Fvulnerability-git-hooks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjamiemagee%2Fvulnerability-git-hooks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjamiemagee%2Fvulnerability-git-hooks/lists"}