Skip to content

πŸ‘ Rbum (Restic Backup Manager) - A user-friendly GUI tool for managing Restic in MacOS

License

Notifications You must be signed in to change notification settings

mpy-dev-ml/rBUM

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

rBUM (Restic Backup Manager)

CI codecov License: MIT

A macOS application for managing restic backups with a clean, modular architecture.

Project Structure

rBUM/
β”œβ”€β”€ Core/                           # Core framework
β”‚   β”œβ”€β”€ Core.docc/                 # Documentation catalog
β”‚   β”œβ”€β”€ Sources/
β”‚   β”‚   β”œβ”€β”€ Errors/               # Error type definitions
β”‚   β”‚   β”‚   β”œβ”€β”€ KeychainError.swift
β”‚   β”‚   β”‚   β”œβ”€β”€ SandboxError.swift
β”‚   β”‚   β”‚   β”œβ”€β”€ SecurityError.swift
β”‚   β”‚   β”‚   └── ServiceError.swift
β”‚   β”‚   β”œβ”€β”€ Logging/             # Logging infrastructure
β”‚   β”‚   β”œβ”€β”€ Models/              # Core data models
β”‚   β”‚   β”œβ”€β”€ Protocols/           # Core protocols
β”‚   β”‚   β”‚   β”œβ”€β”€ KeychainServiceProtocol.swift
β”‚   β”‚   β”‚   β”œβ”€β”€ SecurityServiceProtocol.swift
β”‚   β”‚   β”‚   └── ResticXPCServiceProtocol.swift
β”‚   β”‚   └── Services/            # Core services
β”‚   β”‚       β”œβ”€β”€ KeychainService.swift
β”‚   β”‚       β”œβ”€β”€ SecurityService.swift
β”‚   β”‚       β”œβ”€β”€ ResticXPCService.swift
β”‚   β”‚       └── Mock/            # Mock services
β”‚   β”‚           └── DummyXPCService.swift
β”‚   └── Tests/                    # Core framework tests
β”‚       β”œβ”€β”€ Mocks/               # Test mocks
β”‚       β”œβ”€β”€ SandboxTests/        # Sandbox compliance tests
β”‚       └── XPCTests/            # XPC service tests
β”œβ”€β”€ CoreTests/                     # Additional core tests
β”‚   β”œβ”€β”€ Mocks/                   # Mock implementations
β”‚   β”œβ”€β”€ Models/                  # Model tests
β”‚   β”œβ”€β”€ Protocols/               # Protocol tests
β”‚   β”œβ”€β”€ Services/                # Service tests
β”‚   └── XPCTests/               # XPC integration tests
β”œβ”€β”€ rBUM/                         # Main application
β”‚   β”œβ”€β”€ Services/
β”‚   β”‚   β”œβ”€β”€ Security/           # Security services
β”‚   β”‚   β”‚   └── KeychainCredentialsManager.swift
β”‚   β”‚   └── Storage/            # Storage services
β”‚   β”œβ”€β”€ ViewModels/              # View models
β”‚   └── Views/                   # SwiftUI views
└── rBUMTests/                    # Main app tests
    └── Services/                # Service tests

Architecture

Security Architecture

The project implements a robust security architecture with the following components:

  1. KeychainCredentialsManager

    • Manages secure storage of repository credentials
    • Uses KeychainService for sandbox-compliant operations
    • Handles XPC service integration for secure access
  2. KeychainService

    • Implements secure keychain operations
    • Manages access groups for XPC sharing
    • Ensures sandbox compliance
  3. SecurityService

    • Handles security-scoped bookmarks
    • Manages secure operations through XPC
    • Validates service access and permissions
  4. ResticXPCService

    • Executes privileged operations
    • Manages secure inter-process communication
    • Handles process lifecycle and permissions

The security architecture ensures:

  • Proper sandbox compliance
  • Secure credential management
  • Clear separation of concerns
  • Protocol-oriented design
  • Testability through mocks

Core Module

  • Platform-agnostic interfaces and models
  • Core business logic
  • Protocol-based design for flexibility

Platform Module

  • macOS-specific implementations
  • System framework integrations
  • Sandbox-compliant services

Features

  • Secure credential management
  • Backup scheduling and monitoring
  • Repository management
  • Snapshot handling
  • Secure XPC communication:
    • Version-controlled interface
    • Security validation
    • Resource access control
    • Timeout handling
    • Error propagation First created: 6 February 2025 Last updated: 6 February 2025

Development

Requirements

  • Xcode 15.0+
  • Swift 5.9.2
  • macOS 14.0+

Building

  1. Open rBUM.xcodeproj in Xcode
  2. Build the project (⌘B)
  3. Run the app (⌘R)

XPC Service Development

  1. The XPC service is embedded in the main application
  2. Service requires Core.framework dependency
  3. Testing through CoreTests XPC test suite
  4. Security considerations:
    • Proper entitlements required
    • Sandbox compliance
    • Security-scoped bookmarks
    • Audit session validation

Contributing

Please see CONTRIBUTING.md for guidelines.

License

[Your license here]

About

πŸ‘ Rbum (Restic Backup Manager) - A user-friendly GUI tool for managing Restic in MacOS

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages