{"id":29131981,"url":"https://github.com/otuemre/clocker","last_synced_at":"2025-06-30T06:10:16.036Z","repository":{"id":301962824,"uuid":"1010788545","full_name":"otuemre/CLocker","owner":"otuemre","description":"A lightweight educational file locker written in C that encrypts/decrypts files using XOR logic and toggles their names with a .locked suffix. Built for learning low-level file operations and systems programming.","archived":false,"fork":false,"pushed_at":"2025-06-29T20:21:27.000Z","size":30,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-29T21:21:20.967Z","etag":null,"topics":["c","cybersecurity","encryption","file-encryption-c","ransomware-simulator","xor-encryption"],"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/otuemre.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,"zenodo":null}},"created_at":"2025-06-29T19:59:10.000Z","updated_at":"2025-06-29T20:24:25.000Z","dependencies_parsed_at":"2025-06-29T21:32:08.110Z","dependency_job_id":null,"html_url":"https://github.com/otuemre/CLocker","commit_stats":null,"previous_names":["otuemre/clocker"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/otuemre/CLocker","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/otuemre%2FCLocker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/otuemre%2FCLocker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/otuemre%2FCLocker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/otuemre%2FCLocker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/otuemre","download_url":"https://codeload.github.com/otuemre/CLocker/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/otuemre%2FCLocker/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262720693,"owners_count":23353452,"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":["c","cybersecurity","encryption","file-encryption-c","ransomware-simulator","xor-encryption"],"created_at":"2025-06-30T06:10:15.519Z","updated_at":"2025-06-30T06:10:16.018Z","avatar_url":"https://github.com/otuemre.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CLocker - An XOR File Locker\n\nCLocker is a lightweight educational file locker built in C. It encrypts and decrypts files within a given directory using XOR encryption and renames them based on their locked status.\n\n\u003e This project was built for learning purposes only — it is **not** intended for malicious use.\n\n---\n\n## Features\n\n- Encrypts all regular files in a folder using XOR\n- Renames encrypted files by appending `.locked`\n- Automatically decrypts files and restores original names if run again\n- Accepts full path and key from the user via terminal\n- Works on Windows with minimal dependencies\n- Modular C codebase (split into `.h` and `.c` files)\n\n---\n\n## How It Works\n\n1. The program asks the user for:\n   - Full path to a folder (e.g. `C:\\Users\\your_username\\Desktop\\important`)\n   - A single-character key\n2. It scans the folder for regular files.\n3. If a file ends with `.locked`, it is decrypted and renamed to its original name.\n4. If a file does **not** end with `.locked`, it is encrypted and renamed to `filename.locked`.\n\n---\n\n## Build Instructions\n\n### Requirements\n\n- GCC (MinGW for Windows)\n- [`dirent.h`](https://github.com/tronkko/dirent) (portable version with `static` implementations)\n\n### Compile\n\n```bash\ngcc main.c locker.c -o locker.exe\n```\n\n\u003e No need for `dirent.c` if you're using the self-contained `dirent.h`.\n\n---\n\n## Usage\n\nAfter compiling:\n\n```bash\n./locker.exe\n```\n\nExample input:\n\n```\nPlease Enter the Full Path of the Folder: C:\\Users\\your_username\\Desktop\\top-secret\nPlease Enter the Key (char): A\n```\n\nRun again with the same key to unlock files.\n\n---\n\n## Disclaimer\n\nThis project was created solely for educational and demonstration purposes.  \n**Do not use this tool on systems, files, or data you do not own or have permission to test.**\n\n---\n\n## License\n\nLicensed under the [MIT License](./LICENSE.md). You’re free to use and modify responsibly.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fotuemre%2Fclocker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fotuemre%2Fclocker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fotuemre%2Fclocker/lists"}