Sparkle Key Management Guide
This guide covers the management of EdDSA keys used for signing VibeTunnel updates with the Sparkle framework.Overview
VibeTunnel uses Sparkle’s EdDSA (Ed25519) signatures for secure software updates. This system requires:- A private key (kept secret) for signing updates
- A public key (distributed with the app) for verifying signatures
Key Locations
Public Key
- Location:
VibeTunnel/sparkle-public-ed-key.txt
- Status: Committed to repository
- Usage: Embedded in app via
SUPublicEDKey
in Info.plist - Current Value:
AGCY8w5vHirVfGGDGc8Szc5iuOqupZSh9pMj/Qs67XI=
Private Key
- Location:
private/sparkle_private_key
- Status: NOT in version control (in .gitignore)
- Usage: Required for signing updates during release
- Format: Base64-encoded key data (no comments or headers)
Initial Setup
For New Team Members
-
Request Access
-
Install Private Key
-
Verify Setup
For New Projects
-
Generate New Keys
-
Save Keys
-
Update App Configuration
- Add public key to Info.plist under
SUPublicEDKey
- Commit public key file to repository
- Add public key to Info.plist under
Key Security
Best Practices
-
Never Commit Private Keys
- Private directory is in .gitignore
- Double-check before committing
-
Secure Backup
- Store in encrypted location
- Use password manager or secure cloud storage
- Keep multiple secure backups
-
Limited Access
- Only release managers need private key
- Use secure channels for key transfer
- Rotate keys if compromised
-
Key Format
- Private key file must contain ONLY the base64 key
- No comments, headers, or extra whitespace
- Single line of base64 data
Example Private Key Format
Troubleshooting
”EdDSA signature does not match” Error
Cause: Wrong private key or key format issues Solution:- Verify private key matches public key
- Check key file has no extra characters
- Regenerate appcast with correct key
”Failed to decode base64 encoded key data”
Cause: Private key file contains comments or headers Solution:Testing Key Pair Match
Key Rotation
If keys need to be rotated:-
Generate New Keys
-
Update App
- Change
SUPublicEDKey
in Info.plist - Update
sparkle-public-ed-key.txt
- Release new version with new public key
- Change
-
Transition Period
- Keep old private key for emergency updates
- Sign new updates with new key
- After all users update, retire old key
Integration with Release Process
The release scripts automatically use the private key:-
generate-appcast.sh
- Expects key at
private/sparkle_private_key
- Fails if key missing or invalid
- Signs all DMG files in releases
- Expects key at
-
release.sh
- Calls generate-appcast.sh after creating DMG
- Ensures signatures are created before pushing
Recovery Procedures
Lost Private Key
If private key is lost:- Generate new key pair
- Update app with new public key
- Release update signed with old key (if possible)
- All future updates use new key
Compromised Private Key
If private key is compromised:- Generate new key pair immediately
- Release security update with new public key
- Notify users of security update
- Revoke compromised key (document publicly)
Verification Commands
Verify Current Setup
Verify Release Signatures
Additional Resources
For questions about key management, contact the release team lead.