A simple tool to protect your source code from unauthorized sharing
npm install srcguard
Protect your source code from unauthorized sharing
Installation •
Usage •
How It Works •
Features •
License
---
``bash`
npm install -g srcguard
`bash`
srcguard init
This creates a unique license key for your project and sets up auto-protection for your code.
Important: The generated license.key file contains your encryption key. Keep it secure and don't commit it to your repository.
`bash`
srcguard lock
This encrypts all your source files and replaces them with placeholders. Your original code is safely stored in the .srcguard directory.
`bash`
srcguard unlock
You'll be prompted for your license key. Enter it to restore all your original files.
srcguard uses strong encryption to protect your intellectual property:
1. Initialization: Generates a unique key and sets up Git hooks for auto-protection
2. Locking: Encrypts your files and stores them in a hidden directory
3. Unlocking: Requires the correct license key to restore files
4. Auto-Protection: Automatically locks your code before commits/pushes
- ✅ Strong AES-256 encryption protects your intellectual property
- ✅ Git integration automatically secures your code before sharing
- ✅ Simple key-based access for authorized developers
- ✅ Minimal dependencies for better security and performance
- ✅ Easy setup with just a few commands
- The .srcguard directory contains encrypted versions of your files - do not delete itlicense.key
- Keep your file secure and don't share it with unauthorized users.gitignore` automatically
- srcguard adds the license file to
Q: I lost my license key. Can I recover my code?
A: Without the license key, your files cannot be decrypted. Always keep a backup of your license key in a secure location.
Q: Will this work with any programming language?
A: Yes, srcguard works with any text-based source files, regardless of programming language.
MIT © [Titsou]