{"id":17995967,"url":"https://github.com/dhavalkapil/stack-guard","last_synced_at":"2025-03-26T03:32:10.469Z","repository":{"id":75873067,"uuid":"95903970","full_name":"DhavalKapil/stack-guard","owner":"DhavalKapil","description":"A toy implementation of 'Stack Guard' on top of the LLVM compiler toolchain","archived":false,"fork":false,"pushed_at":"2017-07-01T17:48:55.000Z","size":11,"stargazers_count":24,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-21T05:12:03.244Z","etag":null,"topics":["clang","llvm","stack","taint-analysis"],"latest_commit_sha":null,"homepage":"","language":"C++","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/DhavalKapil.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":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-06-30T16:01:31.000Z","updated_at":"2023-06-21T08:39:23.000Z","dependencies_parsed_at":"2023-02-25T01:00:43.495Z","dependency_job_id":null,"html_url":"https://github.com/DhavalKapil/stack-guard","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DhavalKapil%2Fstack-guard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DhavalKapil%2Fstack-guard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DhavalKapil%2Fstack-guard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DhavalKapil%2Fstack-guard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DhavalKapil","download_url":"https://codeload.github.com/DhavalKapil/stack-guard/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245585406,"owners_count":20639668,"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":["clang","llvm","stack","taint-analysis"],"created_at":"2024-10-29T21:12:35.525Z","updated_at":"2025-03-26T03:32:10.451Z","avatar_url":"https://github.com/DhavalKapil.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# stack-guard\n\nA toy implementation of 'Stack Guard' on top of the [LLVM](http://llvm.org/) compiler toolchain. \n\nInstrumentation code is added during compilation process to insert and verify stack canaries. Local variables (on the stack) are reordered to prevent buffers overflowing into other local variables. Vulnerable buffers are identified by performing a simple version of static taint analysis. Dependencies are maintained between function calls and pointer manipulations.\n\n**Note**: This was developed as a hobby project for fun. It should only be used for educational purposes. Some of its features could be implemented in a much simpler way, but I choose techniques which involved more of LLVM API, just to get used to it.\n\n## Installation\n\nStackGuard requires `cmake` \u003e= 3.8. It has been tested on llvm 3.5 and clang 3.5.\n\nTo build:\n\n```\nmkdir build \u0026\u0026 cd build\ncmake -DLLVM_ROOT=/path/to/llvm/build ..\nmake\n```\n\n## Usage\n\n```\nclang -Xload -load -Xload /path/to/StackGuard/build/StackGuardPass/LLVMStackGuardPass.so \u003csource code\u003e\n```\n\nTests are present in `./tests`. Run them using:\n\n```\nmake test\n```\n\n## License\n\nStackGuard is licensed under the [MIT license](https://dhaval.mit-license.org/2017/license.txt).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdhavalkapil%2Fstack-guard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdhavalkapil%2Fstack-guard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdhavalkapil%2Fstack-guard/lists"}