Release v0.2.1 - Fix Message Decryption
MigChat CLI v0.2.1 - Message Decryption Fix
This is a patch release that fixes a critical bug where encrypted messages were not being decrypted when viewing conversations.
π Bug Fix
Fixed: Messages Showing as Encrypted Base64
Issue: When viewing conversations, messages were displaying as encrypted base64 text instead of decrypted plaintext.
Root Cause: The current_password was None when viewing conversations if the user was already logged in from a previous session. The password is only captured during login or account creation, not when starting an already-logged-in session.
Impact: Users couldn't read their encrypted messages - they would only see the raw base64 ciphertext like:
eyJ2ZXJzaW9uIjoxLCJzZW5k...
Solution
- Added
ensure_password()method that prompts for password when needed for decryption - Updated
print_message()to useensure_password()instead of assuming password exists - Better error handling to show specific decryption failures
- Backward compatibility maintained for unencrypted messages
π§ How It Works Now
- When you view a conversation with encrypted messages
- If password isn't cached, you'll be prompted once to enter it
- Password is cached for the session
- All subsequent messages decrypt automatically
- If decryption fails, you see a clear error message instead of raw base64
π Changes Since v0.2.0
Bug Fixes
- Fixed message decryption not working when viewing conversations
- Fixed borrow checker errors in password handling
- Fixed type comparison issues after cloning current_user
Commits
6c0f7be: Fix message decryption in conversationsdf308fd: Fix borrow checker error in print_messagec6a9fa0: Fix type comparison after cloning current_user
Full Changelog: v0.2.0...v0.2.1
β οΈ Known Issue from v0.2.0
If you upgraded to v0.2.0, you may have seen this decryption issue. Upgrading to v0.2.1 fixes it completely.
π Installation
Upgrading from v0.2.0:
- Download the new binary for your platform
- Replace your existing binary
- When viewing conversations, you'll be prompted for your password once
Quick Install (Linux/macOS):
curl -fsSL https://raw.githubusercontent.com/migchat/cli/main/install.sh | bashQuick Install (Windows):
irm https://raw.githubusercontent.com/migchat/cli/main/install.ps1 | iexManual Installation:
- Download the binary for your platform below
- Rename it to
migchatormigchat.exe(remove platform suffix) - (Unix only) Make it executable:
chmod +x migchat - Move it to a directory in your PATH
π¦ What's in v0.2.x
v0.2.0 (Previous Release)
- CRITICAL SECURITY FIX: Per-account encryption keys
- Each account now has unique encryption keys
- Account isolation enforced
v0.2.1 (This Release)
- Bug Fix: Message decryption now works properly
- Password prompting when needed
- Better error handling
π Security
All security features from v0.2.0 remain:
- β Per-account encryption keys
- β Account isolation
- β Unique fingerprints per account
- β Signal Protocol/X3DH implementation
- β ChaCha20-Poly1305 encryption
- β Perfect forward secrecy
Type: Bug Fix
Priority: P1 - High (affects usability)
Recommendation: Upgrade if you experienced decryption issues in v0.2.0