This project includes git hooks to enforce WASM integrity verification at commit time.
Run this command once after cloning the repository:
git config core.hooksPath .githooks
chmod +x .githooks/pre-commitTo verify hooks are installed:
git config core.hooksPath
# Should output: .githooksRuns before each commit to:
- Detect if WASM artifact is being modified
- Verify all contract imports are updated with new hash
- Ensure hash consistency across all three contracts
- Prevent commits that would break the build
If you need to bypass hooks for a specific commit:
git commit --no-verifyWarning: Only use this if you understand the security implications.
Check if hooks are configured:
git config core.hooksPathReconfigure if needed:
git config core.hooksPath .githooks
chmod +x .githooks/pre-commitIf you intentionally updated the WASM:
- Get the new hash:
sha256sum soroban_token_contract.wasm - Update all three contract imports
- Update verification scripts
- Try committing again
Make hook executable:
chmod +x .githooks/pre-commit