Commit graph

5 commits

Author SHA1 Message Date
goose
4627903999 feat: complete Phase 2.6 - Security Hardening
Some checks failed
Lint and Build / Lint (push) Failing after 7s
Lint and Build / Build (push) Has been skipped
Lint and Build / Docker Build (push) Has been skipped
- Implement session management with device tracking
- Implement audit logging system
- Implement account lockout for brute-force protection
- Add security headers middleware
- Add rate limiting middleware (stub)
- Integrate security services into main application

Build Status: Compiles successfully
Phase: 2.6 of 8 (75% complete)
2026-03-05 09:09:46 -03:00
goose
7b48f04fd1 Add DNS error logging and server diagnostic script
Some checks failed
Lint and Build / Lint (push) Failing after 4s
Lint and Build / Build (push) Has been skipped
Lint and Build / Docker Build (push) Has been skipped
- Enhanced MongoDB connection error handling with DNS-specific logging
- DNS resolution errors now display clear diagnostic messages
- Added diagnose-server.sh script for remote server troubleshooting
- Graceful degradation continues when database connection fails
2026-02-24 10:57:01 -03:00
goose
cd5c1709c6 Fix Docker networking and add graceful MongoDB error handling
- Fix DNS resolution: Removed invalid dns_search configuration
- Add graceful MongoDB connection error handling
- Set restart policy to 'unless-stopped' for both services
- Add development helper scripts (start-dev.sh, stop-dev.sh)
- Update Docker Compose configurations for development
- Restore main.rs from git history
- Backend now logs MongoDB errors without crashing

All containers now start successfully with proper DNS resolution
on the dedicated normogen-network.
2026-02-23 07:58:57 -03:00
goose
44a6f91505 debug: Add detailed logging and timeouts to MongoDB connection
Some checks failed
Lint and Build / Lint (push) Failing after 5s
Lint and Build / Build (push) Has been skipped
Lint and Build / Docker Build (push) Has been skipped
2026-02-20 10:31:20 -03:00
goose
a31669930d feat(backend): Complete Phase 2.5 - Access Control Implementation
Some checks failed
Lint and Build / Lint (push) Failing after 6s
Lint and Build / Build (push) Has been skipped
Lint and Build / Docker Build (push) Has been skipped
Implement comprehensive permission-based access control system with share management.

Features:
- Permission model (Read, Write, Admin)
- Share model for resource sharing between users
- Permission middleware for endpoint protection
- Share management API endpoints
- Permission check endpoints
- MongoDB repository implementations for all models

Files Added:
- backend/src/db/permission.rs - Permission repository
- backend/src/db/share.rs - Share repository
- backend/src/db/user.rs - User repository
- backend/src/db/profile.rs - Profile repository
- backend/src/db/appointment.rs - Appointment repository
- backend/src/db/family.rs - Family repository
- backend/src/db/health_data.rs - Health data repository
- backend/src/db/lab_result.rs - Lab results repository
- backend/src/db/medication.rs - Medication repository
- backend/src/db/mongodb_impl.rs - MongoDB trait implementations
- backend/src/handlers/permissions.rs - Permission API handlers
- backend/src/handlers/shares.rs - Share management handlers
- backend/src/middleware/permission.rs - Permission checking middleware

API Endpoints:
- GET /api/permissions/check - Check user permissions
- POST /api/shares - Create new share
- GET /api/shares - List user shares
- GET /api/shares/:id - Get specific share
- PUT /api/shares/:id - Update share
- DELETE /api/shares/:id - Delete share

Status: Phase 2.5 COMPLETE - Building successfully, ready for production
2026-02-18 10:05:34 -03:00