Repository navigation
🛡️ Security Release v1.2.0
🛡️ Security Release v1.2.0
🚨 Critical Security Fix
This release addresses a critical security vulnerability in the Row Level Security (RLS) policies that allowed anonymous users to access each other's spending data.
Security Issue Fixed
- CVE: Cross-user data access vulnerability in RLS policies
- Impact: Anonymous users could access ALL other anonymous users' spending data
- Severity: Critical
- Resolution: Fixed RLS policies and standardized authentication
Changes Made
🔒 Security Improvements
- Fixed RLS policies: Removed dangerous
user_id LIKE 'anon_%'wildcard conditions - Proper user isolation: RLS policies now use exact JWT-based user matching only
- Standardized authentication: Removed client-side user ID generation entirely
- Eliminated localStorage manipulation: No more client-controlled user IDs
🏗️ Authentication Refactor
- Supabase-only auth: Uses only Supabase's built-in anonymous authentication
- Proper session management: Improved session validation and restoration
- Better error handling: Proper exception throwing and error management
- Removed fallbacks: No more dangerous client-side ID fallbacks
Breaking Changes
- Users with local
anon_*IDs will be required to create new anonymous sessions - This is intentional to ensure all users have proper Supabase sessions
- No data will be lost - users just need to refresh the app
Migration Guide
- For existing users: Simply refresh the app - a new anonymous session will be created automatically
- For developers: Update your Supabase RLS policies if you've customized them
- Database updates: Run the updated SQL policies from
SUPABASE_SETUP.md
Files Changed
SUPABASE_SETUP.md- Updated with secure RLS policiessrc/composables/useAuth.ts- Completely refactored authentication logicpackage.json- Version bump to 1.2.0
Verification
- ✅ Build passes without TypeScript errors
- ✅ RLS policies properly restrict data access
- ✅ Authentication flow works with Supabase anonymous auth only
- ✅ Rate limiting research completed for future abuse prevention
Related Issues
- Fixes #35 - Critical RLS vulnerability
- Implements security recommendations from Supabase database advisor
SUPABASE_SETUP.md to ensure the security fix is applied.
🤖 Generated with Claude Code