Files
xiatianxuan 8f2bcdf8fa v2.0.0: 多目标备份 + S3云存储 + 完整性校验 + 9语言国际化
feat: v2.0.0 — 多目标备份 + S3云存储 + 审计日志 + 9语言国际化
2026-06-20 14:01:43 +08:00

136 lines
4.3 KiB
Markdown

## What's New
### Major Features
#### Multi-Destination Backup
- Parallel backup to local + multiple remote targets simultaneously
- Supports SFTP + WebDAV + S3 cloud storage in a single operation
- Independent failure handling per destination
#### S3 Cloud Storage
- AWS S3 compatible storage support (AWS, MinIO, Alibaba Cloud OSS, etc.)
- Upload/download/delete operations
- Auto-create bucket if not exists
#### Data Integrity
- SHA256 checksum generation and verification
- Reed-Solomon error correction codes (reedsolo)
- Tamper detection with HMAC validation
#### Task Queue System
- JSON-persistent task queue management
- Add, execute, cancel, delete tasks
- Async background execution with status tracking
#### Cross-Archive Search
- Search for files across multiple backup archives
- Pattern matching with wildcard support
- Results grouped by archive
#### Selective Restore
- Restore specific files matching patterns
- Keyword-based file extraction
- Dry-run preview before actual restore
#### Backup Rotation
- Keep-count policy: retain latest N backups
- Keep-days policy: retain backups within N days
- Keep-daily policy: retain N daily backups
#### Pre/Post Hooks
- Execute custom commands before/after backup
- Timeout control and error handling
- Cross-platform command parsing
#### Configuration Profile
- Save/load/delete named profiles
- Switch between different backup configurations
- Import/export profiles as JSON
#### Audit Logging
- Record all backup/restore operations
- Search by time range and event type
- JSON-persistent audit trail
### Performance & Reliability
- **Chunked Backup**: 64KB block-level incremental backup
- **File Deduplication**: SHA256-based dedup to avoid redundant uploads
- **Parallel Compression**: Multi-threaded compression for large backups
- **Bandwidth Limiter**: Token bucket rate limiting for remote uploads
- **Retry Mechanism**: Exponential backoff for network operations
- **Backup Lock**: Cross-platform process lock to prevent concurrent runs
### New Commands (27 added)
| Command | Description |
|---------|-------------|
| `edit` | Edit existing backup strategy |
| `history` | View backup version history |
| `info` | View backup file details |
| `diff` | Compare source directory with backup |
| `verify` | Verify backup file integrity |
| `remote` | Remote file management (list/rm) |
| `export` / `import` | Export/import backup strategies |
| `status` | Backup status dashboard |
| `ignore` | Generate .sbackupignore file |
| `versions` | View backup version history |
| `schedule` | Export cron/schtasks configuration |
| `webhook` | Configure webhook presets |
| `config` | Encrypt/decrypt/validate config |
| `report` | Generate HTML/JSON backup reports |
| `search` | Search files in backup |
| `xsearch` | Cross-archive search |
| `clean` | Clean old backups |
| `completion` | Generate shell completion scripts |
| `wizard` | Interactive configuration wizard |
| `task` | Task queue management |
| `audit` | Audit log queries |
| `hooks` | Manual hook execution |
| `profile` | Configuration profile management |
| `rotate` | Backup rotation cleanup |
| `diskcheck` | Disk space estimation |
| `benchmark` | Compression format benchmarking |
| `integrity` | Directory integrity verification |
### Remote Backup Enhancements
- **SFTP**: Auto-detect default SSH keys (~/.ssh/id_rsa, id_ed25519)
- **SFTP**: Host key verification with known_hosts
- **SFTP**: Allow password fallback on private key auth failure
- **WebDAV**: Zero-dependency urllib implementation
- **WebDAV**: SSRF protection (protocol/IP validation)
- **WebDAV**: Proper PROPFIND redirect handling
- **S3**: MinIO client with path prefix support
### Security
- PBKDF2 encryption for sensitive config fields
- HMAC-SHA256 config tamper detection
- SSRF protection for WebDAV and webhook URLs
- Safe archive extraction (path traversal prevention)
### Developer Experience
- 37 CLI commands
- 37 source modules
- 9 language translations (665 keys each)
- 940 tests, 0 failures
- CI/CD: pytest on 3 platforms x 2 Python versions
- Release automation with versioned binary names
## Installation
```bash
pip install sbackup-cli
```
**Binary downloads:**
| Platform | File |
|----------|------|
| Windows x64 | `sbackup-2.0.0-windows-x64.exe` |
| macOS ARM64 | `sbackup-2.0.0-macos-arm64` |
| macOS x64 | `sbackup-2.0.0-macos-x86_64` |
| Linux x64 | `sbackup-2.0.0-linux-x86_64` |