v2.2.3 - Enhanced Token Security
🔐 Enhanced Token Security & Reliability
Fixed
- 🔐 Enhanced Token Encryption: Implemented OpenSSL AES-256-CBC encryption as primary method with XOR fallback
- Fixed OpenSSL command syntax to use
aes-256-cbcinstead ofenc -aes-256-cbc - Proper encryption/decryption flow with base64 encoding
- Maintains backward compatibility with existing XOR-encrypted tokens
- Fixed OpenSSL command syntax to use
- 🛡️ Token Validation: Added comprehensive token validation after decryption
- Automatic detection and cleanup of corrupted tokens
- Minimum length validation (20+ characters for GitHub tokens)
- Token preview in debug output for troubleshooting
- 🔧 Script Compatibility: Fixed BASH_SOURCE parameter expansion issues
- Proper handling when script is sourced vs executed directly
- Prevents "parameter not set" errors in strict mode
- 📱 Function Structure: Cleaned up decrypt_token function structure and removed duplicate code
Security
- Token encryption now uses industry-standard AES-256-CBC with OpenSSL when available
- Fallback XOR encryption maintains compatibility with existing installations
- Enhanced error handling prevents token corruption issues
Upgrade Instructions
git pull origin main
./setup.sh # Existing tokens will be automatically validated and re-encrypted if neededThis release resolves the token corruption issues reported in previous versions.